LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 09-27-2005, 12:14 PM   #1
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Rep: Reputation: 15
qmail not receiving mail sent from remote host


Hi,

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.
 
Old 09-27-2005, 01:18 PM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
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?
 
Old 09-28-2005, 02:47 AM   #3
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
qmail problem

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.

<carol@host.com>:
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?

Last edited by ohcarol; 09-28-2005 at 03:16 AM.
 
Old 09-28-2005, 01:17 PM   #4
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
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
qmailctl stat
 
Old 09-29-2005, 01:32 AM   #5
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
Hereis the output of my qmail control file

# grep "" /var/qmail/control/*

/var/qmail/control/checkpassword:checkvpw
/var/qmail/control/concurrencyincoming:20
/var/qmail/control/defaultdelivery:./Maildir/
/var/qmail/control/defaultdomain:com.np
/var/qmail/control/locals:localhost
/var/qmail/control/me:lumbini.com.np
/var/qmail/control/plusdomain:com.np
/var/qmail/control/rcpthosts:localhost
/var/qmail/control/rcpthosts:lumbini.com.np
/var/qmail/control/smtpgreeting:smtp.lumbini.com.np
/var/qmail/control/timeoutremote:120
/var/qmail/control/virtualdomains:lumbini.com.np:myusers
/var/qmail/control/virtualdomains:lumbini.com.np:lumbini.com.np

#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?
 
Old 09-29-2005, 03:33 PM   #6
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
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
 
Old 09-30-2005, 02:12 AM   #7
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
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?
 
Old 09-30-2005, 02:02 PM   #8
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
Is mail.lumbini.com.np the real address? I don't seem to be able to resolve it.
 
Old 10-02-2005, 01:16 AM   #9
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
Sorry, actually "mail.baayu.com.np" is the real host.
Please try.
 
Old 10-02-2005, 06:11 AM   #10
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
Well, I've just tried to deliver a message to your postmaster address, see if you get this one:
Code:
rossy - trigger - Sun Oct 02 11:08:26
~> telnet krishna.wlink.com.np 25
Trying 202.79.32.34...
Connected to krishna.wlink.com.np.
Escape character is '^]'.
220 krishna.wlink.com.np ESMTP qmail-smtpd ready
HELO
MAIL FROM:david_ross AT linuxquestions.net
250 krishna.wlink.com.np Hi [84.45.139.87] [84.45.139.87].
250 david_ross AT linuxquestions.net, sender OK
RCPT TO: postmaster AT baayu.com.np
250 postmaster AT baayu.com.np, recipient ok
DATA
354 go ahead
subject: testing by david_ross from LQ

This is a test.

.

250 Queued!
The AT is just to obscure the addresses.
 
Old 10-02-2005, 06:47 AM   #11
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
I didn't get any mail at my postmaster address. and "krishna.wlink.com.np" is my isp dns address.

thank you
 
Old 10-02-2005, 08:35 AM   #12
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
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?
 
Old 10-02-2005, 11:31 AM   #13
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
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)

Last edited by ohcarol; 10-02-2005 at 11:36 AM.
 
Old 10-02-2005, 01:20 PM   #14
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 64
If you run "netstat -nlp" do you see port 25 in use by qmail?
 
Old 10-02-2005, 08:04 PM   #15
ohcarol
Member
 
Registered: Dec 2004
Location: Nepal
Posts: 86

Original Poster
Rep: Reputation: 15
This is the output of my netstat command

#netstat -npl

tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN -
tcp 0 0 202.79.53.76:53 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN -
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
having 2 Qmail probs - sending and receiving jaymer Linux - Software 1 06-24-2005 12:11 AM
problem receiving pop3 mail from postfix mail server GEN_Electric Linux - Software 2 02-14-2005 03:43 PM
Qmail Problem....? (Receiving mail) ysg08 Linux - Networking 3 01-17-2005 02:30 PM
Sending mail via Postfix smtpd through remote host requiring authentication Saffsd Linux - Networking 0 01-26-2004 06:05 AM
Qmail - Mail forward to host arckid Linux - Software 1 09-09-2003 03:34 AM


All times are GMT -5. The time now is 02:19 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration