Tuesday, July 26, 2011

How to change the password of the openvz vps

Advertisements

Here the steps to change the password of the openvz vps or virtual private server from the command line.


[root@test ~]# vzlist -a | grep 192.168.0.100
       462        245 running   192.168.0.100    abc.xyx.com

Always take back up of configuration file before you do anything
[root@test ~]# cp /etc/sysconfig/vz-scripts/462.conf{,bfchpass}

Syntax
vzctl set VE_ID --userpasswd root:[newpasswd] --save

[root@test ~]# vzctl set 462 --userpasswd root:abc123$ --save
Changing password for user root.
passwd: all authentication tokens updated successfully.
Saved parameters for CT 462
[root@test ~]#

No comments:

Post a Comment

Be nice. That's all.