Fixing Critical OPNSense Issues, by Restoring from Backup 🗄️

Very occasionally things go wrong with OPNSense. Sometimes this may mean that the web interface or even SSH access is unavailable. Thankfully FreeBSD is configured to store recent system snapshots, and restoring from one is super easy.

  1. Power down the system
  2. Plug in a keyboard and monitor
  3. Power up the system, this may take a few minutes
  4. When prompted for credentials, log in as root
  5. From the main menu, enter 13 (restore from backup)
  6. Choose a recent backup, ideally a few hours before the issue occurred. Enter the corresponding number, and press enter
  7. Press Y for reboot when complete
  8. Once the system has rebooted, log back in as root
  9. Select option 11, reload all services
  10. A few minutes later your networking should now be restored, and the web interface accessible

😊

A couple of things to note

  • It sometimes takes up to 10 minutes for the login prompt to display, this is normal
  • In the meantime, a whole load of logs will scroll past, including some warnings, but do not worry
  • Once a backup has been restored, you'll often need to reload the services before functionality is recovered

Remember to make frequent backups of your system. This can be done from the UI, under System --> Configuration --> Backups.
In doing so, it means that if your system is unable to be repaired, or restored from a system backup, you can calmly reset to defaults or even reinstall OPNSense all together, without needing to worry about re-configuring everything from scratch.