Plesk Password retrieval via the command line (Linux / Windows)

Want to help support this blog? Try out Oh Dear, the best all-in-one monitoring tool for your entire website, co-founded by me (the guy that wrote this blogpost). Start with a 10-day trial, no strings attached.

We offer uptime monitoring, SSL checks, broken links checking, performance & cronjob monitoring, branded status pages & so much more. Try us out today!

Profile image of Mattias Geniar

Mattias Geniar, May 26, 2011

Follow me on Twitter as @mattiasgeniar

Plesk Controlpanel has several tools to retrieve the ‘admin’ password to gain entrance to the Controlpanel. Up to version 10.2 these were just unencrypted text files (say what?) on the server. Since 10.2 you need to use a command to retrieve them in plain text (sounds better, doesn’t it?).

Linux

For all versions lower than 10.2, just use the following at a shell:

# cat /etc/psa/.psa.shadow

For all versions higher than 10.2, use this:

# /usr/local/psa/bin/admin --show-password

In both cases, you’ll see the admin password in plain text.

You can also use that password to log in directly to the MySQL shell.

# mysql -u admin -p`cat /etc/psa/.psa.shadow`

That line works in all versions of Plesk.

Windows

On Windows, you can use one of the following.

> "%plesk_bin%\plesksrvclient" -get
> "%plesk_bin%\plesksrvclient" -get  -nogui


Want to subscribe to the cron.weekly newsletter?

I write a weekly-ish newsletter on Linux, open source & webdevelopment called cron.weekly.

It features the latest news, guides & tutorials and new open source projects. You can sign up via email below.

No spam. Just some good, practical Linux & open source content.