LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   can't login (corrupt etc/passwd ?) (https://www.linuxquestions.org/questions/linux-general-1/cant-login-corrupt-etc-passwd-47545/)

nimrod 02-28-2003 02:35 AM

can't login (corrupt etc/passwd ?)
 
I can't login, neither vncviewer or telnet.
Samba still works.
It seems that my etc/passwd file is corrupt.
i'm quite a newbie with linux and don't know
how to fix this problem.
Should I reinstall linux (RedHat 7) or can I get
generate a new passwd file ?
Thanks for your help.

rch 02-28-2003 03:12 AM

Re: can't login (corrupt etc/passwd ?)
 
Quote:

Originally posted by nimrod
I can't login, neither vncviewer or telnet.
Samba still works.
It seems that my etc/passwd file is corrupt.
i'm quite a newbie with linux and don't know
how to fix this problem.
Should I reinstall linux (RedHat 7) or can I get
generate a new passwd file ?
Thanks for your help.

well you said that you can use samba
new passwd file is not required
can you edit the passwd file?
if yes
it should be
root:x:0:0:...blah blah
remove the x
so that it becomes
root::0:0:...
now on the login prompt
just type root
and you should get into your system
don't forget to make a new passwd!
keep posted

nimrod 02-28-2003 09:53 AM

Thanks for your answer.
I removed root password and tried to connect with SSH.
I get access denied.
I tried to log on the pc with linux,
it says that the account may have been disabled or it may be a problem with the account.
It seems that other files have been damaged.
I think it comes from a forced shutdown because of an electricity cut.
When booting I got the message that the last shutdown was not clean, I accepted automatic repair but it still doesn't work.
I think I'll format because I can retrieve all my data with samba and I need it up fast.

rch 03-01-2003 10:21 PM

Quote:

Originally posted by nimrod
Thanks for your answer.
I removed root password and tried to connect with SSH.
I get access denied.
I tried to log on the pc with linux,
it says that the account may have been disabled or it may be a problem with the account.
It seems that other files have been damaged.
I think it comes from a forced shutdown because of an electricity cut.
When booting I got the message that the last shutdown was not clean, I accepted automatic repair but it still doesn't work.
I think I'll format because I can retrieve all my data with samba and I need it up fast.

well i am indeed suprised that it did not worked
anyway hope that you have a backup of your data

bulliver 03-01-2003 10:26 PM

If you still have installation disks you should be able to type "linux rescue" at the prompt, and boot into your system without a password, wherein you can reset the passwords.


All times are GMT -5. The time now is 12:06 PM.