Lost password
Lost the system password for RH Enterprise 3. User password works just fine but I can't change any files. Is there a way to install a new password? I have tried Red Hats "single user mode", but it went to a kernel panic each time.
Thanks
Doug VE5DA
Quoted 5 lines · Doug
Lost the system password for RH Enterprise 3. User password works just fine but I can't change any files. Is there a way to install a new password? I have tried Red Hats "single user mode", but it went to a kernel panic each time.
I haven't used RH for about 10 years, but the easiest way to handle that sort of problem (assuming you don't have the ability for a normal user to run root commands with sudo) is to boot with a CD-based distro (such as Knoppix), mount the / directory of the hard drive and edit /etc/password or /etc/shadow (if that exists) to delete the second field of the root line. Change
root:something:something_else toroot::something_else
This will allow root to login without a password.
Of course, after rebooting to your RH system and logging in as root you should immediately assign a new password with the passwd command. In addition to using Knoppix or similar, some installation CDs will allow you to mount / and edit the file in the same way (only a limited set of editors may be available, but vi or similar should be there).
Bob, N7XY
Quoted 4 lines · Doug
Lost the system password for RH Enterprise 3. User password works just fine but I can't change any files. Is there a way to install a new password? I have tried Red Hats "single user mode", but it went to a kernel panic each time.
Strange that single user mode caused a kernel panic. Do you know why? I have never experienced that before (been using RedHat, and later Fedora, since 4.something)
I am not fully sure that the RH Enterprise CDs work the same way as the Fedora ones, but you could try the following. Start with the RHEL3-CD and at the prompt write "linux rescue", you will be asked some questions about keyboard, language etc. When it is ready, and you get a normal console prompt, you write "chroot /mnt/sysimage" (this is also displayed as a help before you are presented with the prompt). You can now simply use the passwd-command to change the root-password.
73 de Lars, sm6rpz
Signature · 2 lines
Lars E. Pettersson <[email protected]> http://www.sm6rpz.se/
Hi-
A more secure way to update your root password with a (Live|rescue)CD
is to mount your root partition somewhere, chroot to it and then run 'passwd'. Of course, this only works if you have one partition for both your /etc directory and /usr directory. If not, you can always mount the respective partitions at their appropriate locations.
The advantage of this is that your machine never has a blank root
password.
-Robin K.
Quoted 37 lines · Bob Nielsen
Quoted 5 lines · Doug
Lost the system password for RH Enterprise 3. User password works just fine but I can't change any files. Is there a way to install a new password? I have tried Red Hats "single user mode", but it went to a kernel panic each time.
I haven't used RH for about 10 years, but the easiest way to handle that sort of problem (assuming you don't have the ability for a normal user to run root commands with sudo) is to boot with a CD- based distro (such as Knoppix), mount the / directory of the hard drive and edit
/etc/passwordor/etc/shadow(if that exists) to delete the second field of the root line. Changeroot:something:something_else to
root::something_elseThis will allow root to login without a password.
Of course, after rebooting to your RH system and logging in as root you should immediately assign a new password with the passwd command. In addition to using Knoppix or similar, some installation CDs will allow you to mount / and edit the file in the same way (only a limited set of editors may be available, but vi or similar should be there).
Bob, N7XY
-
To unsubscribe from this list: send the line "unsubscribe linux-hams" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 10 lines · Robin Kauffman
Hi-
A more secure way to update your root password with a (Live|rescue)CD
is to mount your root partition somewhere, chroot to it and then run 'passwd'. Of course, this only works if you have one partition for both your /etc directory and /usr directory. If not, you can always mount the respective partitions at their appropriate locations.
The advantage of this is that your machine never has a blank root
password.-Robin K.
Still another possibility is to append "init=/bin/bash" to the kernel line. This will boot the system, and instead of starting sysvinit via /sbin/init, will immediately execute a shell with an effective UID of
0. Once that's done, remount the root partition read-write via "mount -o remount,rw /" use the passwd command to change the password, and power-cycle the machine.
Jeremy, NW7JU
Doug,
Boot from the install disk in recovery mode. You can do the following:
# chroot /mnt/sysimage # passwd root
Then you can just set it. Just exit out until the shell stops and the system will reboot.
Good luck.
Jim - KC9AOP
Quoted 15 lines · Doug
Lost the system password for RH Enterprise 3. User password works just fine but I can't change any files. Is there a way to install a new password? I have tried Red Hats "single user mode", but it went to a kernel panic each time.
Thanks
Doug VE5DA
-
To unsubscribe from this list: send the line "unsubscribe linux-hams" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html