LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-30-2009, 05:35 PM   #1
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Rep: Reputation: 15
Postfix Dovecot send receive issues [RESOLVED]


Well, here I go again.

I am running CentOS 5.
I am using Postfix and Dovecot. I have had no problems sending/receiving mail until recently.

I have a domain name(we'll call it mydomain.com} and mx records pointing to my server. All of a sudden, I can send email out to ANY email address on the web. However, I can only RECEIVE email from mydomain.com. I cannot receive email from any other domains.

In other words.
If I send email from:
name@comcast.net
to:
name@mydomain.com
It never arrives.

However, if I send from:
name@mydomain.com
to:
name2@mydomain.com
It arrives just fine.

Sounds confusing, I know, but hopefully someone can shed some light for me.

The only "weird" thing I noticed recently was that my server time was off. After setting the time correctly, dovecot stopped working. I then had to start dovecot manually, then email started working again, but only as I described above.

Last edited by areamike; 04-09-2009 at 07:20 AM. Reason: Changed title to add resolved.
 
Old 03-30-2009, 06:50 PM   #2
sleddog
Member
 
Registered: Jan 2002
Location: Labrador, Canada
Distribution: CentOS, Debian
Posts: 182

Rep: Reputation: 35
Mail sending is done by Postfix so it's unlikely that an issue with Dovecot would affect it (the Dovecot problem sounds like the time moved backwards hiccup, resolvable by running ntpd on your server).

Send a test message while tailing your mail log:

tail -f /var/log/maillog

and watch for messages from Postfix. There should be some good clues there to explain what's happening.
 
Old 03-30-2009, 07:01 PM   #3
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
Thanks, I'll try your suggestion.

Oh and yes, I am now running ntpd on my server after researching why dovecot stopped when I changed my server's time.
 
Old 03-30-2009, 07:05 PM   #4
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by sleddog View Post
Mail sending is done by Postfix so it's unlikely that an issue with Dovecot would affect it (the Dovecot problem sounds like the time moved backwards hiccup, resolvable by running ntpd on your server).

Send a test message while tailing your mail log:

tail -f /var/log/maillog

and watch for messages from Postfix. There should be some good clues there to explain what's happening.
Welp, tried your suggestion and got nothing, nada zero.

All the maillog shows is the PLAIN type login from the email account through dovecot, but no email is ever received from outside domains.

Mar 30 20:05:13 www dovecot: pop3-login: Login: user=<areamike>, method=PLAIN, rip=::ffff:XX.XXX.XXX.XXX, lip=::ffff:192.168.0.111
Mar 30 20:05:13 www dovecot: POP3(areamike): Disconnected: Logged out top=0/0, retr=0/0, del=0/0, size=0

However, if I send email from user@mydomain to user1@mydomain, it shows in maillog as normal. But from user@anyotherdomain to user@mydomain, NOTHING!

Last edited by areamike; 03-30-2009 at 07:10 PM.
 
Old 03-30-2009, 07:30 PM   #5
sleddog
Member
 
Registered: Jan 2002
Location: Labrador, Canada
Distribution: CentOS, Debian
Posts: 182

Rep: Reputation: 35
How are you sending these mails...

From user@mydomain to user1@mydomain: which SMTP server are you using? Your ISP? Your own server?

From user@anyotherdomain to user@mydomain: same question... which SMTP server? Your ISP? Your server? Gmail? Something else?

When mail sent from an outside source (e.g. a Gmail account) is received at your server, Postfix receives it and will log the fact. If you don't see that happening then the outside sender is having a problem finding or connecting to your mail server.

- Check that Postfix is in fact running.
- Check that there isn't a firewall on your server blocking it.
- Check that the MX record for your domain is correct.

But you do need to explain exactly how you're sending those messages, i.e. via which SMTP server.
 
Old 03-30-2009, 07:50 PM   #6
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
Postfix is running.
Firewall has not been changed
I have not changed my MX records in a long time, so I doubt that is the problem.

From user@mydomain to user1@mydomain: uses smtp.mydomain.com to send

From user@anyotherdomain to user@mydomain: uses smtp.comcast.net to send

It appears to me that ANY mail coming from anything other than smtp.mydomain.com is not being received by my server. It's almost like it is blocking anything not from smtp.mydomain.com.

The other thing is, the mail being sent from smtp.anyotherdomains.com is going out just fine to user@mydomain.com and is not bouncing back at all.

Last edited by areamike; 03-30-2009 at 07:57 PM.
 
Old 03-31-2009, 07:37 AM   #7
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
OK, I think I found the problem.

COMCAST.

742BFC18056: host mx1.comcast.net[76.96.62.116] refused to talk to me: 554 IMTA19.westchester.pa.mail.comcast.net comcast 69.245.162.242 Comcast blocked. Please see http://help.comcast.net/content/faq/ES000001

So there it is. Apparently they finally caught on that I was using an smtp(smtp.mydomain.com) server occasionally other than theirs. I wasn't using it for spam, just for my own personal use, however, it appears that does not matter.

Thank you Comcast.

The funny thing is that I can send email from Windows Mail using user@mydomain.com through smtp.mydomain.com and it works. I still just cannot receive email from anything other than mydomain.com email addresses. Although it may be deceiving since I have relayhost=smtp.comcast.net in my Postfix main.cf

Last edited by areamike; 03-31-2009 at 07:54 AM.
 
Old 03-31-2009, 01:17 PM   #8
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
OK, now I am starting to wonder if this has anything to do with PCRE. I recently thought I needed to install PCRE, however it was already on my box. I installed it anyway and it almost seems coincidental that accepting emails from outside stopped working around the same time.

This is driving me nuts.

I can still send emails out from my server to anywhere with no problems. I can receive emails, but ONLY from my FQDN of my server.
eg.
user@areamike.com to user2@areamike.com works flawlessly

user@comcast.net to user@aremiake.com NO WORKY!

dangitt, this is gonna make me crazy.

All, I know is that if I get this fixed, I am never adding or changing anything ever again on my Linux server unless it is broke.
 
Old 04-08-2009, 05:18 PM   #9
bono00
LQ Newbie
 
Registered: Apr 2009
Posts: 2

Rep: Reputation: 0
About your problem...

Something similiar is happening with my pop3 server/service.

I can send email to any domain/email address on web, but I CAN NOT receive emails from ANY domain (anywhere), mydomain included.

Iīve made several changes in dovecot.conf but I canīt identify the problem.

Do you have any clue about my problem??...

Thanks...


Quote:
Originally Posted by areamike View Post
Well, here I go again.

I am running CentOS 5.
I am using Postfix and Dovecot. I have had no problems sending/receiving mail until recently.

I have a domain name(we'll call it mydomain.com} and mx records pointing to my server. All of a sudden, I can send email out to ANY email address on the web. However, I can only RECEIVE email from mydomain.com. I cannot receive email from any other domains.

In other words.
If I send email from:
name@comcast.net
to:
name@mydomain.com
It never arrives.

However, if I send from:
name@mydomain.com
to:
name2@mydomain.com
It arrives just fine.

Sounds confusing, I know, but hopefully someone can shed some light for me.

The only "weird" thing I noticed recently was that my server time was off. After setting the time correctly, dovecot stopped working. I then had to start dovecot manually, then email started working again, but only as I described above.
 
Old 04-09-2009, 07:19 AM   #10
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
bono00,

I'm not sure, but my problem is resolved. I had change the listening port for smtp from 25 to something else. This worked for while and then stopped. I changed back to port 25 and now all is well.

Here is the tutorial I used to setup my Postfix and Dovecot on my Linux box.
Postfix -> http://www.linuxmail.info/postfix-sm...owto-centos-5/
Dovecot -> http://www.linuxmail.info/install-se...ecot-centos-5/
SMTP Auth for Dovecot -> http://www.linuxmail.info/postfix-sm...-dovecot-sasl/

First page is step one, setting up Postfix, Then Next is setting up Dovecot. You might have made changes to your Dovecot config that is causing the issue. Or it could be your postfix main.cf file has some wrong settings.
 
  


Reply



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
Postfix + Dovecot + mail send restriction brgsousa Linux - Software 0 11-26-2008 01:14 PM
postfix (cant send or receive mail) madfed Linux - Server 45 08-07-2008 03:51 AM
Postfix : mail cannot send to send outside ( can send/receive locally) bobbinsupport Linux - Networking 3 12-15-2007 10:40 PM
postfix can't receive mail; send OK ssfrstlstnm Linux - Server 4 04-24-2007 08:01 PM
Postfix able to send but not receive mail :( !! Ikik Linux - General 10 01-28-2004 07:40 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

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

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration