From owner-freebsd-questions Wed Jun 26 10:38:56 2002 Delivered-To: freebsd-questions@freebsd.org Received: from web14401.mail.yahoo.com (web14401.mail.yahoo.com [216.136.174.58]) by hub.freebsd.org (Postfix) with SMTP id 471AB37B401 for ; Wed, 26 Jun 2002 10:38:51 -0700 (PDT) Message-ID: <20020626173848.46342.qmail@web14401.mail.yahoo.com> Received: from [210.53.51.130] by web14401.mail.yahoo.com via HTTP; Wed, 26 Jun 2002 10:38:48 PDT Date: Wed, 26 Jun 2002 10:38:48 -0700 (PDT) From: Qingjia Zhu Subject: Re: sendmail refuse localhost(revisited)? To: Alexander V Zubchenko Cc: gshapiro@FreeBSD.org, freebsd-questions@freebsd.org In-Reply-To: <20020626110835.L12722-100000@server.hermes-comp.zp.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, gurus Because fetchmail in my box works, that is, my sendmail do can receive incoming mails, so I'd like to describe my problem again, I hope somebody can look into this and help me to find the way out(Which config file to modifiy? How?). My box dials up to the Internet. First, I did a complete freshly install(FreeBSD 4.6 release), create two user(root, qjzhu), hostname is not set in /etc/rc.conf, and /etc/hosts contains ::1 localhost localhost.my.domain 127.0.0.1 localhost localhost.my.domain No /etc/mail/relay-domains, no /etc/mail/local-host-names Now it's ok for root to send mail to qjzhu with 'mail' MUA. /var/log/maillog logs > Jun 27 00:35:33 sendmail[122]: g5QGZXnA000122: from=root, size=30, class=0, > nrcpts=1, msgid=<200206261635.g5QGZXnA000122@localhost.my.domain>, relay= > root@localhost > Jun 27 00:35:33 sm-mta[123]:g5QGZXWM000123: from=, > , size=349, class=0, nrcpts=1, msgid=<200206261635.g5QGZXnA000122@localhost. > my.domain>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1] > Jun 27 00:35:33 sendmail[122]: g5QGZXnA000122: to=qjzhu, ctladdr=root > (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30025, relay=loca > lhost.my.domain. [127.0.0.1], dsn=2.0.0, stat=Sent (g5QGZXWM000123 Message > accepted for delivery) > Jun 27 00:35:33 sm-mta[124]: g5QGZXWM000123: to=, > ctladdr= (0/0), delay=00:00:00, xdelay=00:00:00, > mailer=local, pri=30625, relay=local, dsn=2.0.0, stat=Sent Then, I add hostname="qjzhu.headsun.net" to /etc/rc.conf, change /etc/hosts into 127.0.0.1 localhost qjzhu.headsun.net and in /etc/mail/sendmail.cf I add Cwlocalhost qjzhu.headsun.net Now root is UNABLE to send mail to qjzhu with 'mail' MUA, /var/log/maillog logs > Jun 27 00:42:20 qjzhu sendmail[122]: g5QGgKcm000122: from=root, size=30, > class=0, nrcpts=1, msgid=<200206261642.g5QGgKcm000122@qjzhu.headsun.net>, > relay=root@localhost > Jun 27 00:42:20 qjzhu sendmail[122]: g5QGgKcm000122: to=qjzhu, ctladdr=root > (0/0),delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30025, relay=qjzhu. > headsun.net., dsn=4.0.0, stat=Deferred: Connection refused by qjzhu.headsun. > net. Then I dial up and start fetchmail, sendmail seems ok to receive incoming mails, /var/log/maillog logs: > Jun 27 00:51:28 qjzhu sm-mta[156]: g5QGpEoe000156: from= bsd.org>, size=2610, class=-60, nrcpts=1, msgid=<200206261646.g5QGkoSI00090 > 5@freefall.freebsd.org>, proto=ESMTP, daemon=MTA, relay=localhost[127.0.0.1] > Jun 27 00:51:28 qjzhu sm-mta[175]: g5QGpEoe000156: to=, del > ay=00:00:00, xdelay=00:00:00, mailer=local, pri=140821, relay=local, dsn=2.0 > .0, stat=Sent So, what's the reason of "connection refused"? How to resolve? Can anybody explain the logs? Please shed some light on it. Thanks. >Alexander V Zubchenko wrote: >> Also want to notate: in prev. mail in second case (with 'mail' MUA) >> clearly two moments: >> a) mailer is relay (not local) >> b) this may b just mistype in letter, not in real output, but there r >> relay=localhost.heasun.net not headsun.net >> >> Also i'm not sured it is correct 'Cwlocalhost'. Try to change it to >> real host name or domainname. Other ideas some later...:) __________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message