Articles in this section

How to get a list of mail accounts with enabled and disabled mailboxes in Plesk?

Plesk for Windows kb: how-to Plesk for Linux

Applicable to:

  • Plesk for Linux
  • Plesk for Windows

Question

How to get a list of mail accounts with enabled/disabled mailboxes in Plesk?

Answer

  1. Connect to the server via SSH/RDP

  2. Note: Additional step for a Windows server: start the Command Prompt

    To list all mailboxes with the enabled status run the command below:

    CONFIG_TEXT: plesk db -Ne "select concat(m.mail_name,'@',d.name) as mailbox, m.postbox from domains d, mail m, accounts a where m.dom_id=d.id and m.account_id=a.id and m.postbox='true'"

    To list all mailboxes with the disabled status run the command below:

    CONFIG_TEXT: plesk db -Ne "select concat(m.mail_name,'@',d.name) as mailbox, m.postbox from domains d, mail m, accounts a where m.dom_id=d.id and m.account_id=a.id and m.postbox='false'"

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.