Using chpasswd to change account passwords on Linux

The chpasswd command allows admins to change account passwords by piping username and password combinations to it.

This can be done one-account-at-a-time or by putting all of the accounts to be modified in a file and piping the file to the command.

[Get regularly scheduled insights by signing up for Network World newsletters.]
How to use chpasswd

Using the chpasswd command requires root privilege. You can switch to the root account and run a command like this:

# echo nemo:imafish | chpasswd

Better yet, you can use sudo with a command like this:

To read this article in full, please click here

Source:: Network World – Data Center