Can sand, can't receive emails :(

Discussion in 'Installation/Configuration' started by Hypnotize, Jan 6, 2017.

  1. Hypnotize

    Hypnotize New Member

    Hi there :)
    I accidentally forgot to install dovecot before installing ISPConfig 3 , but I managed to connect everything afterwords and it works well, but there is a little problem :/
    I can send emails (in roundcube) but I can't receive them.
    This is my postfix's main.cf
    Code:
    https://dl.dropboxusercontent.com/u/30005219/main.cf
    Can you help me with this ? :D
    Thanks in advance :)
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    which errors do you get in the mail.log when you send an email to your server?
     
  3. Hypnotize

    Hypnotize New Member

    Thanks for your reply :)

    These are the messages i get.

    I have send email from "gvardia-cs at hotmail.com" to "troy at gvardia.me" :)
     

    Attached Files:

  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Hmm, you posted here in an ispconfig forum, but the mail paths mentioned in your log files are not from an ispconfig system. Emails on ISPConfig are always in:

    /var/vmail/domain.tld/user/

    but your path is:

    /var/mail/vhosts/domain.tld/catch-all/tmp/1483721894.P23825.vmi97256.contabo.host

    Did you had mailboxes on that system before or did you had another control panel installed without doing a clean reinstall? ISPConfig just edits config files, it does not overwrite it, so if you start with an unclean system, then the resulting system will fail very likely.
     
  5. Hypnotize

    Hypnotize New Member

    Thanks once more for your reply :)
    I had some problems with postfix after installing ispconfig3, so i had to reinstall it , and now I'm stuck with this problem :/
    What should I do in order to fix it ?
    Thanks once more :)
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    Remobe thes eline sform postfix main.cf, they are from a different crontrolapenl that you must have installed first:

    Code:
    # Virtual domain config
    virtual_mailbox_domains = /etc/postfix/virtual_domains
    virtual_mailbox_base = /var/mail/vhosts
    virtual_mailbox_maps = hash:/etc/postfix/vmailbox
    # Make sure you replace these UID:GID numbers
    virtual_minimum_uid = 5010
    virtual_uid_maps = static:5010
    virtual_gid_maps = static:5010
    virtual_alias_maps = hash:/etc/postfix/virtual
    
    # TLS
    smtpd_use_tls = no
    smtpd_tls_security_level = may
    smtpd_tls_auth_only = yes
    smtpd_tls_key_file = /etc/postfix/myserver.key
    smtpd_tls_cert_file = /etc/postfix/server.crt
    smtpd_tls_loglevel = 1
    smtpd_tls_received_header = yes
    smtpd_tls_session_cache_timeout = 3600s
    tls_random_source = dev:/dev/urandom
    
    # SASL
    smtpd_sasl_type = dovecot
    broken_sasl_auth_clients = yes
    smtpd_sasl_path = private/auth
    smtpd_sasl_auth_enable = yes
    smtpd_sasl_security_options = noanonymous
    smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination, permit
    smtpd_relay_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination
    
    # Amavisd
    content_filter = amavisfeed:[127.0.0.1]:10024
    ISPConfig can not work if you install it on a unclean server, that's why you had the postfix problems. Then download ispconfig again, unpack it and run the update.php script in the install folder. Let ispconfig reconfigure the services when the updater asks.
     
  7. Hypnotize

    Hypnotize New Member

    Thanks for your reply :)
    I have updated ispconfig and now i get this error when I try to login to roundcube :
    Code:
    Jan  7 16:35:02 vmi97256 sendmail[2513]: NOQUEUE: SYSERR(root): No local mailer defined
    Jan  7 16:35:02 vmi97256 sendmail[2513]: NOQUEUE: SYSERR(root): QueueDirectory (Q) option must be set
    Jan  7 16:35:02 vmi97256 dovecot: imap-login: Disconnected (disconnected before auth was ready, waited 0 secs): user=<>, rip=127.0.0.1, lip=127.0.0.1, secured, session=<sm7C4IJFBAB/AAAB>
    Jan  7 16:35:02 vmi97256 dovecot: pop3-login: Disconnected (no auth attempts in 0 secs): user=<>, rip=127.0.0.1, lip=127.0.0.1, secured, session=<0hnD4IJFCgB/AAAB>
    Jan  7 16:35:02 vmi97256 postfix/smtpd[2541]: connect from localhost.localdomain[127.0.0.1]
    Jan  7 16:35:02 vmi97256 postfix/smtpd[2541]: warning: SASL: Connect to private/auth failed: Connection refused
    Jan  7 16:35:02 vmi97256 postfix/smtpd[2541]: fatal: no SASL authentication mechanisms
    Jan  7 16:35:03 vmi97256 postfix/master[2025]: warning: process /usr/libexec/postfix/smtpd pid 2541 exit status 1
    Jan  7 16:35:03 vmi97256 postfix/master[2025]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling
    Jan  7 16:35:06 vmi97256 dovecot: imap-login: Disconnected (auth failed, 1 attempts in 4 secs): user=<troy@gvardia.me>, method=PLAIN, rip=127.0.0.1, lip=127.0.0.1, secured, session=<fO7F4IJFCAB/AAAB>
    Jan  7 16:36:06 vmi97256 postfix/smtpd[2610]: connect from bay004-omc4s18.hotmail.com[65.54.190.220]
    Jan  7 16:36:06 vmi97256 postfix/smtpd[2610]: warning: SASL: Connect to private/auth failed: Connection refused
    Jan  7 16:36:06 vmi97256 postfix/smtpd[2610]: fatal: no SASL authentication mechanisms
    Jan  7 16:36:07 vmi97256 postfix/master[2025]: warning: process /usr/libexec/postfix/smtpd pid 2610 exit status 1
    Jan  7 16:36:07 vmi97256 postfix/master[2025]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling
     
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    Probably there are more errors in postfix main.cf and master.cf due to the unclean base setup.

    Which Linux distribution do you use?

    And please post main.cf as well as master.cf of your server.
     
  9. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    And also make sure, that doveot or - if you use courier - saslauthd is running.
     
  10. Hypnotize

    Hypnotize New Member

    Once more, thanks for your reply.
    I managed to login to roundcube, but i get this errors when I try to send email or receive one :
    Code:
    Jan  7 22:49:57 vmi97256 postfix/smtpd[26932]: connect from localhost.localdomain[127.0.0.1]
    Jan  7 22:49:57 vmi97256 postfix/smtpd[26932]: warning: SASL: Connect to private/auth failed: Connection refused
    Jan  7 22:49:57 vmi97256 postfix/smtpd[26932]: fatal: no SASL authentication mechanisms
    I'm Using Centos 7.3
    I restarted saslauthd (and it is running), but i still get this errors.
    These are my main.cf and master.cf
     

    Attached Files:

  11. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    remove the following lines from your master.cf:
    Code:
    amavisfeed unix - - n - 2 lmtp
      -o lmtp_data_done_timeout=1200
      -o lmtp_send_xforward_command=yes
    
    
      flags=DRhu user=vmail:vmail argv=/usr/libexec/dovecot/deliver -f ${sender} -d ${user}@${nexthop}
    
    (flags=... in 127.0.0.1:10025)
     
  12. Hypnotize

    Hypnotize New Member

    Thanks for your reply.

    When I try to update ispconfig3 so it rewrites files, everything is ok, except I get this error :
    Code:
    Job for amavisd.service failed because the control process exited with error code. See "systemctl status amavisd.service" and "journalctl -xe" for details.
    And full message is :
    Code:
    amavisd.service - Amavisd-new is an interface between MTA and content checkers.
       Loaded: loaded (/usr/lib/systemd/system/amavisd.service; enabled; vendor preset: disabled)
       Active: failed (Result: start-limit) since Sat 2017-01-14 00:22:38 CET; 14s ago
         Docs: http://www.ijs.si/software/amavisd/#doc
      Process: 29493 ExecStart=/usr/sbin/amavisd -c /etc/amavisd/amavisd.conf (code=exited, status=13)
    Main PID: 2241 (code=exited, status=0/SUCCESS)
    
    Failed to start Amavisd-new is an interface between MTA and content checkers..
    Unit amavisd.service entered failed state.
    amavisd.service failed.
    amavisd.service holdoff time over, scheduling restart.
    start request repeated too quickly for amavisd.service
    Failed to start Amavisd-new is an interface between MTA and content checkers..
    Unit amavisd.service entered failed state.
    amavisd.service failed.
    
    :/
     

Share This Page