l*****n 发帖数: 12 | 1 Here is the scenario:
I ftped passwd to windows.
And modify it a little bit.
Then ftp it back.
Noboday can log int the machine now.
I guessed it is because there is an Control-M at the end
of each line.
But how to solve it?
Is there a solution for this? |
l***y 发帖数: 11 | 2 Yes, you found the problem.
Try to write a small program to replace those newline characters.
【在 l*****n 的大作中提到】 : Here is the scenario: : I ftped passwd to windows. : And modify it a little bit. : Then ftp it back. : Noboday can log int the machine now. : I guessed it is because there is an Control-M at the end : of each line. : But how to solve it? : Is there a solution for this?
|
l*****n 发帖数: 12 | 3 But how? I can not access that file now.
How to access it in the first place?
Thanks very much
【在 l***y 的大作中提到】 : Yes, you found the problem. : Try to write a small program to replace those newline characters.
|
l***y 发帖数: 11 | 4 I think you're the system administrator. Don't worry. Ask your superior to reset it. I don't know how to do it.
【在 l*****n 的大作中提到】 : But how? I can not access that file now. : How to access it in the first place? : Thanks very much
|
l*****n 发帖数: 12 | 5 I do know the root password. But noweven root can not log in.
The other group memeber s will be mad at me since they can not
access also.
Who ca nsave me ?
【在 l***y 的大作中提到】 : I think you're the system administrator. Don't worry. Ask your superior to reset it. I don't know how to do it.
|
T********r 发帖数: 6210 | 6 try to boot into single user mode (search google for FAQs
for your UNIX system, i.e. Solaris FAQs if you are using
Solaris), and then mount the file system which contains
/etc, move passwd to passwd.bak, and create a new passwd
file as:
echo "root::0:0::/:/bin/sh" > passwd
then reboot the machine, login as root and modify the
passwd.bak to remove ^M, copy it back to passwd.
【在 l*****n 的大作中提到】 : I do know the root password. But noweven root can not log in. : The other group memeber s will be mad at me since they can not : access also. : Who ca nsave me ?
|