LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 03-20-2014, 12:05 PM   #1
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 338

Rep: Reputation: Disabled
Sending emails with postfix on centos


I am trying to set up a very simple email server, and will just need to send emails. I followed http://www.techotopia.com/index.php/...x_Email_Server. When sending an email, /var/log/maillog shows the below error. The server is physical and located in my house, and uses my Comcast modem to connect to the Internet.

Any suggestions? Thank you

EDIT I think the first problem was a result of iptables. I have it temporarily disabled, but now I get the following:

Code:
Mar 20 04:14:16 desktop postfix/pickup[11163]: B95715260BE1: uid=495 from=<gitlab@localhost>
Mar 20 04:14:16 desktop postfix/cleanup[12682]: B95715260BE1: message-id=<532acd8885983_2fe43faa55e97ed0627c3@desktop.mysite.com.mail>
Mar 20 04:14:16 desktop postfix/qmgr[11164]: B95715260BE1: from=<gitlab@localhost.mysite.com>, size=696, nrcpt=1 (queue active)
Mar 20 04:14:16 desktop postfix/smtp[12684]: connect to mx2.comcast.net[2001:558:fe2d:70::22]:25: Network is unreachable
Mar 20 04:14:16 desktop postfix/smtp[12684]: connect to mx1.comcast.net[2001:558:fe14:70::22]:25: Network is unreachable
Mar 20 04:14:46 desktop postfix/smtp[12684]: connect to mx2.comcast.net[yy.yy.yy.yyy]:25: Connection timed out
Mar 20 04:15:16 desktop postfix/smtp[12684]: connect to mx1.comcast.net[xx.xx.xx.xxx]:25: Connection timed out
Mar 20 04:15:17 desktop postfix/smtp[12684]: B95715260BE1: to=<dummy@comcast.net>, relay=none, delay=60, delays=0.24/0.01/60/0, dsn=4.4.1, status=deferred (connect to mx1.comcast.net[xx.xx.xx.xxx]:25: Connection timed out)
EDIT. This was my original log, but I think I experienced the problems due to iptables.
Code:
Mar 20 03:59:15 desktop postfix/pickup[11163]: 6EFB75260BDD: uid=495 from=<gitlab@localhost>
Mar 20 03:59:15 desktop postfix/cleanup[12378]: 6EFB75260BDD: message-id=<532aca0342c35_2fe43faa55e97ed0626fa@desktop.mysite.com.mail>
Mar 20 03:59:15 desktop postfix/qmgr[11164]: 6EFB75260BDD: from=<gitlab@localhost.mysite.com>, size=696, nrcpt=1 (queue active)
Mar 20 03:59:15 desktop postfix/error[12380]: 6EFB75260BDD: to=<dummy@comcast.net>, relay=none, delay=0.19, delays=0.09/0.01/0/0.09, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to mx1.comcast.net[xx.xx.xx.xxx]:25: Connection timed out)

Last edited by NotionCommotion; 03-20-2014 at 12:15 PM.
 
Old 03-20-2014, 04:13 PM   #2
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 338

Original Poster
Rep: Reputation: Disabled
Hi,

Does anyone have any ideas?

Maybe another question is why postfix is trying to use comcast.net. Yes, my Internet provider is comcast, but I don't remember editing a Linux configuration file and putting that in (but then again, I might have an forgotten!).

Please provide any suggestions how I could troubleshoot this.

Thank you
 
Old 03-20-2014, 06:46 PM   #3
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 338

Original Poster
Rep: Reputation: Disabled
Actually, it appears to have nothing to do with comcast. I sent an email to a gmail account, and now I see google and not comcast.

Note that I tried to show only responses in /var/log/maillog that pertain to the last email sent, but I think there might be a few stranglers from earlier emails.

Please provide any clues.

