9 thoughts on “How to setup a mail server with virtual domains using Postfix, Dovecot and OpenDKIM”

  1. Following your instructions, I’m not able to login to the smtp using Thunderbird. Also postfix sends emails via root@DOMAIN instead of the created user.

    Please help.

    Reply
    • Make sure the mail_location and directory permissions are correct. You should also check the log files for error messages.

      Reply
  2. Should/can the ‘group = postfix’ rather than ‘vmail’ under ‘unix_listener /var/spool/postfix/private/auth {‘.

    Does ‘service auth {‘ section require ‘user = dovecot’ or ‘root’?

    If possible, it would be helpful to know why the following are required and at what point each helps in the mail receipt or delivery process:

    usermod -aG vmail postfix
    usermod -aG vmail dovecot

    Appreciate the post.

    Reply
    • Postfix and Dovecot are added to the vmail group because it is essential for the email server to work due to the vmail ownership of the files responsible for email handling.

      Reply
  3. I’ve a doubt, what are all the ports that i have to open to internet? i’ve opened 143, 465, 587, 993, there is another one that i MUST to open?

    best regards.

    Reply
  4. I have successfully installed virtual domain postfix with dovecot. email is working fine. my server supports regexp, but i am unable to write rule for following

    abc.mydomain.com should send/receive email to/from abc.mydomain.com only

    xyz.mydomain.com should send/receive email to/from xyz.mydomain.com only

    abc.blahdomain.com should send/receive email to/from abc.blahdomain.com only

    it didnt work with my regex, Please guide.

    i used trasnport

    mydomain.com . :
    .mydomain.com :
    * error: you can send email to only your domain

    Reply

Leave a Comment