免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2358 | 回复: 8
打印 上一主题 下一主题

请问一个关于SENDMAIL的问题能发信.不能收信 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2007-05-15 15:23 |只看该作者 |倒序浏览
我的服务器好奇怪. 可以发送信件.但不能收取信件.

-bash-3.00# ll

-rw-rw----  1 jianghongbo mail 3974  5月 15 13:59 jianghongbo





Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
+OK dovecot ready.
user 帐号
+OK
pass 密码
+OK Logged in.
Connection closed by foreign host.



May 15 14:52:52 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 14:52:52 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 14:52:52 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 14:52:52 localhost dovecot: child 8302 (pop3) returned error 89
May 15 14:52:53 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 14:52:53 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 14:52:53 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 14:52:53 localhost dovecot: child 8305 (pop3) returned error 89
May 15 14:52:54 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 14:52:54 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 14:52:54 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 14:52:54 localhost dovecot: child 8309 (pop3) returned error 89
May 15 14:52:54 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 14:52:54 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 14:52:54 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 14:52:54 localhost dovecot: child 8311 (pop3) returned error 89
May 15 14:52:55 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 14:52:55 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 14:52:55 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 14:52:55 localhost dovecot: child 8315 (pop3) returned error 89

论坛徽章:
0
2 [报告]
发表于 2007-05-15 15:33 |只看该作者
[quote]原帖由 qq37479055 于 2007-5-15 15:23 发表于 1楼  
我的服务器好奇怪. 可以发送信件.但不能收取信件.[/.quote]

selinux ? 改 /etc/sysconfig/selinux 內容關閉重開後測試

论坛徽章:
0
3 [报告]
发表于 2007-05-15 17:29 |只看该作者
改了
SELINUX=permissive

SELINUXTYPE=targeted


May 15 17:15:07 localhost sm-msp-queue[3266]: l4F8g7Y1013467: to=root, ctladdr=root (0/0), delay=00:33:00, xdelay=00:00:00, mailer=relay, pri=210649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 17:15:07 localhost sm-msp-queue[3266]: l4F8p8R1013876: to=root, ctladdr=root (0/0), delay=00:23:59, xdelay=00:00:00, mailer=relay, pri=210649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 17:15:07 localhost sm-msp-queue[3266]: l4F8q8XC013920: to=root, ctladdr=root (0/0), delay=00:22:59, xdelay=00:00:00, mailer=relay, pri=210649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 17:15:07 localhost sm-msp-queue[3266]: l4F8T86E012879: to=root, ctladdr=root (0/0), delay=00:45:59, xdelay=00:00:00, mailer=relay, pri=210760, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 17:15:07 localhost sm-msp-queue[3266]: l4F8S8b3012832: to=root, ctladdr=root (0/0), delay=00:46:59, xdelay=00:00:00, mailer=relay, pri=211126, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 17:20:16 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 17:20:17 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 17:20:17 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 17:20:17 localhost dovecot: child 4801 (pop3) returned error 89
May 15 17:21:04 localhost pop3-login: Login: jianghongbo [::ffff:127.0.0.1]
May 15 17:21:04 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 17:21:04 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 17:21:04 localhost dovecot: child 4851 (pop3) returned error 89

论坛徽章:
0
4 [报告]
发表于 2007-05-15 18:36 |只看该作者
SELINUX=disabled


May 15 18:02:36 localhost sm-msp-queue[3252]: l4F8q8XC013920: to=root, ctladdr=root (0/0), delay=01:10:28, xdelay=00:00:00, mailer=relay, pri=300649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 18:02:36 localhost sm-msp-queue[3252]: l4F8T86E012879: to=root, ctladdr=root (0/0), delay=01:33:28, xdelay=00:00:00, mailer=relay, pri=300760, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 18:02:36 localhost sm-msp-queue[3252]: l4F8S8b3012832: to=root, ctladdr=root (0/0), delay=01:34:28, xdelay=00:00:00, mailer=relay, pri=301126, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 15 18:19:01 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 18:19:01 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 18:19:01 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 18:19:01 localhost dovecot: child 5361 (pop3) returned error 89
May 15 18:29:39 localhost pop3-login: Login: jianghongbo [::ffff:211.160.89.23]
May 15 18:29:39 localhost pop3(jianghongbo): mbox: Can't create root IMAP folder //mail: Permission denied
May 15 18:29:39 localhost pop3(jianghongbo): MAIL environment missing and autodetection failed (home /)
May 15 18:29:39 localhost dovecot: child 5983 (pop3) returned error 89

论坛徽章:
0
5 [报告]
发表于 2007-05-16 03:38 |只看该作者
你的使用者是不是沒有 home directory ?

--

论坛徽章:
0
6 [报告]
发表于 2007-05-16 06:06 |只看该作者
原帖由 kenduest 于 2007-5-16 03:38 发表于 5楼  
你的使用者是不是沒有 home directory ?

--



同上, 用户无宿主目录

论坛徽章:
0
7 [报告]
发表于 2007-05-16 11:05 |只看该作者
原因是我更改了jianghongbo的目录到/下

我改回到/HOME/JIANGHONGBO/就好了。谢谢大家!

SELINUX=disabled  还需要么?

论坛徽章:
0
8 [报告]
发表于 2007-05-16 12:13 |只看该作者
May 16 12:02:37 localhost sm-msp-queue[8297]: l4F8g7Y1013467: to=root, ctladdr=root (0/0), delay=19:20:30, xdelay=00:00:00, mailer=relay, pri=1920649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 16 12:02:37 localhost sm-msp-queue[8297]: l4F8p8R1013876: to=root, ctladdr=root (0/0), delay=19:11:29, xdelay=00:00:00, mailer=relay, pri=1920649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 16 12:02:37 localhost sm-msp-queue[8297]: l4F8q8XC013920: to=root, ctladdr=root (0/0), delay=19:10:29, xdelay=00:00:00, mailer=relay, pri=1920649, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 16 12:02:37 localhost sm-msp-queue[8297]: l4F8T86E012879: to=root, ctladdr=root (0/0), delay=19:33:29, xdelay=00:00:00, mailer=relay, pri=1920760, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
May 16 12:02:37 localhost sm-msp-queue[8297]: l4F8S8b3012832: to=root, ctladdr=root (0/0), delay=19:34:29, xdelay=00:00:00, mailer=relay, pri=1921126, relay=[127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]

虽然一切都正常了.能收能发了.但为什么日志还是一直在报这个?
而且每天ROOT都会收到的一封描述系统信息的信也不发送了是什么原因?

论坛徽章:
0
9 [报告]
发表于 2007-05-16 13:12 |只看该作者
查看/var/log/maillog,提示“Connection refused by 127.0.0.1”,又不是给local发邮件,怎么被本机refuse了呢??

原来Redhat SMTP默认仅绑定127.0.0.1,不能访问外部网络。

因此需要更改/etc/mail/sendmail.cf文件,将

O DaemonPortOptions =Port=smtp,Addr=127.0.0.1, Name=MTA

改为

O DaemonPortOptions =Port=smtp, Name=MTA

然后重启sendmail
OK
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP