Cant Open /dev/null: no such file or folder when using passwd in rescue mode

General support questions
Post Reply
jballester
Posts: 3
Joined: 2018/01/11 23:08:40

Cant Open /dev/null: no such file or folder when using passwd in rescue mode

Post by jballester » 2018/01/11 23:13:20

Im trying to reset my root password but when i used the passwd command the following error occurr:

Can't open /dev/null: no such file or folder found.

I check directory and file and it exists. How can i work with this problem.

thanks

User avatar
TrevorH
Forum Moderator
Posts: 23471
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Cant Open /dev/null: no such file or folder when using passwd in rescue mode

Post by TrevorH » 2018/01/11 23:31:17

CentOS 5 died in March 2017 - migrate NOW!
Full time Geek, part time moderator. Use the FAQ Luke

jballester
Posts: 3
Joined: 2018/01/11 23:08:40

Re: Cant Open /dev/null: no such file or folder when using passwd in rescue mode

Post by jballester » 2018/01/12 10:35:37

Thanks for your reply.

Yes, i did it yesterday and try again using your link but with the same result.

When i type passwd, instead of ask for username, the error Cant Open /dev/null: no such file or folder occur.

jballester
Posts: 3
Joined: 2018/01/11 23:08:40

Re: Cant Open /dev/null: no such file or folder when using passwd in rescue mode

Post by jballester » 2018/01/12 15:31:52

Finally i solve the problem.

After the mount -o remount;rw /sysroot command...

I have to use this one...

mknod /dev/null/ c 1 3 and hit enter.

Then i used the passwd command without problems.

Thanks for your help.

Post Reply