It was that time again. We had to change the root password. I changed it on the first workstation and it failed. Why? The /etc/nsswitch.conf file was initially setup for NIS+ and then files. I had to swap them.
Here's the error message: "passwd: Unsupported switch entry for "passwrd:", Use "-r repository". Unexpected failure. Password file/table unchanged.
Here's how it was setup.
passwd: nisplus files
group: nisplus files
Change to the following:
# vi /etc/nsswitch.conf
passwd: files nisplus
group: files nisplus
...
:wq! (saves and quits vi)
Then I proceeded with the root password change
# passwd root
...or as Cass pointed out
For Files
# passwd -r files root
# passwd -r file username
For NIS+
# passwd -r nisplus username
This blog covers Unix system administration HOWTO tips for using inline for loops, find command, Unix scripting, configuration, SQL, various Unix-based tools, and command line interface syntax. The Unix OS supports tasks such as running hardware, device drivers, peripherals and third party applications. Share tips/comments. Read the comments. But most importantly: Read Disclaimer - Read Disclaimer.
2 comments:
Not to detract from your method, but you could have just used
passwd -r files root
save any trouble with nsswitch.conf
Cass
I appreciate the tip and gaining more knowledge from contributors like you. Thanks Cass.
Post a Comment