Postfix Configuration File Plesk Server

Posted onby
  1. Postfix Configuration Ubuntu
  2. Postfix Configuration File Plesk Server Health Monitor
  3. Executable File
  4. Sql Server Configuration File
  5. Postfix Configuration File Plesk Server Requirements
  6. Web Configuration File

The following configuration items are not in the postfix configuration and need to be added to the /etc/postfix/ configuration file. They configure the SMTP authentication settings for the smtpd daemon. # # SMTP-AUTH configuration # # The name of the Postfix SMTP server's local SASL authentication realm. Task: Stop Postfix. Type the following command: # postfix stop. Task: Start Postfix. Type the following command: # postfix start. Task: Restart Postfix. Type the following command: # postfix stop && postfix start. Task: Reload Postfix. To re-read configuration files, enter: # postfix reload The following distribution specific commands can be used too. Configuring postfix to block all emails except the specified email accounts. If you need allow a emailing only from a particular from the postfix email server you can follow the below steps. Use Transport Mapping. Here we can tell the postfix mail server to sent or disregard the emails. For this we need to edit the postfix configuration file. Postfix logs all failed and successful deliveries to a logfile. The file is usually called /var/log/maillog or /var/log/mail; the exact pathname is defined in the /etc/syslog.conf file. ( syslog.conf specifies where the mail -facility logs get written to, it's rather self-explaining when you look at it.). Like you said your plesk install keeps starting postfix and if that is the case then you have got two options: 1. Misconfigure postfix configuration file so that plesk is not able to start it at all. However, if plesk depends on or checks the exit status whether it was able to start postfix successfully or not then you have to go with option 2.

Postfix is infinitely configurable to suit your needs. For large corporations andISPs, Postfix can be configured to use a mySQL backend instead of usingconfiguration files. Thus a quick insert or delete of a record can addusers, domains, etc. This tutorial configures Postfix to receive emailusing local configuration files.

Postfix Installation:

  • Red Hat/Fedora/CentOS: yum install postfix
  • Ubuntu/Debian: apt-get install postfix

Postfix configuration file: /etc/postfix/

(Red Hat, Fedora, Suse and Ubuntu!)


Allow no relay or outbound SMTP:

Add to file

Receive email for local users: (multiple domains can bespecified but an email sent to Michael is not distinguished betweendomains. One Michael for all domains.)

Add to file

Postfix Configuration Ubuntu

Virtual host:
(receive email for multiple domains. Users distinguished between domains.Email recipient [email protected] is different than [email protected])
Add this definition to support virtual hosts:

Add to file

Add anti-SPAM measures:

Add to file Note:
  • SpamHaus combines three blackhole lists: Exploits block list (exploited systems):, Policy block list (non-MTA IP): and Spamhaus block list:, into one ''.

Limit denial of service attacks:

Add to file

File: /etc/postfix/vhosts.txt

Domains listed here should NOT be listed with the 'mydestination' directive.

File: /etc/postfix/valias.txt

This file maps email addresses to local user names: Upon creation or change, create the db file: postmap /etc/postfix/valias.txt
ConfigurationThis creates the file /etc/postfix/valias.txt.db

File: /etc/postfix/access_sender

Generate database file 'access_sender.db': postmap /etc/postfix/access_sender
Used by directive check_sender_access hash:/etc/postfix/access_sender Other access lists:
  • IP block list used by http: Exploited server list
Postfix debugging and diagnostics: Look in log files for error messages.
  • Red Hat: /var/log/maillog
  • Ubuntu: /var/log/mail.log

Postfix Pitfalls:

  • Error in /var/log/maillog Check for other applications using port 25: fuser -uv 25/tcp
    Often Sendmail is installed by default and may be running.
    Fix: service sendmail stop; service postfix restart

Postfix configuration tutorials:

Postfix Configuration File Plesk Server Health Monitor

  • Anti-spam configuration [example]

More examples:

  • Complete mail server configurations - Debian/Ubuntu
Postfix and Mailman email list server integration and configuration:

Postfix can be configured three different ways to interface with Mailman.The following uses the /etc/aliases file for this configuration.Requires the following configuration:

File: /etc/aliases These entries are generated by Mailman. See the YoLinux Mailman tutorial.

Links on Postfix and Mailman integration:
(Three different methodologies)

  1. Postfix-Mailman integration - GNU
  2. Use regular expression in configuration: example and tutorial.
    Example configuration including apache

Executable File

Check if an open relay: (you do not want to be an open relay)

by Richard Blum
ISBN #0672321149, Sams
'Linux Email'
by Black, Koetter, Hilderbrandt, McDonald, Rusenko and Taylor.
ISBN #190481137X, Packt

I reviewed this book and found it to be a verycomplete discussion with examples of the installation, configuration,integration and use of Postfix, Courier POP/IMAP, SquirelMail,SpamAssassin, ClamAV and Cyrus SASL. It is concise and to the point.How to configure a Linux email server for the most popular and usefulserver configurations. This book is specific to the components listedand will get you up and running fast.

'Stopping Spam'
by Alan Schwartz, Debby Russell (Editor), Simson Garfinkel
ISBN #156592388X, O'Reilly and Associates
'Removing the Spam : Email Processing and Filtering'
by Geoff Mulligan
ISBN #0201379570, Addison-Wesley Networking Basics Series
Please enable JavaScript to view the comments powered by Disqus.
Active4 years, 5 months ago

I have problems connecting on SMTP to the email server.

I'm trying to send email with PHPMailer and this is the error I get:

I have tested with another email server and it works fine, so it must be something wrong with the server configuration.

The server is running Postfix, Courier Imap and Plesk control panel.

Also has installed the fail2ban tool.

Hours ago it was running Dovecot instead of Courier but I have removed it and installed Courier thinking that this will solve it but with no luck.

I have also did tweaking to Postfix but with no luck.

I'm thinking that the problem could be either misconfiguration in email server, or maybe ssl/auth issues on server, or maybe some firewall causing problems?

Just tried to connect by telnet 25 and got this:

Providing here my configuration:

And another one:

Alexandru Trandafir Catalin
Alexandru Trandafir CatalinAlexandru Trandafir Catalin
1,8192 gold badges24 silver badges34 bronze badges

1 Answer

Just found the solution by myself:


When trying to send email using Roundcube, an error occurs:

When connecting via telnet, following output is displayed:

Mail server does not return authentication mechanisms list:


Postfix misconfiguration.


Check Postfix configuration file at /etc/postfix/ . Comment thee following lines which are responsible for preventing plain text passwords and forcing SMTP connection over SSL or TLS

Sql Server Configuration File

Alexandru Trandafir CatalinAlexandru Trandafir Catalin
1,8192 gold badges24 silver badges34 bronze badges

Postfix Configuration File Plesk Server Requirements

Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.

Web Configuration File

Not the answer you're looking for? Browse other questions tagged authenticationsmtpimappostfix-mtaplesk or ask your own question.