[opensuse] su password lost
I can no longer access su. I have only ever used one of two passwords. Neither of them will work today. Suggestions for correction? winstephen -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Sunday 22 April 2007 09:51, StephenW wrote:
I can no longer access su. I have only ever used one of two passwords. Neither of them will work today.
Suggestions for correction?
winstephen
You can try this: http://en.opensuse.org/Recover_Root_Password -- Regards, Rajko. http://en.opensuse.org/Portal -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
StephenW wrote:
I can no longer access su. I have only ever used one of two passwords. Neither of them will work today.
Suggestions for correction?
winstephen
You would normally use the root password, unless you're trying to su to another user. If you've "forgotten" the root password, it is possible to remove or replace the existing root password, by booting from a rescue disk and manipulating the /etc/password and shadow files. However, I have neven had a need to do that, so I can't speak from experience. -- Use OpenOffice.org http://www.openoffice.org -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
StephenW wrote:
I can no longer access su.
Then you have no access to root. By the way, it's not the su password, it's the password for the root account
I have only ever used one of two passwords. Neither of them will work today.
Suggestions for correction?
(1). use a recovery disk (2). mount your root partition as a non-root filesystem. (3). Use your favorite editor (vi, emacs, whatever) to edit the file {mountpoint}/etc/passwd and on the line that starts: root: change it from something like either of these lines: root:x:0:0:root:/root:/bin/bash or root:2HxFgnYkt7:0:0:root:/root:/bin/bash to root::0:0:root:/root:/bin/bash This wipes out the password field (the characters between the 1st and 2nd ':' characters). (4) If the password field was like in the first example (an "x"), then ALSO do step (4a). (4a) Use your favorite editor (vi, emacs, whatever) to edit the file {mountpoint}/etc/shadow and on the line that starts: then change the line that starts with root to root:::::::: (that's 8 ':' characters). (5) reboot the system (WITHOUT the rescue disk), and then (6) login to root for the password, type nothing and just hit the return key. (7) now that you are logged in as root, type the command # passwd this will allow you to change the password (8) This is THE MOST IMPORTANT PASSWORD ON THE SYSTEM REMEMBER YOUR ROOT PASSWORD! MAKE IT SOMETHING THAT YOU *NEVER* NEED TO WRITE DOWN (as usual, don't use the names of your pets, relatives, cars, or anything else which could be guessed by someone who knows you). -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
StephenW wrote:
I can no longer access su. I have only ever used one of two passwords. Neither of them will work today.
Suggestions for correction?
Assuming you mean that you don't know your root password any more, the normal way to fix this is to boot into single user mode and then just use the passwd command to change it to something you will remember in the future. Under openSUSE 10.2, you just type in " single" after selecting the boot kernel. However, it seems the openSUSE 10.2 defaults to a 'secure' terminal, so even then it asks you for you root password. So that isn't going to work. Otherwise, I guess try some of the other options already mentioned here. -- Jonathan Arnold (mailto:jdarnold@buddydog.org) Daemon Dancing in the Dark, an Open OS weblog: http://freebsd.amazingdev.com/blog/ UNIX is user-friendly. It's just a bit picky about who its friends are. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Mon, 23 Apr 2007 10:41:15 -0400
Jonathan Arnold
Assuming you mean that you don't know your root password any more, the normal way to fix this is to boot into single user mode and then just use the passwd command to change it to something you will remember in the future. Under openSUSE 10.2, you just type in " single" after selecting the boot kernel. However, it seems the openSUSE 10.2 defaults to a 'secure' terminal, so even then it asks you for you root password. So that isn't going to work. This has been the default for a number of SuSE (and other Linux) releases.
A number of ways have already been discussed.
--
Jerry Feldman
On Sunday 22 April 2007, StephenW wrote:
I can no longer access su. I have only ever used one of two passwords. Neither of them will work today.
Suggestions for correction?
winstephen
boot the system using a knoppix or similar live cd mount the / partition of the main hard drive (the one you screwed uo the password on) best seems to be to mount it on /mnt/maindisk or something siomilar AFAIK it has to be in a directory UNDER /mnt of the running system once mounted "chroot /mnt/main" passwd enter new password for root user reneter new password for root user new password saved . unmount the mounted hard drive reboot new password in use . I have had to do this on several differing systems suse simply mephis slackware .. never failed yet .. have fun Pete . -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (7)
-
Aaron Kulkis
-
James Knott
-
Jerry Feldman
-
Jonathan Arnold
-
peter nikolic
-
Rajko M.
-
StephenW