after spending 1/2 a day trying to relay to gmail i realized that the port is block by optonline.net. Doh. feel silly.
So now i'm trying to configure sendmail to relay using the mail.optonline.net. And it's not going well.
Here is the log and config file. I'm out of ideas at this point and any suggestion(s) are very welcomed.
Code:
[root@vmhost mail]# grep -v ^dnl ./sendmail.mc
divert(-1)dnl
include(`/usr/share/sendmail-cf/m4/cf.m4')dnl
VERSIONID(`setup for linux')dnl
OSTYPE(`linux')dnl
define(`SMART_HOST', `[mail.optonline.net]')dnl
define(`confDEF_USER_ID', ``8:12'')dnl
define(`confTO_CONNECT', `1m')dnl
define(`confTRY_NULL_MX_LIST', `True')dnl
define(`confDONT_PROBE_INTERFACES', `True')dnl
define(`PROCMAIL_MAILER_PATH', `/usr/bin/procmail')dnl
define(`ALIAS_FILE', `/etc/aliases')dnl
define(`STATUS_FILE', `/var/log/mail/statistics')dnl
define(`UUCP_MAILER_MAX', `2000000')dnl
define(`confUSERDB_SPEC', `/etc/mail/userdb.db')dnl
define(`confPRIVACY_FLAGS', `authwarnings,novrfy,noexpn,restrictqrun')dnl
define(`confAUTH_OPTIONS', `A')dnl
define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
define(`confTO_IDENT', `0')dnl
FEATURE(`no_default_msa', `dnl')dnl
FEATURE(`smrsh', `/usr/sbin/smrsh')dnl
FEATURE(`mailertable', `hash -o /etc/mail/mailertable.db')dnl
FEATURE(`virtusertable', `hash -o /etc/mail/virtusertable.db')dnl
FEATURE(redirect)dnl
FEATURE(always_add_domain)dnl
FEATURE(use_cw_file)dnl
FEATURE(use_ct_file)dnl
FEATURE(local_procmail, `', `procmail -t -Y -a $h -d $u')dnl
FEATURE(`access_db', `hash -T<TMPF> -o /etc/mail/access.db')dnl
FEATURE(`blacklist_recipients')dnl
EXPOSED_USER(`root')dnl
DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl
FEATURE(`accept_unresolvable_domains')dnl
LOCAL_DOMAIN(`localhost.localdomain')dnl
FEATURE(`authinfo',`hash /etc/mail/auth/client-info')dnl
MAILER(smtp)dnl
MAILER(procmail)dnl
the client-info file is :
Code:
cd auth
[root@vmhost auth]# ls -l
total 16
-rw------- 1 root root 58 Mar 15 22:41 client-info
-rw------- 1 root root 12288 Mar 15 22:41 client-info.db
[root@vmhost auth]# cat ./client-info
AuthInfo:mail.optonline.net "U:root" "I:my_username_on_optonline.net" "P:mypassword"
an attempt to send an email. Not sure why it sends it to localhost and what user "az" has to do with all this - i'm "root" now.
Code:
[root@vmhost mail]# sendmail -v fake_email@optonline.net
buba
real pain
.
fake_email@optonline.net... Connecting to [127.0.0.1] via relay...
220 vmhost.home ESMTP Sendmail 8.13.8/8.13.8; Wed, 16 Mar 2011 12:54:51 -0400
>>> EHLO vmhost.home
250-vmhost.home Hello localhost [127.0.0.1] (may be forged), pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-AUTH LOGIN PLAIN
250-DELIVERBY
250 HELP
>>> MAIL From:<az@vmhost.home> SIZE=15 AUTH=az@vmhost.home
250 2.1.0 <az@vmhost.home>... Sender ok
>>> RCPT To:<fake_email@optonline.net>
>>> DATA
250 2.1.5 <fake_email@optonline.net>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .
250 2.0.0 p2GGspqZ003541 Message accepted for delivery
fake_email@optonline.net... Sent (p2GGspqZ003541 Message accepted for delivery)
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 vmhost.home closing connection
and attempt to send an email as (local) user "az":
Code:
Date: Wed, 16 Mar 2011 08:53:38 -0400
From: Mail Delivery Subsystem <MAILER-DAEMON@vmhost.home>
To: az@vmhost.home
Subject: Returned mail: see transcript for details
Parts/Attachments:
1 Shown 13 lines Text
2 Shown 331 bytes Message, "Delivery Status"
3 Shown 499 bytes Message
3.1 Shown 2 lines Text
----------------------------------------
The original message was received at Wed, 16 Mar 2011 08:53:38 -0400
from localhost [127.0.0.1] (may be forged)
----- The following addresses had permanent fatal errors -----
<my_user@optonline.net>
(reason: 550 5.1.8 invalid/host-not-in-DNS return address not allowed)
----- Transcript of session follows -----
... while talking to mail.optonline.net.:
>>> MAIL From:<az@vmhost.home> SIZE=469
<<< 550 5.1.8 invalid/host-not-in-DNS return address not allowed
554 5.0.0 Service unavailable
the /etc/hosts* are:
Code:
cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
#127.0.0.1 vmhost.home vmhost
#127.0.0.1 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
192.168.1.204 server
10.0.2.15 vmhost.home vmhost
[root@vmhost auth]# cat /etc/hosts.allow
#
# hosts.allow This file describes the names of the hosts which are
# allowed to use the local INET services, as decided
# by the '/usr/sbin/tcpd' server.
#
ALL:127.0.0.1