LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 12-08-2005, 01:52 PM   #1
schentor
Member
 
Registered: Jul 2005
Distribution: RHEL, Mint, Ubuntu
Posts: 32

Rep: Reputation: 15
sendmail using wrong hostname


I maintain a server on a LAN that is having problems with sendmail. The daily logwatch emails sent to root are sometimes returned because of an incorrectly spelled hostname. Other times they get through, and the hostname in the headers look fine. When I send emails from pine, they always go through correctly. However, in all situations /var/log/maillog misspells the hostname. The hostname listed in /etc/hosts and /etc/sysconfig/network is correct. Can someone help with this? Thanks in advance.

The returned email:

Code:
Subject:
Returned mail: see transcript for details
From:
Mail Delivery Subsystem <MAILER-DAEMON@sallly.network.com>
Date:
Thu, 8 Dec 2005 04:17:35 -0800
To:
root@sallly.network.com
X-Account-Key:
account4
X-UIDL:
@D3!!,Be"!"o6!!-2_!!
X-Mozilla-Status:
0001
X-Mozilla-Status2:
10000000
Received:
from sallly.network.com (sally.network.com [xxx.xxx.xxx.xxx]) by mailserver.network.com (8.12.10/8.12.10) with ESMTP id jB8CHZ60024468 for <schen@network.com>; Thu, 8 Dec 2005 04:17:35 -0800 (PST)
Received:
from localhost (localhost) by sallly.network.com (8.11.6/8.11.6) id jB8CHZi20209; Thu, 8 Dec 2005 04:17:35 -0800
Message-ID:
<200512081217.jB8CHZi20209@sallly.network.com>
MIME-Version:
1.0
Auto-Submitted:
auto-generated (failure)
X-Spam-Checker-Version:
SpamAssassin 2.63 (2004-01-11) on dagalas
X-Spam-Level:
*
X-Spam-Status:
No, hits=1.1 required=5.0 tests=NO_DNS_FOR_FROM autolearn=no version=2.63
X-network.com-MailScanner-Information:
Please contact the ISP for more information
X-network.com-MailScanner:
Found to be clean
Content-Type:
multipart/report; report-type=delivery-status; boundary="jB8CHZi20209.1134044255/sallly.network.com"
X-UIDL:
@D3!!,Be"!"o6!!-2_!!

The original message was received at Thu, 8 Dec 2005 04:02:01 -0800
from root@localhost

   ----- The following addresses had permanent fatal errors -----
schen@network.com
    (reason: 553 5.1.8 <root@sallly.network.com>... Domain of sender address root@sallly.network.com does not exist)
    (expanded from: root)

   ----- Transcript of session follows -----
... while talking to mail.network.com.:

>>>>>> MAIL From:<root@sallly.network.com> SIZE=312

<<< 553 5.1.8 <root@sallly.network.com>... Domain of sender address root@sallly.network.com does not exist
501 5.6.0 Data format error



Reporting-MTA: dns; sallly.network.com
Arrival-Date: Thu, 8 Dec 2005 04:02:01 -0800

Final-Recipient: RFC822; root@sallly.network.com
X-Actual-Recipient: RFC822; schen@network.com
Action: failed
Status: 5.1.8
Diagnostic-Code: SMTP; 553 5.1.8 <root@sallly.network.com>... Domain of sender address root@sallly.network.com does not exist
Last-Attempt-Date: Thu, 8 Dec 2005 04:17:35 -0800



Subject:
LogWatch for sally
From:
root <root>
Date:
Thu, 8 Dec 2005 04:02:01 -0800
To:
root
Return-Path:
<root>
Received:
(from root@localhost) by sally.network.com (8.11.6/8.11.6) id jB8C21D19511 for root; Thu, 8 Dec 2005 04:02:01 -0800
Message-ID:
<200512081202.jB8C21D19511@sally.network.com>

 ################## LogWatch 2.6 Begin ##################### 

 --------------------- sendmail Begin ------------------------ 

6095 bytes transferred
2 messages sent
 ---------------------- sendmail End ------------------------- 


 ###################### LogWatch End ######################### 

Part 1.2
	
Content-Type:
	message/delivery-status

LogWatch for sally.eml
	
Content-Type:
	message/rfc822
The correct hostname is sally, but sendmail thinks it's sallly. I've replaced the real domain with network.com.
 
Old 12-08-2005, 04:10 PM   #2
Finlay
Senior Member
 
Registered: Mar 2003
Location: Seattle
Distribution: Slackware ?-14.1
Posts: 1,029

Rep: Reputation: 47
if you type:
hostname
what do you get?
 
Old 12-08-2005, 04:27 PM   #3
schentor
Member
 
Registered: Jul 2005
Distribution: RHEL, Mint, Ubuntu
Posts: 32

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Finlay
if you type:
hostname
what do you get?
I get the correct hostname, 'sally' with two l's.
 
Old 12-08-2005, 04:33 PM   #4
Finlay
Senior Member
 
Registered: Mar 2003
Location: Seattle
Distribution: Slackware ?-14.1
Posts: 1,029

Rep: Reputation: 47
did you generate your own sendmail.cf file?

what do you get when you type:

cat /proc/sys/kernel/hostname
 
Old 12-08-2005, 04:59 PM   #5
schentor
Member
 
Registered: Jul 2005
Distribution: RHEL, Mint, Ubuntu
Posts: 32

Original Poster
Rep: Reputation: 15
cat /proc/sys/kernel/hostname gives the correct hostname. I don't know how sendmail.cf was generated, since sendmail was already set up when I started administrating this machine.
 
Old 12-08-2005, 07:08 PM   #6
KnightHawk
Member
 
Registered: Aug 2005
Posts: 128

Rep: Reputation: 15
check your /etc/mail/local-mailer-table

Its probably spelled wrong in there. With sendmail using the hostname as the "domain" is only the default action when the domain is not spelled out with the "Cw" directive either via the cf file or a local-mailer-table.
 
Old 12-09-2005, 01:53 PM   #7
schentor
Member
 
Registered: Jul 2005
Distribution: RHEL, Mint, Ubuntu
Posts: 32

Original Poster
Rep: Reputation: 15
This computer doesn't have /etc/mail/local-mailer-table. It did have blank file named /etc/mail/mailertable. I tried putting this line:
sally.gps.caltech.edu smtp:sally.gps.caltech.edu
in it and re-generated mailer-table.db and restarted sendmail, but the mail log is still displaying the wrong hostname. I couldn't find any mention of the incorrect hostname, "sallly", in /etc/sendmail.cf or in any of the files in /etc/mail.
 
  


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
RedHat Enterprise wrong hostname with POP3 AwoLtheMighty Red Hat 3 08-09-2005 10:38 PM
Wrong Hostname in the DNS and DHCP Address Leases of Windows 2000 saneax Linux - Networking 1 03-03-2005 03:14 AM
something is wrong with my hostname Paxmaster Linux - Networking 12 11-12-2004 06:17 PM
Hostname and Sendmail caps_phisto Linux - Networking 2 10-30-2004 11:51 AM
Wrong Hostname in a MS Domain Zeb Linux - Networking 0 03-16-2004 03:32 AM

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

All times are GMT -5. The time now is 12:52 AM.

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