[solved] Need to restore config.xml ... root is disabled

Started by moals, February 14, 2024, 01:47:09 AM

Previous topic - Next topic
I've recently updated a couple of interface IPs and now I cannot get into the UI.  I have a console connection with an admin user, however root is disabled and my user is not in sudoers.  As such, I cannot copy a /conf/backup/config_file to /conf/config.xml.  I've tried editing the current config.xml file, however it is read only and I cannot chmod the file.  Also, I cannot run the opnsense-shell (to perform a scripted recovery?) (must be root user).

Most of the help from forums indicate doing one of the above items... given my limited experience here and that I cannot sudo or login as root, I feel like my hands are tied. 

Is there anything else that I can? I've thought of reinstalling OPNsense, then recovering one of the backups, however I came here for help first.
I appreciate whatever help that you can lend...thanks.

Do you have access to boot menu?
If you do then reboot to single mode (hit 2 on boot menu).
If asked for shell just hit enter (/bin/sh is default).
Then remount your root filesystem RW:
mount -u -o rw /

I appreciate your help.  I did have access to the boot menu, however due to time constraints, I went ahead and began a fresh install. I am going to keep your note close by for next time ...
Again, thank you very much for your help and quick reply.