Visit Our UNIX and Linux User Community


root password


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting root password
# 1  
Old 03-20-2002
root password

For some reason my root password is not working ... and I have no idea why

I can't log in as root and i cant su to root


Could anyone tell me how to fix this ?

running Red Hat Linux
# 2  
Old 03-20-2002
reboot and break in

There are two paths here.

One is to reboot and get back into single user mode, which doesn't require a password on 99% of UNIX flavors, when you get to the prompt type:

passwd root

That should let you change the root passwd.

The second path is not as easy. You will either need to make an alternate boot disk or reload your OS.

Also, you can search this site for others who have had problems with losing the root password. Search for "root login problems" or "no root password".

Here is one link.

https://www.unix.com/showthread.php?s...+root+password



Maybe you will get lucky and can reboot to single user mode and change the password!

Let me know how this works out!

Good Luck. Smilie
# 3  
Old 03-20-2002
ok i rebooted the machine and changed the password in single user mode. it worked perfectly.

However my problem is a little more extensive than this (as usual)

I have the same root passwd on all 4 of my servers. All running Red Hat Linux.

For some odd reason the root passwd will not work on any of my servers. It looks like someone manually changed the root passwd on all my servers (sounds like a hacker).

My question is there a way to change the root passwd on all of my servers without having to reboot every single one of them or creating boot disks ?

The reason i dont want to reboot these servers is because they are production web servers.
# 4  
Old 03-20-2002
rlogin or rcp

If you have .rhosts files established on each of the other servers, you should be able to execute. rlogin

rlogin systemname -l root

If you have the exact same passwd files, you can use rcp.

rcp mycurrentbox:/etc/passwd theotherbox:/etc/passwd

Then you can login over there as well. If they are not the same you can do this anyway and then restore you password from a backup with out interrupting the users.



If not you may need to reboot them as well.

keep me updated.
# 5  
Old 03-20-2002
ok,

here is what i did on my local server.

i added a line to my .rhost file in the root home directory :

remote.server.abc root

i set the file permissions to 600


then im using the rlogin command like this :

rlogin -l root remote.server.abc

it wont do anything, it just hangs there


do i need to edit the .rhost file in my remote server, also ??

If so, how will I be able to if the .rhost file has root permissions and i cant login as root ?

i think the .rhosts files have been created for other servers but not for my situation.

i also tried the remote copy command 'rcp' but that seems to be just hanging there also.


My local server is behind a firewall and my remote server is outside the firewall .... could that be an issue ???

btw, thanks for you help.
# 6  
Old 03-20-2002
You do need to have a .rhosts on both/all systems involved.

Also your format is wrong for the rlogin command.

rlogin hostname -l root


If this doesn't work you will have to schedule downtime to reboot.



Smilie
# 7  
Old 03-20-2002
Also (from memory) make sure that your default file (/etc/auth/system/default) still exists.

Pretty sure that's it, otheruwise you won't be able to rcmd the other server

Previous Thread | Next Thread
Test Your Knowledge in Computers #31
Difficulty: Easy
Alan Turing was the founder of IBM.
True or False?

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Can a root role change the root password in Solaris 10?

i do not have root on a solairs 10 server , however i do have the root role, i was wondering if I can change the root password as a a role with the passwd command? I have not tried yet. and do i have to use the # chgkey -p afterwards? i need to patch is why i am asking. thanks (1 Reply)
Discussion started by: goya
1 Replies

2. Ubuntu

Root access that can't change root password?

We are having a little problem on a server. We want that some users should be able to do e.g. sudo and become root, but with the restriction that the user can't change root password. That is, a guarantee that we still can login to that server and become root no matter of what the other users will... (2 Replies)
Discussion started by: 244an
2 Replies

3. Solaris

Lost Root Password on VXVM Encapsulated Root Disk

Hi All Hope it's okay to post on this sub-forum, couldn't find a better place I've got a 480R running solaris 8 with veritas volume manager managing all filesystems, including an encapsulated root disk (I believe the root disk is encapsulated as one of the root mirror disks has an entry under... (1 Reply)
Discussion started by: sunnyd76
1 Replies

4. Solaris

Solaris 8 - Asks for current root password when trying to change root password.

Hello All, I have several solaris boxes running Solaris 8. When changing root passwords on them, all will simply ask for the new root password to change and of course to re-type the new password. One of the systems however asks for the existing root password before it will display the new password... (8 Replies)
Discussion started by: tferrazz
8 Replies

5. Shell Programming and Scripting

how to change root password using shell script with standard password

Hi Friends. I am new to scripting now i want to change the root password using the script with standard password. which is the easy scripting to learn for the beginner, Thanks in advance. (2 Replies)
Discussion started by: kurva
2 Replies

6. HP-UX

Root Password

Hi all, I am changing the root password periodically from eg: password01 to password02. However, I can still use password01 after it is changed, it seems that it only authenticates up the first few characters. Please can someone let me know how I can fix this. Thanks Ryan (1 Reply)
Discussion started by: macgre_r
1 Replies

7. Linux

root password

Hi everybody: I have a problem. How does it possible that when I type the root password on terminal, later write: su password: ****** System recognize the password, but when a I use the GUI environment, the system does not recognize it. Any suggestion. :o Thanks in advance. (2 Replies)
Discussion started by: tonet
2 Replies

8. UNIX for Dummies Questions & Answers

I need it to prompt me for a root password, so I don't have to log as root

Hi folks, I'm trying to install a program, and I want to place some of the executables into /usr/bin so that they can be executed from any folder on the computer. I've been giveng the root password, but told never to log in directly as root. Instead, I can wait for a password prompt. However, I... (2 Replies)
Discussion started by: lunchtime
2 Replies

9. Linux

how to access root priveliges if root password is lost

wish to know how to access root password it root password is forgotten in linux (1 Reply)
Discussion started by: wojtyla
1 Replies

10. Answers to Frequently Asked Questions

Lost root password / Can't login as root

We have quite a few threads about this subject. I have collected some of them and arranged them by the OS which is primarily discussed in the thread. That is because the exact procedure depends on the OS involved. What's more, since you often need to interact with the boot process, the... (0 Replies)
Discussion started by: Perderabo
0 Replies

Featured Tech Videos