OPNsense Forum

Archive => 16.1 Legacy Series => Topic started by: cbb09 on July 05, 2016, 05:36:32 pm

Title: Restore config during install
Post by: cbb09 on July 05, 2016, 05:36:32 pm
Hello,

I was wondering if there's a way to restore a configuration backup file during installation like this one: https://doc.pfsense.org/index.php/Automatically_Restore_During_Install

Many thanks!
-C
Title: Re: Restore config during install
Post by: franco on July 06, 2016, 04:30:55 pm
Hi C,

We've removed the autoloading a long time ago. Some people have been using USB images that they mount and modify /usr/local/etc/config.xml accordingly before installation. You can also build your own images with prebuilt sets and change the config.xml from the build system. It takes just a few seconds (in a set up build host running FreeBSD) to produce a custom image with those.

Others have asked to implement unattended installations, which would probably be the ultimate goal, but we never made it out of the concept phase, mostly because having something work in unattended mode requires a different images to be released.

Open for ideas. :)


Cheers,
Franco
Title: Re: Restore config during install
Post by: cbb09 on July 08, 2016, 05:25:57 am
Thank you for the quick response
Title: Re: Restore config during install
Post by: cbb09 on July 10, 2016, 04:04:47 am
Some people have been using USB images that they mount and modify /usr/local/etc/config.xml accordingly before installation.

Hi Franco, I've tried to mount the usb drive after dd'ing the OPNsense img, but it only mounts the 26MB boot partition (on linux and OS X) and I cannot figure out how to mount the main partition. Any thoughts?

Thanks!
Title: Re: Restore config during install
Post by: franco on July 11, 2016, 11:23:43 am
This only works on FreeBSD, as it's a native file system.
Title: Re: Restore config during install
Post by: bartjsmit on July 11, 2016, 11:33:34 am
Have you tried this from a Linux host?

   sudo modprobe ufs
   sudo mount -t ufs -o ufstype=ufs2 /dev/sdxx /mnt

also try without -o ufstype=ufs2

Bart...