These forums are locked and archived, but all topics have been migrated to the new forum. You can search for this topic on the new forum: Search for Postfix not restarting Centos 7, but I think mail is working? on the new forum.
Is there something special about Postfix on Centos 7? I tried restarting and I get this:
[root@ac3 ~]# service postfix restart
Redirecting to /bin/systemctl restart postfix.service
Job for postfix.service failed because the control process exited with error code. See "systemctl status postfix.service" and "journalctl -xe" for details.
Running "systemctl status postfix.service" shows:
[root@ac3 ~]# systemctl status postfix.service
● postfix.service - Postfix Mail Transport Agent
Loaded: loaded (/usr/lib/systemd/system/postfix.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Tue 2016-02-23 19:09:43 GMT; 2min 32s ago
Process: 20570 ExecStart=/usr/sbin/postfix start (code=exited, status=1/FAILURE)
Process: 20567 ExecStartPre=/usr/libexec/postfix/chroot-update (code=exited, status=0/SUCCESS)
Process: 20563 ExecStartPre=/usr/libexec/postfix/aliasesdb (code=exited, status=0/SUCCESS)
Main PID: 3601 (code=killed, signal=TERM)
Feb 23 19:09:41 myhostname.com systemd[1]: Starting Postfix Mail Transport Agent...
Feb 23 19:09:41 myhostname.com postfix/postfix-script[20639]: starting the Postfix mail system
Feb 23 19:09:41 myhostname.com postfix/master[20641]: fatal: bind 0.0.0.0 port 25: Address already in use
Feb 23 19:09:42 myhostname.com postfix/master[20640]: fatal: daemon initialization failure
Feb 23 19:09:43 myhostname.com postfix/postfix-script[20649]: fatal: mail system startup failed
Feb 23 19:09:43 myhostname.com systemd[1]: postfix.service: control process exited, code=exited status=1
Feb 23 19:09:43 myhostname.com systemd[1]: Failed to start Postfix Mail Transport Agent.
Feb 23 19:09:43 myhostname.com systemd[1]: Unit postfix.service entered failed state.
Feb 23 19:09:43 myhostname.com systemd[1]: postfix.service failed.
This is what is running on port 25:
[root@ac3 ~]# sudo netstat -lnp |grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 16250/smtpd
tcp6 0 0 :::25 :::* LISTEN 16250/smtpd
BUT I can send mail using PHP, so mail is sending.
So why is Postfix not running, how do I make a change to postfix config and restart it?
Thanks
Well, I just decided to:
kill -9 16250
then could start postfixDont know what that other service was running on 16250