How do I reset username and password? (in Linux Kernel 2.4.26)
I bought an older Laptop for my son. It has Pentium 133mhz (yes, it is old). It came with Linux. My son wants to keep the Linux. When I turn it on, it is going through bunch of stuff that I am not familiar with. And, it stops at 'box login:'. I don't know what to enter at this point. A random entry is resulting prompt 'Password:'. Is there any way to reset these? Do I need to reinstall Linux. I noticed following also (if helps):
LILO 22.5.7.2 I also noticed the following during start up: Linux Kernerl 2.4.26 Thanks for any help. |
You may well want to reinstall Linux, as that sounds like a rather old distribution. However, there are several ways to reset this, if you do not mind messing with some configuration files. Could you give me any more details about the system? The Linux distribution you are running would be especially helpful.
|
Quote:
|
You may have been jotting down parts of some bootup messages. The numbers you noted are the version numbers. But since you get to the log screen, it sounds like it is booting OK. You just need to zero out the passwords temporarily so you can log in.
Normally, I would recommend wiping the hard drive and installing a fresh distro after buying a used machine. However given the age of this laptop, finding a light enough distribution may take some work. At the initial boot menu, is there a "Rescue" menu item? If not try entering "rescue" in the line with boot options (probably at the bottom of the screen). It sounds like you forgot the usernames & passwords, and need to edit a file to temporarily reset them. Another option is booting from the install disc for the distro and entering "rescue" on it's boot options line. If you have a live distro, such as knoppix, you can boot the machine up to that. Post back and we can tell you how to find the user names and edit the /etc/passwd file to allow you to log in. Good Luck! |
On a machine that old Slax is one of the linux distributions that would work like a charm (there are some others like Damn Small Linux but Slax is friendlier). It is relatively small, is fast and it is Free as most Linux distros.
With a usb or CD-rom you would be able to boot Slax in to that computer and decide wether to stick with Slax (you dont even need to install if you dont want to) or even use it to reset the password of the Linux that is in the laptop installed. http://www.slax.org/ is where you can download it if interested. In my opinion that is the easiest way to go in this situation. |
Quote:
|
you could
1. keep the linux that's already installed in which case you should ask your son about the password for root then you login as root and create a new user yes, there's a way to reset the password if you have a floppy drive, you can create a rescue disk you can download one from here http://www.toms.net/rb/ then boot from the floppy, mount the partition where linux is located and cd on that partition to the etc directory there's a file named passwd check if there's a file named shadow if the answer is yes the file you need to edit is shadow, otherwise it's passwd open the file with an editor (vi, for instance) and go to the line that starts with root:....: copy that line below, and precede the original with '#', so that now it is like this #root:....:... root:....:... the (encrypted) password is all what's between the first colon ':' (after root) and the next colon remove all the characters between these two ':' in your second root line afterwards it should look like #root:c03m900...:... root::... save and exit then cd to the floppy, umount the partition, reboot (remove the floppy) at the login prompt type after your typed in 'root' you shouldn't be prompted for a password Now you can set a new password with the command passwd 2. if you prefer to install a new linux you might get a more recent linux than the one installed but not too new, especially if you want a graphical interface you can try slackware and select xfce as the window manager (kde might not work on your laptop if you don't have enough RAM) if you want to try out slax (as suggested below) the more recent ones won't probably work (they use kde and require at least 256MB of RAM) you can try the versions 5.something that have xfce |
Quote:
|
Quote:
I thought 'bought the laptop' FROM 'his son' should have read more carefully well, in this case they'll have to remove the old password in /etc/shadow (if it exists, otherwise in /etc/passwd), reboot and reset the root password |
|
All times are GMT -5. The time now is 11:19 PM. |