After installing sendmail. and running the following commands: root@sendmail # yum install sendmail. root@sendmail mail# yum install dovecot root@sendmail mail# cd /etc/mail/ root@sendmail mail# vi local-host-names # local-host-names - include all aliases for your machine here. Example.com root@sendmail mail# vi /etc/dovecot.conf protocols = imap pop3 //uncomment root@sendmail mail# m4 sendmail.mc sendmail.cf root@sendmail mail# make root@sendmail mail# /etc/init.d/sendmail start root@sendmail mail# /etc/init.d/saslauthd start root@sendmail mail# /etc/init.d/dovecot start root@sendmail mail# chkconfig sendmail on root@sendmail mail# chkconfig dovecot on root@sendmail mail# chkconfig saslauthd on I still had the same issue. I checked my /var/log/maillog and saw an error: My unqualified host name (domain) unknown; sleeping for retry After more searching, I changed /etc/hosts from: 127.0.0.1 localhost localhost.localdomain domain ip.ip.ip.ip domain localhost to: 127.0.0.1 localhost.localdomain localhost domain ip.ip.ip.ip localhost domain and now the mail function is now working fine. I know this has been answered but I had a similiar problem. In case anyone else.
/var/log/maillog showed me a Postfix permission issue. Sendmail: fatal: chdir /var/spool/postfix: Permission denied Tracking down error I found solution to be SELinux policy on CentOS (I'm using version 6). Quick answer: setsebool httpdcansendmail 1 You can use -P to make the change permanent; I just needed for password reset e-mail so not needed for my case. Credit: EDIT: I would have commented but I don't have enough reputation yet.
In this brief tutorial, let us show you how I have upgraded my centos 7 kernel to the latest stable version. I am going to use a simple way so that beginners can easily understand how to upgrade to latest kernel. Yum --enablerepo=elrepo-kernel install kernel-ml-3.* Loaded plugins: fastestmirror. Based on and mostly the same as the 4.4 posted on the qmailtoaster.com wiki CentOS 4.4 QmailToaster Install - QMail-Toaster; Distro Notes. This tutorial is for CentOS 5 (cnt50) i386 To install CentOS 5 x86_64, replace cnt50 with cnt5064 DNS Notes. You must have either a local DNS server or a local caching name server.
I had the same problem. I have a development server at home and prod server at external server house and incoming mails go to other server. PHP:s mail works nicely in server house, but not at home. I tested a bit and got it to work at home in the same manner as in server house. The difference between methods in server house and home is the configuration of sendmail. Server house I had only to install sendmail and it was fine, but at home I had to install also sendmail-cf and use it to add outgoing mail server address.
Let's assume you have Centos, Apache and PHP at home server and you want to send emails using PHP:s mail function.