/go/vmail: vmail from the Command Line

GoAdmio keeps its mail accounts, domains, relay settings, and filters in databases. Postfix and Dovecot read plain files. /go/vmail turns the first into the second. It: Run it when mail data looks out of date, for example after changing mail data in the databases, or when a mailbox cannot log in or receive mail. Every admin action in GoAdmio has a matching /go/ command, so anything you can click you can also script.

Quick start

/go/vmail

Examples

# Rebuild everything
/go/vmail

# Check the Postfix configuration afterwards
sudo postfix check

# See which domains Postfix now accepts mail for
cat /etc/postfix/vmail_domains

# Find mailboxes that were given the default password "Go"
sudo sqlite3 /var/lib/sqlite/mail.db "SELECT Email FROM Mail WHERE Pass='Go'"

# Check the status of the saved SMTP relays
sudo sqlite3 /var/lib/sqlite/smtp.db "SELECT SMTPHost, SMTPPort, SMTPStatus FROM SMTP"

# The relay file holds passwords. It should be readable by root only
ls -l /etc/postfix/vmail_sasl_passwd

Output

Message Meaning
VMAIL: There are currently no active domains. The Site table is empty. Exit code 1.
Instance (vmail) already running. Another run started within the last 15 minutes. Exit code 1.
Messages from postfix check A problem with the Postfix configuration or its folder permissions.
Nothing The run finished without errors.

The command also prints package-install output the first time, if opendmarc or swaks has to be installed.

See the full reference at /go/vmail and the GoAdmio command index.

GoAdmio is free and open source, with no license fees and no account limits. Read the GoAdmio docs, or see why it is a free cPanel alternative at goadmio.com.

By:

Posted in:


Leave a Reply

Your email address will not be published. Required fields are marked *