====== Debugging e-mail problems ====== ===== Check if the server hostname is resolvable forward and reverse: ===== Prompt$> host your-servername.example.com your-servername.example.com has address 192.0.2.100 Prompt$> host 192.0.2.100 100.2.0.192.in-addr.arpa. domain name pointer your-servername.example.com. ===== Check if mailserver is accepting connections and answers with correct HELO/EHLO ===== Prompt$> telnet your-servername.example.com 25 Trying 192.0.2.100... Connected to your-servername.example.com. Escape character is '^]'. 220 your-servername.example.com ESMTP MAIL Server \\ If the servername is not correct you can adjust it in /etc/postfix/main.cf altering the smtpd_banner parameter ===== Check that you have not configured a virtualdomain as mydestination in main.cf ===== Prompt$> postconf | grep "^my" mydestination = $myhostname, $mydomain mydomain = $myhostname myhostname = your-servername.example.com mynetworks = 127.0.0.0/8 mynetworks_style = subnet myorigin = $myhostname \\ When you have configured mydestination containing example.com and have mail-accounts setup in ispcp for example.com this wont work.\\ Postfix tells that in the logs by saying: "do not list domain in BOTH mydestination and virtual_alias_domains" ===== Check policy daemons ===== When you don't receive an e-mail and the logs show "451 Server configuration error" this is possibly because of an problem with connecting a policy daemon.\\ In this case a deeper look in the logs will point out:\\ "warning: connect to 127.0.0.1:12525: Connection refused" or "warning: connect to 127.0.0.1:60000: Connection refused"\\ This means postfix cannot connect to policyd-weight and/or postgrey.\\ Check if you have this services installed using your distros package managing solution (apt-get or yum or whatever)\\ Check if the services are listening on the correct port. This can be done by typing "netstat -an | grep 12525" into the command line.\\ \\ If you have no intention to use the policy daemons configured in the default ispcp environment, remove them from the config:\\ You find them in the "/etc/postfix/main.cf" in the directive "smtpd_recipient_restrictions".\\ Policy-weight is the option check_policy_service inet:127.0.0.1:12525.\\ Postgrey is the option check_policy_service inet:127.0.0.1:60000.\\ ===== Check if dns is working ===== Prompt$> host www.google.com should give you some ip addresses.\\ If postfix run in chrooted environment ensure that the resolv.conf in the chroot is identical to /etc/resolv.conf\\ You can check if postfix runs chrooted with the following command:\\ Prompt$> grep -v "^#" /etc/postfix/master.cf | grep "smtpd$" smtp inet n - y - - smtpd According to "man 5 master" the fifth column defines if service is chrooted or not. On most distros a "y" or a "-" in the fifth column means the service is chrooted. Centos, debian and maybe others chroot to "/var/spool/postfix", so the resolv.conf used by postfix would be stored as "/var/spool/postfix/etc/resolv.conf" ===== Further assistance ===== If the above checklist and your inquiry in the forums does not lead to the resolution of your problem, you can ask for help in the forum:\\ Such a request has to include at minimum the following informations:\\ * IspCP Release (if trunk, svn co date or revision number) * Realserver / Vserver * Behind natted firewall / direct routed * Distribution / OS used * Output of postconf -n * Output of grep -v "^#" /etc/postfix/master.cf * Complete log of an smtp session that leads to the problem (not the whole maillog / mail.info) * Mailclient / Webmailproduct you use\\ Detailed description of the problem!!!\\ We won't answer threads which say "I can't send mails, please help, its urgent"