分类:
2010-06-23 13:19:45
服务器运行了fetchmail用于接收邮件,但是由于服务器是公用的,不知道什么设置或者装什么软件导致fetchmail突然运行不正常。
查看日志文件发现fetchmail没有记录。
rpm -e后yum重装fetchmail。装好之后日志开始记录,但是提示
fetchmail: connection to localhost:smtp [::1/25] failed: Connection refused.之类的错误。
telnet 25发现不正常。
检查sendmail 发现启动失败
提示
[root@redhat etc]# service sendmail start
Starting sendmail: 451 4.0.0 /etc/mail/sendmail.cf: line 91: fileclass: cannot open '/etc/mail/local-host-names': World writable directory
451 4.0.0 /etc/mail/sendmail.cf: line 588: fileclass: cannot open '/etc/mail/trusted-users': World writable derectory [FAILED]
解决方法
[root@redhat etc]# chmod go-w / /etc /etc/mail /usr /var /var/spool /var/spool/mqueue
[root@redhat etc]# chown root / /etc /etc/mail /usr /var /var/spool /var/spool/mqueue
[root@redhat etc]# service sendmail start
Starting sendmail: [ OK ]
详细可以查看sendmail的readme中DIRECTORY PERMISSIONS 章节!