During the installation and setup of any linux distro using the Lilo bootloader, it is quite comfortable to know that you can change or erase the password of the root account if something should go wrong. What happened to me was that the system locale (language) simply made typing my password impossible. If you use Lilo, this is not a reason to re-install.
In the boot process you can press TAB to get up a bash console.
Mount the root filesystem (‘/’) read-write and set the password with command: passwd root
Run sync and reboot using /sbin/reboot
See Zenwalk wiki’s Lost root password for step by step guide
When you are finished setting up the system and want to start using it, however, allowing any user to pass boot parameters with the possibility of bypassing the root password is clearly a security issue. To restrict access to running parameters in Lilo, you can either edit the global or the individual bootimage settings.
Global
add ‘password = secretpass‘ to /etc/lilo.conf
chmod lilo.conf 600 and set owner to root (step by step guide above)
run lilo -v
Individual boot image
specify the password (as above) under each boot entry you have in lilo.conf
and add ‘restricted’ at the end of the entry
chmod lilo.conf 600 and set owner to root (step by step guide above)
run lilo -v
Links:
- Lost root password at the Zenwalk Wiki
- Lilo configuration and usage by Mayank Sarup
Note: If you edit global settings, you will have to enter the password each time you boot.
Hey, do you use DD-WRT by any chance?
Personally I have the WRT54GC (which isn’t DD-WRT according to Wikipedia), but I bought a DD-WRT using router to a client recently.
Let me guess, VPN problems?
Well, the VPN problem has been resolved, but now I’m trying to figure out how to add users. DD-WRT doesn’t come with “adduser” command.