qmail not receiving mail sent from remote host
I have installed qmail in my redhat linux machine along with vpopmail so that I can provide mail account to my user. My problem is that I can receive mail in my maildir sent from localhost that is using my own smtp server. But mail sent from another remote host can't be recived by my mail server. Can you tell me what's problem in my qmail.
Does your DNS addresses resolve correctly from the remote host?
Do you have any firewall rules in place?
What error do you get when you try to connect and deliver from a remote host?
Yes my DNS address is resovled probperly when I do dig mail.host.com it shows the ip address of my mail server.
I tried to send message from remote host doing telnet smtp.hos.com 25
and it says messages accepted for delivery.
However messsage is bounced back. with the follwing message.
Hi. This is the qmail-send program at abc.host.net
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.
Sorry, I wasn't able to establish an SMTP connection. (#4.4.1)
I'm not going to try again; this message has been in the queue too long.
However I can received mail send using my local smtp server. Can anyone tell me why is remote mail not received? Do I need to open access in my cisco firewall access list to allow connection to my smtp server from globally?
Well if the telnet to port 25 succeded then your firewall is obviously ok so there shouldn't be anything needing changed there.
Can you show us what your config is like:
grep "" /var/qmail/control/*
Are the services running ok - can you post the output from:
ps -ef | grep mail
Hereis the output of my qmail control file
# grep "" /var/qmail/control/*
#ps -e |grep mail
root 552 550 0 Sep28 ? 00:00:00 supervise qmail-send
root 554 550 0 Sep28 ? 00:00:00 supervise qmail-smtpd
root 556 550 0 Sep28 ? 00:00:01 supervise qmail-pop3d
qmaill 558 555 0 Sep28 ? 00:00:00 /usr/local/bin/multilog t /var/l
qmails 559 552 0 Sep28 ? 00:00:03 qmail-send
qmaild 560 554 0 Sep28 ? 00:00:00 /usr/local/bin/tcpserver -v -R -
qmaill 561 553 0 Sep28 ? 00:00:00 /usr/local/bin/multilog t /var/l
qmaill 563 557 0 Sep28 ? 00:00:00 /usr/local/bin/multilog t /var/l
root 578 559 0 Sep28 ? 00:00:00 qmail-lspawn ./Maildir/
qmailr 579 559 0 Sep28 ? 00:00:00 qmail-rspawn
qmailq 580 559 0 Sep28 ? 00:00:00 qmail-clean
root 22251 17514 0 11:18 pts/2 00:00:00 grep mail
One thing I have not made DNS entry for my smtp server "smtp.lumbini.com.np" in my ISP dns server. Do I need to made dns entry for smtp.lumbini.com.np too to receive mail from remote host?
If the mx record for lumbini.com.np resolves to smtp.lumbini.com.np then you will need to make an A record for it.
I think you'll also need to add the domain to locals:
echo lumbini.com.np >> /var/qmail/control/locals
My MX record for lumbini.com.np resolves to mail.lumbini.com.np. I also added lumbini.com.np to locals file. Still not solved.
When I do :
# host lumbini.com.np
lumbini.com.np has address xxx.xx.xx.xx
lumbini.com.np mail is handled (pri=10) by mail.lumbini.com.np
lumbini.com.np mail is handled (pri=20) by ns1.myispdns.com.np
Which shows that MX of my domain is pointed to mail.lumbini.com.np.
STill I am not receiving any mail sent from remote host. Or is the router firewall blocking smtp connection to my host?
Is mail.lumbini.com.np the real address? I don't seem to be able to resolve it.
Sorry, actually "mail.baayu.com.np" is the real host.
Well, I've just tried to deliver a message to your postmaster address, see if you get this one:
I didn't get any mail at my postmaster address. and "krishna.wlink.com.np" is my isp dns address.
Sorry, I took the wrong host from the MX record. I can't even get a response from mail.baayu.com.np, it just times out. Is it connected to the internet and not firewalled?
yes it's connected to the internet and running up. and also I have open acess to my smtp server in my linux box.
ACCEPT tcp ------ 0.0.0.0/0 xxx.xx.xx.xx * -> 25
And in my cisco router access-list
permit tcp host xxx.xx.xx.xx any eq smtp
permit tcp any eq smtp host xxx.xx.xx.xx
permit tcp any host xxx.xx.xx.xx eq smtp
Even I cannot get mail sent from my ISP network. I think you can ping my domain.
While I do tcpdump in my server I can see request comming to my server's smtp port.
21:26:59.888407 eth0 > baayu.com.np.smtp > smtp5.wlink.com.np.18843: S 1210081289:1210081289(0) ack 818152708 win 32120 <mss 1460,nop,nop,timestamp 937586 357506637,nop,wscale 0> (DF)
21:27:06.085988 eth0 < smtp5.wlink.com.np.18842 > baayu.com.np.smtp: S 43429644:43429644(0) win 65535 <mss 1460>
21:27:06.086100 eth0 > baayu.com.np.smtp > smtp5.wlink.com.np.18842: S 1212269194:1212269194(0) ack 43429645 win 32120 <mss 1460,nop,nop,timestamp 938206 357506637,nop,wscale 0> (DF)
21:27:06.092160 eth0 < smtp5.wlink.com.np.18843 > baayu.com.np.smtp: S 818152707:818152707(0) win 65535 <mss 1460>
21:27:06.092229 eth0 > baayu.com.np.smtp > smtp5.wlink.com.np.18843: S 1210081289:1210081289(0) ack 818152708 win 32120 <mss 1460,nop,nop,timestamp 938207 357506637,nop,wscale 0> (DF)
21:28:00.134854 lo > baayu.com.np.5188 > baayu.com.np.smtp: . 1:1(0) ack 1 win 31072 <nop,nop,timestamp 943611 943611> (DF)
21:28:00.134854 lo < baayu.com.np.5188 > baayu.com.np.smtp: . 1:1(0) ack 1 win 31072 <nop,nop,timestamp 943611 943611> (DF)
21:28:00.141843 lo > baayu.com.np.smtp > baayu.com.np.5188: P 1:30(29) ack 1 win 31072 <nop,nop,timestamp 943612 943611> (DF)
21:28:19.460725 eth0 > baayu.com.np.smtp > smtp5.wlink.com.np.18843: S 1210081289:1210081289(0) ack 818152708 win 32120 <mss 1460,nop,nop,timestamp 945544 357506637,nop,wscale 0> (DF)
21:28:19.460795 eth0 > baayu.com.np.smtp > smtp5.wlink.com.np.18842: S 1212269194:1212269194(0) ack 43429645 win 32120 <mss 1460,nop,nop,timestamp 945544 357506637,nop,wscale 0> (DF)
If you run "netstat -nlp" do you see port 25 in use by qmail?
This is the output of my netstat command
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN -
tcp 0 0 126.96.36.199:53 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN -
|All times are GMT -5. The time now is 06:57 PM.|