FOR BOTH LINUX AND WINDOWS SERVERS:
In a shared server(both linux and windows), it is quite tedious to determine the email password for email accounts if you are not much familiar with MySQL. But you can use the following command to retrieve all the email password for a domain.

=======
SELECT mail.mail_name, accounts.password FROM domains LEFT JOIN mail ON domains.id = mail.dom_id LEFT JOIN accounts ON mail.account_id = accounts.id WHERE domains.name = ‘yourdomain.com’
=======

Steps:
1. Login to MySQL prompt
[For Linux]
mysql -uadmin -p`cat /etc/psa/.psa.shadow`
[For Windows]
1. Retrieve the Plesk password [ cd %plesk_bin%, plesksrvclient.exe -get ]
1. Goto plesk directory [cd %plesk_dir%]
2. Goto the bin folder of the MySQL directory [cd Databases\MySQL\bin
mysql.exe -uadmin -penter_password_here -P8306

2. Use psa database;
use psa;

3. Execute the following query

======
SELECT mail.mail_name, accounts.password FROM domains LEFT JOIN mail ON domains.id = mail.dom_id LEFT JOIN accounts ON mail.account_id = accounts.id WHERE domains.name = ‘domain.com’;
======

===============

ONLY FOR LINUX SERVERS:

Alternatively, for Linux servers you can use the following command to retrieve the email password for a specific mail account.

==========
/usr/local/psa/admin/bin/mail_auth_view |grep name@domain.com
==========

Leave a Reply

This website stores cookies on your computer. These cookies are used to provide a more personalized experience and to track your whereabouts around our website in compliance with the European General Data Protection Regulation. If you decide to to opt-out of any future tracking, a cookie will be setup in your browser to remember this choice for one year.

Accept or Deny