linux 修改用户密码的几种方法

  • passwd 命令手动修改:
[root@localhost user]# passwd user
Changing password for user user.
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.
[root@localhost user]#

  

  • passwd 命令 命令行修改
[root@localhost user]# echo 'Abc@123.'|passwd --stdin user

chpasswd 命令,命令行修改

[root@localhost user]# echo 'user:Abc@123.'|chpasswd

  

猜你喜欢

转载自www.cnblogs.com/ncyhl/p/12715496.html