Code:
Mar 20 10:41:09 desktop postfix/qmgr[3279]: B01CB5260BE9: from=<gitlab@localhost.mysite.com>, size=697, nrcpt=1 (queue active)
Mar 20 10:41:09 desktop postfix/qmgr[3279]: 161965260BE5: from=<gitlab@localhost.mysite.com>, size=701, nrcpt=1 (queue active)
Mar 20 10:41:09 desktop postfix/smtp[6424]: connect to gmail-smtp-in.l.google.com[2607:f8b0:400e:c01::1b]:25: Network is unreachable
Mar 20 10:41:27 desktop postfix/pickup[5639]: 376C55260BBF: uid=495 from=<gitlab@localhost>
Mar 20 10:41:27 desktop postfix/cleanup[6430]: 376C55260BBF: message-id=<532b2847196a4_d293f982ac74280819d2@desktop.mysite.com.mail>
Mar 20 10:41:27 desktop postfix/qmgr[3279]: 376C55260BBF: from=<gitlab@localhost.mysite.com>, size=697, nrcpt=1 (queue active)
Mar 20 10:41:27 desktop postfix/smtp[6433]: connect to gmail-smtp-in.l.google.com[2607:f8b0:400e:c01::1a]:25: Network is unreachable
Mar 20 10:41:39 desktop postfix/smtp[6425]: connect to mail.dummy.com[xx.xxx.xxx.xxx]:25: Connection timed out
Mar 20 10:41:39 desktop postfix/smtp[6425]: 161965260BE5: to=<michael@dummy.com>, relay=none, delay=1482, delays=1451/0.01/30/0, dsn=4.4.1, status=deferred (connect to mail.dummy.com[xx.xxx.xxx.xxx]:25: Connection timed out)
Mar 20 10:41:39 desktop postfix/smtp[6424]: connect to gmail-smtp-in.l.google.com[zzz.zzz.zz.zz]:25: Connection timed out
Mar 20 10:41:39 desktop postfix/smtp[6424]: connect to alt1.gmail-smtp-in.l.google.com[2607:f8b0:4001:c05::1b]:25: Network is unreachable
Mar 20 10:41:57 desktop postfix/smtp[6433]: connect to gmail-smtp-in.l.google.com[zzz.zzz.zz.zz]:25: Connection timed out
Mar 20 10:41:57 desktop postfix/smtp[6433]: connect to alt1.gmail-smtp-in.l.google.com[2607:f8b0:4001:c05::1b]:25: Network is unreachable
Mar 20 10:42:09 desktop postfix/smtp[6424]: connect to alt1.gmail-smtp-in.l.google.com[yy.yyy.yyy.yy]:25: Connection timed out
Mar 20 10:42:09 desktop postfix/smtp[6424]: connect to alt2.gmail-smtp-in.l.google.com[2607:f8b0:4002:c07::1a]:25: Network is unreachable
Mar 20 10:42:09 desktop postfix/smtp[6424]: B01CB5260BE9: to=<dummy@gmail.com>, relay=none, delay=1132, delays=1072/0.01/60/0, dsn=4.4.1, status=deferred (connect to alt2.gmail-smtp-in.l.google.com[2607:f8b0:4002:c07::1a]:25: Network is unreachable)
Mar 20 10:42:27 desktop postfix/smtp[6433]: connect to alt1.gmail-smtp-in.l.google.com[yy.yyy.yyy.yy]:25: Connection timed out
Mar 20 10:42:27 desktop postfix/smtp[6433]: connect to alt2.gmail-smtp-in.l.google.com[2607:f8b0:4002:c07::1a]:25: Network is unreachable
Mar 20 10:42:27 desktop postfix/smtp[6433]: 376C55260BBF: to=<dummy@gmail.com>, relay=none, delay=60, delays=0.14/0.01/60/0, dsn=4.4.1, status=deferred (connect to alt2.gmail-smtp-in.l.google.com[2607:f8b0:4002:c07::1a]:25: Network is unreachable)
 
Old 03-20-2014, 07:09 PM   #4
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 338

Original Poster
Rep: Reputation: Disabled
I have a hardware firewall between my Comcast modem and my PC, Centos server, etc. Since it is only outgoing, this could not be the problem, right?
 
Old 03-20-2014, 10:12 PM   #5
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 338

Original Poster
Rep: Reputation: Disabled
Plese?
 
Old 03-21-2014, 01:27 PM   #6
Habitual
Senior Member
 
Registered: Jan 2011
Distribution: Slack14_64_Multilib
Posts: 3,075
Blog Entries: 4

Rep: Reputation: 745Reputation: 745Reputation: 745Reputation: 745Reputation: 745Reputation: 745Reputation: 745
Most of those are network timeouts and not indicative of a postfix configuration issue.
Have you done anything to iptables? Maybe you blocked a port you shouldn't have?

Code:
iptables -L -n
will show those rules, if any exist.

you can further test your connectivity issue(s) by a few simple methods:
Code:
telnet mailhost 25
ping <mail_host_ip>
and a good "tool" I use to examine what's going on is
Code:
sendmail -v -q
Have a gander at http://www.postfix.org/SOHO_README.html

I wish I could be more helpful.

Edit: NO mailserver I know of will accept "gitlab@localhost"
See myhostname and mydomain at http://wiki.centos.org/HowTos/postfi...4db84812c8dbfd

Last edited by Habitual; 03-21-2014 at 01:34 PM.
 
  


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
set up postfix for sending and receiving external emails lindampofu Linux - Newbie 1 09-26-2012 06:47 AM
[Postfix] Block sending emails outside of the domain fabler Linux - Server 0 07-07-2011 02:35 AM
Centos 5.x: Postfix not sending emails via telnet, no error on logs? klabacita Linux - Server 2 12-09-2009 02:47 AM
Postfix - problem with sending emails from Outlook, Thunderbird... dlugasx Linux - Server 1 11-22-2009 10:58 PM
Postfix - sending emails and connection timeouts endfx Linux - Server 2 08-18-2007 11:45 PM


All times are GMT -5. The time now is 03:38 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