LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 05-27-2005, 06:06 AM   #1
60s TV Batman
Member
 
Registered: Oct 2004
Location: London (UK)
Distribution: Ubuntu 12.04
Posts: 60

Rep: Reputation: 17
Can receive email but can't send it


Hi there

I have Fedora 3 with Kernel 2.6.11-1.27_FC3. I've also registered the domain gx7.co.uk, and pointed it at my static IP: 82.153.177.29

I can display a test webpage I set up with http://gx7.co.uk and I can send mail to wayne@gx7.co.uk from one of my other email accounts. I can download this email to Outlook Express on my windows PC. I can also see it by entering mail on my Linux box.

What I can't do is send mail out from my Linux box. For example, if I send mail from wayne@gx7.co.uk to wayne@megaresponse.com, it appears that Outlook has sent it, but the mail never arrives in my inbox.

This is what I see in my maillog file...

[deleted]: to=<wayne@megaresponse.com>, ctladdr=<wayne@gx7.co.uk> (500/500), delay=00:00:20, xdelay=00:00:20, mailer=esmtp, pri=120668, relay=megaresponse.com., dsn=4.0.0, stat=Deferred: Name server: megaresponse.com.: host name lookup failure

NOTE: Despite the log saying "megaresponse.com.: host name lookup failure", I can use this email account to send and receive and dig/dig -x works just fine with megaresponse.com and it's IP. So the problem is with gx7.co.uk and/or Sendmail on my server.

When I try to mail my ISP email address from wayne@gx7.co.uk, I get a two messages in maillog, and a "may be forged" comment about the internal LAN IP address...

[deleted]from=<wayne@gx7.co.uk>, size=471, class=0, nrcpts=1, msgid=<[deleted]>, proto=SMTP, daemon=MTA, relay=gx7.co.uk [192.168.0.3] (may be forged)
[deleted]to=<wayne@starfleet.eclipse.co.uk>, delay=00:00:00, mailer=esmtp, pri=30471, dsn=4.4.3, stat=queued

I've also noticed that a dig gx7.co.uk works just fine, but a reverse DNS with dig -x 82.153.177.29 fails. Should I be concerned about this? And are these two problems related?

Last edited by 60s TV Batman; 05-27-2005 at 06:12 AM.
 
Old 05-27-2005, 10:30 AM   #2
Berhanie
Senior Member
 
Registered: Dec 2003
Location: phnom penh
Distribution: Fedora
Posts: 1,625

