Persisting pfSense nanobsd /tmp and /var across reboots

  • I'm a new pfSense user, I just got 2.2.6 running on a PC Engines APU1d2 board.  The board has an 8 GB SD card with the embedded nanobsd pfSense image on it.  The board also has a 60 GB mSATA SSD installed.

    These APU boards have enough RAM for a healthy sized /var filesystem running from RAM.  It would be nice to be able to persist this across reboots by syncing to/from the SSD during shutdown and bootup.

    Is there an easy way to do this?  To have pfSense copy the contents of /var and /tmp to the SSD (currently mounted as /ssd) during shutdown, and then during bootup, copy them back from the SSD to the /var and /tmp ramdisks during startup?

    My thinking is that using the embedded nanobsd image (vs. doing a full install to the SSD) keeps /tmp and /var in RAM, so it doesn't cause excessive wear on the SSD.  Syncing to/from the SSD at boot and shutdown time would be minimal wear since one doesn't normally reboot that often, and it should be a very fast operation (RAM to SSD and vice versa), and then I gain the benefit of persisting that data across shutdowns and reboots.

    Thank you

  • Guess I'm the only one interested in this functionality.  :-\

    I went ahead and ordered a new more durable mSATA drive, so that I can run a full install of pfSense on it.  It's an industrial mSATA drive that uses SLC, good for 8 years @ 100 GB per day of writes.  I won't have to worry about it wearing out any time soon!

Log in to reply