postfix(1)
Postfix mail server control and management command for starting, stopping, and monitoring the mail system.
Synopsis
postfix [-c config_dir] [-D] [-v] {start|stop|reload|flush|check|status|set-permissions|upgrade-configuration}Description
The postfix command controls the Postfix mail server, a modular mail transfer agent (MTA) that routes and delivers email. It manages the lifecycle of Postfix processes and performs system configuration tasks.
Most commands require root or equivalent privileges. The command reads configuration from the main.cf file in the Postfix configuration directory (default /etc/postfix).
Common operations include starting the background daemon, reloading configuration, flushing queued mail, and verifying system setup. Use postfix check before starting to catch configuration errors early.
Common options
| Flag | What it does |
|---|---|
-c config_dir | Specify alternate configuration directory (default: /etc/postfix) |
-D | Enable verbose logging and don't detach from controlling terminal |
-v | Enable verbose output for diagnostic information |
Examples
Start the Postfix mail server daemon in the background
sudo postfix startStop the Postfix mail server gracefully
sudo postfix stopReload configuration without stopping active connections
sudo postfix reloadVerify basic Postfix configuration and directory permissions
postfix checkShow whether Postfix is running and the status of mail queues
postfix statusForce delivery attempt of all queued messages immediately
sudo postfix flushStart Postfix using alternate configuration directory
sudo postfix -c /etc/postfix.backup startUpgrade configuration files for the current Postfix version
sudo postfix upgrade-configuration