Rep: Reputation: 165Reputation: 165
I don't use Sendmail, so I may be off in my understanding of the logs; but my guess is that you have your SMART_HOST improperly defined. It may be something like
Code:
define(`SMART_HOST', `smtp.response.com')
instead of just
Code:
define(`SMART_HOST', `response.com')
 
Old 05-27-2005, 11:31 AM   #3
60s TV Batman
Member
 
Registered: Oct 2004
Location: London (UK)
Distribution: Ubuntu 12.04
Posts: 60

Original Poster
Rep: Reputation: 17
Hi and thanks for your reply

This didn't make a difference, and I'm not sure this is a smart_host problem anyway. For some reason, my system can't get a resolution on perfectly good domain names. I suspect it's not looking at the outside world...but don't know how to tell it to do this.
 
Old 05-27-2005, 12:13 PM   #4
Berhanie
Senior Member
 
Registered: Dec 2003
Location: phnom penh
Distribution: Fedora
Posts: 1,625

Rep: Reputation: 165Reputation: 165
You might try to ping a machine outside your network using the machine's IP address and, if successful, using its FQDN. If you are successful with the first but not with the second, then you have a name resolution problem.

I don't use Fedora (so, someone who does may give you more Fedora-specific info), but in general, one puts a list of domain name servers (the machines that translate names to ip addresses) in the file /etc/resolv.conf -- either directly or through some distro-specific tool.
 
Old 05-27-2005, 12:55 PM   #5
snarkout
Member
 
Registered: Apr 2005
Location: The Land Of Entrapment
Posts: 77

Rep: Reputation: 15
Post your sendmail.mc file. Before people can look at that, everything that is offered will be random stabs in the dark.

Is there a particular reason you're using sendmail? Most people find it confounding if they have no experience setting up mailservers (and many that do have exp find it equally as confounding).
 
Old 05-27-2005, 01:06 PM   #6
60s TV Batman
Member
 
Registered: Oct 2004
Location: London (UK)
Distribution: Ubuntu 12.04
Posts: 60

Original Poster
Rep: Reputation: 17
Quote:
Originally posted by snarkout
Is there a particular reason you're using sendmail? Most people find it confounding if they have no experience setting up mailservers
No specific reason, other than I don't know any better. Setting up a webserver is a project I've been wanting to get my teeth into. I have the Fedora 3 Bible, and that gives instructions for Sendmail.

As it happens, I've just managed to solve the problem by looking more deeply at what /etc/resolv.conf does, instead of relying on the sparse info in Fedora 3 Bible.

In case anyone else has this problem, and happens to read this post, my resolv.conf file contained only one nameserver...my router. Sendmail was obviously attempting to get domains resolved from my el cheapo ADSL router! That clearly wasn't going to work for external domains!

I added my domain register's nameserver IPs to resolv.conf, restarted Sendmail, and voila! A gazillion queued emails were suddenly delivered to my various email addresses.

I shan't be reporting myself for spam

Last edited by 60s TV Batman; 05-27-2005 at 01:11 PM.
 
Old 05-27-2005, 01:16 PM   #7
Berhanie
Senior Member
 
Registered: Dec 2003
Location: phnom penh
Distribution: Fedora
Posts: 1,625

Rep: Reputation: 165Reputation: 165
Good job!
 
Old 05-27-2005, 04:01 PM   #8
snarkout
Member
 
Registered: Apr 2005
Location: The Land Of Entrapment
Posts: 77

Rep: Reputation: 15
Good TSing!
 
Old 05-27-2005, 04:25 PM   #9
60s TV Batman
Member
 
Registered: Oct 2004
Location: London (UK)
Distribution: Ubuntu 12.04
Posts: 60

Original Poster
Rep: Reputation: 17
There is still one problem that remains. The changes I made to /etc/resolv.conf are lost when I reboot.

Does anyone know why and/or how to stop this from happening and/or how to get whatever is rewriting the file to rewrite it with the correct info?
 
Old 05-28-2005, 12:21 PM   #10
snarkout
Member
 
Registered: Apr 2005
Location: The Land Of Entrapment
Posts: 77

Rep: Reputation: 15
Add the line:

PEERDNS=no

to

/etc/sysconfig/network-scripts/ifcfg-eth0
(assuming you are using eth0 as your network interface - if not, edit the file that corresponds with the correct interface).

This should do the trick.

Edit: FWIW, this problem usually occurs when you are using DHCP, and you should probably not be using DHCP for a mailserver. Just a thought.

Last edited by snarkout; 05-28-2005 at 12:22 PM.
 
Old 06-26-2005, 07:37 AM   #11
jollyjoice
Member
 
Registered: Aug 2003
Location: UK
Distribution: Gentoo 64
Posts: 383

Rep: Reputation: 30
thanks guys, that was just what i was looking for!
 
  


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
I can't send out email neither receive any... ultrax Linux - Wireless Networking 2 02-12-2008 09:16 AM
Can send email, not receive hanasi SUSE / openSUSE 5 07-16-2005 04:05 PM
can't receive email but ok to send? taiwf Linux - Newbie 2 07-05-2005 05:27 PM
I can send but cannot receive email quickk Linux - Newbie 1 11-03-2004 06:49 AM
Can receive email but can't send retarded Linux - Newbie 7 03-18-2004 07:37 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

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