LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-20-2003, 02:49 AM   #1
eggoz
Member
 
Registered: Feb 2003
Posts: 159

Rep: Reputation: 30
Mail and /etc/hosts


I know I am missing something here.

My eth1 ip is set to 192.168.0.7.

In the sendmail.mc file, I have this line: DAEMON_OPTIONS(`port=smtp,Addr=192.168.0.7, Name=MTA-v6, Family=inet6')dnl

And in my hosts file looks like this:
127.0.0.1 backup localhost.localdomain localhost
192.168.0.7 pavilionhome.dyndns.org backup

Not really sure what should be in here. But when I start the sendmail server, i get this error:

Starting sendmail: 554 5.3.0 /etc/mail/sendmail.cf: line 270: host "192.168.0.7" unknown

What am I missing? Thanks.
 
Old 06-20-2003, 04:12 PM   #2
Shin Takeshita
LQ Newbie
 
Registered: Dec 2002
Location: Novi, MI
Distribution: Red Hat
Posts: 25

Rep: Reputation: 15
I apologize beforehand that I am not answering your question.

I am curious as to what may happen if you type "ping backup".
 
Old 06-21-2003, 02:08 AM   #3
eggoz
Member
 
Registered: Feb 2003
Posts: 159

Original Poster
Rep: Reputation: 30
Quiet alright. It pings it with no problem.
 
Old 06-21-2003, 01:30 PM   #4
defa0009
Member
 
Registered: Jun 2003
Posts: 185

Rep: Reputation: 31
Shouldn't it be just:

127.0.0.1 localhost.localdomain localhost


Also have you come across this link: http://www.nmia.com/~glenn/protech/sendmail.htm

Last edited by defa0009; 06-21-2003 at 01:48 PM.
 
Old 06-21-2003, 01:42 PM   #5
defa0009
Member
 
Registered: Jun 2003
Posts: 185

Rep: Reputation: 31
Open /etc/mail/sendmail.mc in a text editor.
Find the line that begins DAEMON-OPTIONS and lists the loopback IP address (127.0.0.1).
Type dnl at the beginning of this line. dnl means "delete to new line" - in other words, it comments out what follows.


So in your case you would have:

dnl DAEMON_OPTIONS(`port=smtp,Addr=192.168.0.7, Name=MTA-v6, Family=inet6')

Last edited by defa0009; 06-21-2003 at 01:43 PM.
 
Old 06-21-2003, 02:08 PM   #6
Robert0380
LQ Guru
 
Registered: Apr 2002
Location: Atlanta
Distribution: Gentoo
Posts: 1,280

Rep: Reputation: 47
inet6??????? why is it setup for IP version 6?
 
Old 06-22-2003, 03:22 AM   #7
eggoz
Member
 
Registered: Feb 2003
Posts: 159

Original Poster
Rep: Reputation: 30
wait a tick. you want me to comment out 127.0.0.1 or 192.168.0.7?

Woah, that link looks great. Take a look tomarrow when i'm not half asleep.

Thanks.
 
Old 06-23-2003, 02:50 AM   #8
eggoz
Member
 
Registered: Feb 2003
Posts: 159

Original Poster
Rep: Reputation: 30
OK, quick question I hope.

On this page, Link , it says,
Quote:
Make sure that you have a line listing the IP address of your server, followed by any and all domain names it services, in all their variants.
Well, what if your server was behind a router? No problem correct?.

But, what if you had a dyanmic ip? My domain, imagiro-1.com, is forwarded to the dyndns service, then to my main comp at pavilionhome.dyndns.org. Which IP would I use? Thanks.
 
Old 06-23-2003, 08:19 AM   #9
Shin Takeshita
LQ Newbie
 
Registered: Dec 2002
Location: Novi, MI
Distribution: Red Hat
Posts: 25

Rep: Reputation: 15
Let me clariy my earlier question of "what happens if you ping backup". Which IP address responds?
 
Old 06-23-2003, 08:24 AM   #10
defa0009
Member
 
Registered: Jun 2003
Posts: 185

Rep: Reputation: 31
If your behind a router no problem but if not then you would have to change the ip in /etc/hosts everytime yours changed. But if you have a router just put the ip of the machine acting as the mail server.

Dynamic ip doesn't matter if the mail server sending you mail can find your router through the dyndns service then your router just forwards it to the machine's ip on the LAN. I use a router and just forward port 110 and 25 to my mail server at 192.168.1.6
 
Old 06-23-2003, 12:43 PM   #11
eggoz
Member
 
Registered: Feb 2003
Posts: 159

Original Poster
Rep: Reputation: 30
Shin, you just showed me a huge mistake that I thought was happening. Ping backup gives me an ip of 127.0.0.1. Major reason why I can't send mail.

My hosts file:

127.0.0.1 backup localhost.localdomain localhost
192.168.0.7 imagiro-1.com backup
24.50.15.130 smtp smtp.imagiro-1.com imagiro-1.com

The last ip is my ip assigned to me right now by my isp. Where should "backup" be located?

def, What about recieving mail? I was thinking of using the dyndns server. I read somebody else did that. I'll have to find the post where I read that.
 
  


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
External Hosts Resolve but Local Hosts Do Not kjm9 Linux - Networking 7 11-19-2005 03:51 PM
hosts.allow spawn /bin/mail zzyzx Slackware 8 08-23-2005 11:24 AM
hosts.allow & hosts.deny question... jonc Linux - Security 9 03-05-2005 09:41 PM
Adding shell commands to hosts.deny and hosts.allow ridertech Linux - Security 3 12-29-2003 03:52 PM
Maddening sendmail problem -- cant send mail to remote hosts! HELP! Bungo2000 Linux - Networking 11 06-09-2003 03:33 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

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