Postfix | Can send emails but I can't receive any

Discussion in 'Server Operation' started by Jocker, Aug 23, 2018.

  1. Jocker

    Jocker New Member

    Hello, that's oddly weird because I can send emails fine but I can't receive any back.
    I use roundcube on Debian 9 Stretch

    main.cf
    Code:
    compatibility_level = 2
    #queue_directory = /var/spool/postfix
    command_directory = /usr/sbin
    daemon_directory = /usr/lib/postfix/sbin
    data_directory = /var/lib/postfix
    myhostname = info.example.com
    mydomain = example.com
    inet_interfaces = all
    unknown_local_recipient_reject_code = 550
    mynetworks_style = host
    mynetworks = 127.0.0.0/8, 192.168.0.0/24
    alias_maps = hash:/etc/aliases
    alias_database = hash:/etc/aliases
    recipient_delimiter = +
    smtpd_banner = $myhostname ESMTP
    debugger_command =
        PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
        ddd $daemon_directory/$process_name $process_id & sleep 5
    sendmail_path = /usr/sbin/postfix
    newaliases_path = /usr/bin/newaliases
    _path = /usr/bin/mailq
    setgid_group = postdrop
    inet_protocols = ipv4
    message_size_limit = 10485760
    mailbox_size_limit = 1073741824
    smtpd_sasl_type = dovecot
    smtpd_sasl_path = private/auth
    smtpd_sasl_auth_enable = yes
    smtpd_sasl_security_options = noanonymous
    smtpd_sasl_local_domain = $myhostname
    smtpd_recipient_restrictions = permit_mynetworks,permit_auth_destination,permit_sasl_authenticated,reject
    virtual_mailbox_domains = info.example.com
    virtual_mailbox_base = /home/vmail
    virtual_mailbox_maps = hash:/etc/postfix/virtual-mailbox
    virtual_uid_maps = static:20000
    virtual_gid_maps = static:20000
    smtpd_use_tls = yes
    smtpd_tls_cert_file = /etc/postfix/tls/smtpd.pem
    smtpd_tls_key_file = /etc/postfix/tls/smtpd.pem
    smtpd_tls_CAfile = /etc/postfix/tls/smtpd.pem
    smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
    smtpd_tls_security_level = may
    smtp_tls_security_level = may
    smtp_tls_CAfile = /etc/postfix/tls/smtpd.pem
    smtp_tls_cert_file = /etc/postfix/tls/smtpd.pem
    smtp_tls_key_file = /etc/postfix/tls/smtpd.pem
    smtp_tls_session_cache_database = btree:${queue_directory}/smtp_scache
    smtp_use_tls = yes
    smtpd_tls_received_header = yes
    smtpd_tls_ask_ccert = yes
    smtpd_tls_loglevel = 1
    tls_random_source = dev:/dev/urandom
    smtp_tls_CApath = /etc/ssl/certs
    smtpd_tls_CApath = /etc/ssl/certs
    
    master.cf
    Code:
    # ==========================================================================
    # service type  private unpriv  chroot  wakeup  maxproc command + args
    #               (yes)   (yes)   (no)    (never) (100)
    # ==========================================================================
    smtp      inet  n       -       y       -       -       smtpd
    smtps     inet  n       -       y       -       -       smtpd
      -o syslog_name=postfix/smtps
      -o smtpd_tls_wrappermode=yes
    
    #628       inet  n       -       y       -       -       qmqpd
    pickup    unix  n       -       y       60      1       pickup
    cleanup   unix  n       -       y       -       0       cleanup
    qmgr      unix  n       -       n       300     1       qmgr
    #qmgr     unix  n       -       n       300     1       oqmgr
    tlsmgr    unix  -       -       y       1000?   1       tlsmgr
    rewrite   unix  -       -       y       -       -       trivial-rewrite
    bounce    unix  -       -       y       -       0       bounce
    defer     unix  -       -       y       -       0       bounce
    trace     unix  -       -       y       -       0       bounce
    verify    unix  -       -       y       -       1       verify
    flush     unix  n       -       y       1000?   0       flush
    proxymap  unix  -       -       n       -       -       proxymap
    proxywrite unix -       -       n       -       1       proxymap
    smtp      unix  -       -       y       -       -       smtp
    relay     unix  -       -       y       -       -       smtp
    #       -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
    showq     unix  n       -       y       -       -       showq
    error     unix  -       -       y       -       -       error
    retry     unix  -       -       y       -       -       error
    discard   unix  -       -       y       -       -       discard
    local     unix  -       n       n       -       -       local
    virtual   unix  -       n       n       -       -       virtual
    lmtp      unix  -       -       y       -       -       lmtp
    anvil     unix  -       -       y       -       1       anvil
    scache    unix  -       -       y       -       1       scache
    
    maildrop  unix  -       n       n       -       -       pipe
      flags=DRhu user=vmail argv=/usr/bin/maildrop -d ${recipient}
    
    uucp      unix  -       n       n       -       -       pipe
      flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
    #
    # Other external delivery methods.
    #
    ifmail    unix  -       n       n       -       -       pipe
      flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
    bsmtp     unix  -       n       n       -       -       pipe
      flags=Fq. user=bsmtp argv=/usr/lib/bsmtp/bsmtp -t$nexthop -f$sender $recipient
    scalemail-backend unix    -    n    n    -    2    pipe
      flags=R user=scalemail argv=/usr/lib/scalemail/bin/scalemail-store ${nexthop} ${user} ${extension}
    mailman   unix  -       n       n       -       -       pipe
      flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py
      ${nexthop} ${user}
    
    mail.log
    Code:
    dovecot: imap-login: Login: user=<[email protected]>, method=CRAM-MD5, rip=::1, lip=::1, mpid=1661, secured, session=<SRAwMg909q0AAAAAAAAAAAAAAAAAAAAB>
    dovecot: imap([email protected]): Logged out in=50 out=511
    dovecot: imap-login: Login: user=<[email protected]>, method=CRAM-MD5, rip=::1, lip=::1, mpid=1663, secured, session=<tsuuMg90+K0AAAAAAAAAAAAAAAAAAAAB>
    dovecot: imap([email protected]): Logged out in=159 out=1043
    dovecot: imap-login: Login: user=<[email protected]>, method=CRAM-MD5, rip=::1, lip=::1, mpid=1665, secured, session=<0MO4Mg90+q0AAAAAAAAAAAAAAAAAAAAB>
    dovecot: imap([email protected]): Logged out in=159 out=1043
    postfix/smtpd[1667]: connect from mail-oi0-f50.google.com[209.85.218.50]
    postfix/smtpd[1667]: Trusted TLS connection established from mail-oi0-f50.google.com[209.85.218.50]: TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)
    postfix/trivial-rewrite[1669]: warning: do not list domain info.example.com in BOTH mydestination and virtual_mailbox_domains
    postfix/smtpd[1667]: 1564B19F68: client=mail-oi0-f50.google.com[209.85.218.50]
    postfix/cleanup[1670]: 1564B19F68: message-id=<CAJGcSDS37koObns3Yk76F_x6=y5pWW6e4O1T44GeNL3F+h0Hvg@mail.gmail.com>
    postfix/qmgr[649]: 1564B19F68: from=<[email protected]>, size=7673, nrcpt=1 (queue active)
    postfix/trivial-rewrite[1669]: warning: do not list domain info.example.com in BOTH mydestination and virtual_mailbox_domains
    postfix/local[1671]: 1564B19F68: to=<[email protected]>, relay=local, delay=0.29, delays=0.27/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)
    postfix/qmgr[649]: 1564B19F68: removed
    postfix/smtpd[1667]: disconnect from mail-oi0-f50.google.com[209.85.218.50] ehlo=2 starttls=1 mail=1 rcpt=1 data=1 quit=1 commands=7
    
     
  2. Please confirm your MX record is correctly set in the dns and the Server hostname is pointed to the Server IP.
     

Share This Page