How to change cPanel password from command line

1) Access the server as a root user through SSH

2) Execute following command
# /scripts/chpass username password
where
username : cPanel account username
password : new password you wish to set
Note: password should not contain special characters
3) Synchronize the new password with the default FTP user
# /scripts/ftpupdate
If any feedback, queries are always welcome!

===
ERROR: /usr/local/cpanel/scripts/realchpass
Invocation changes only the system
password and does not have any effect
on other services associated with your
cPanel account, including FTP, SSH,
WebDAV, and FrontPage. It is strongly
encouraged for you to change the
password via the WHM & cPanel
interface. You can force a password
change through this script by setting
the environment variable
‘ALLOW_PASSWORD_CHANGE=1’.

solution:

export ALLOW_PASSWORD_CHANGE=1

==

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s