Boot TrueNAS as memory resident only? Say to boot from iPXE?

Jibun no Kage

Dabbler
Joined
May 18, 2023
Messages
15
Boot TrueNAS as memory resident only? Say from iPXE? Yes, this would mean initially TrueNAS was stateless, had not personality, i.e. configuration. But that would be the next question or issue to solve. The first question is, can one Boot TrueNAS from iPXE. Not to install, but as a functional system? For example, various virtualization hypervisors can do this, since they are 100% memory resident, typical logging is forwarding to rsyslog server or similar, in such cases, since base memory has its limits in a memory resident OS approach.

I have seen references to TrueNAS once booting from USB thumb drives, only to see warnings that the thumb drives quickly become exhausted, so that suggests TrueNAS when booting from USB thumb drive was never memory resident.

Is there any plans, efforts to make TrueNAS memory resident, as a pre-cursor to booting to a stateless system, then once up, pull personality, i.e. configuration from say a HTTP/HTTPS source point? Would be interesting would it not?
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,456
Prior to the release of FreeNAS 9.3 in 2014, the OS was loaded into a RAMdisk at boot (most often, but certainly not always, from a USB stick), and writes only happened when system updates took place or changes to the configuration were made. With the release of FreeNAS 9.3, iX moved to the current model, which has the OS live on a live ZFS pool. I'd expect the chance they'll change from that is effectively zero.
 

Jibun no Kage

Dabbler
Joined
May 18, 2023
Messages
15
Yeah... Too bad they moved away from the idea... but I can see the logic. Well, was in interesting idea.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,456
The live ZFS pool provides data integrity and snapshots/boot environments, to name two important features. I'd consider it an overall win, but that doesn't mean it's an unmitigated plus for everyone.
 

Jibun no Kage

Dabbler
Joined
May 18, 2023
Messages
15
I have a long history with stateless systems, and since I can implement them with ease, it was a thought, why have any bootable media, at all. This is not to say any other strategy is better or worse at all, just would be an interesting option to have, IMHO.

I am building a new frame, boot OS on IR RAID-1, may even add SSD to give the ZFS boot a recovery point, have not decided if I need or want that level of recovery, I don't have any thing that mission critical. But since the new frame will have ECC, maybe. My first frame was really to spend time with TrueNAS, after using other solutions. So it was not ECC (yes I know), and not a lot of real estate.
 

Davvo

MVP
Joined
Jul 12, 2022
Messages
3,147
Take a look at the following resource.

With the multi report script you can (among other things) regularly get a backup of your config: if your OS drive dies you just need to swap it, reinstall it and import the config.
I guess investing in parity for the boot OS Is worth only if you can't easily access the system or you want to reduce downtime.
 
Last edited:

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,681
Yeah... Too bad they moved away from the idea... but I can see the logic. Well, was in interesting idea.

Obviously you can still do it with the typical bootstrap-and-handoff technique, but it'd be rather hacky and you'd need to work out custom mechanisms to also instantiate the config database, etc. The habit the system has of handling some stuff such as database upgrades by assuming persistence would be a bit challenging. It's not clear it'd be worth it; it's plenty easy to bootstrap a standard FreeBSD system via PXE and avoid a lot of unnecessary drama caused by fighting the paradigm.
 

Jibun no Kage

Dabbler
Joined
May 18, 2023
Messages
15
@Davvo, yes, completely doable IMHO. And... I had actually already read the reference you noted. Was interesting reading, and excellent discussion.

@jgreco, as an interesting idea, I may try such in the near future just for the challenge. I spent some time bootstrapping FreeBSD years ago, when I first setup KVM and was using iP:XE for various diskless VMs, in my home environment.

For now going to just get my new frame up, and in use. Even the IR RAID-1 is a bit over kill for my home use, I happen to have the LSI card, a couple of smaller SSDs, so using them makes sense. The big change, in my new frame, for my use, is moving to ECC enabled hardware.
 
Top