[PLUG] Host Unknown Problem After Name Change

Bill Thoen bthoen at gisnet.com
Sun Apr 10 02:22:14 UTC 2011


On Sat, Apr 09, 2011 at 08:49:00AM -0700, Rich Shepard wrote:
> On Sat, 9 Apr 2011, Bill Thoen wrote:
> 
> > I've recently set up a new web server running CentOS 5.5 and I wanted to
> > change the machine name from what it was named when it wsa built to
> > something else.  So I set hostname=hotspur.gisnet.local and changed the
> > HOSTNAME= line in /etc/sysconfig/network to HOSTNAME=hotspur.gisnet.local.
> 
> Bill,
> 
>    What do you have in /etc/hosts? Each machine on the LAN should have the
> same contents. The format usually is IP address, white space, full name
> (e.g., hotspur.gisnet.local), white space, alias (e.g. hotspur).

This is what's in one of my machine's /etc/hosts. I just put names in these
for convenience' sake. I didn't think these were all that criitcal for
changing a machine's name, but like I've said before I've got a lot to
learn about system administration.

/etc/hosts:
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1               localhost.localdomain localhost
::1             localhost.localdomain6 localhost6


>    On Slackware (and, if I recall correctly, in Red Hat), the network
> configuration has separate key/value pairs for hostname, network name, host
> IP, gateway IP, and DNS IP.

In hosts? I thought that stuff would be in /etc/syhsconfig/network or
somewhere down that networking directory tree in razamatz.cf or
ishkabibble.conf. (Sorry, but was this stuff hard to learn when you were
first going at it? I think it's especially hard for the knowlessman because
it's in networking where several major software packages come together, and
half the time when I try to debug these sorts of things I don't even know
what I'm looking for, let alone know in what package the problem origiinates. 

What's strange is that even thuogh I've changed hostname interactively, and
also reset it in the /etc/sysconfig/network, and then re-starting
sendmail, the log entries are still using the old name
'lower.gisnet.local'. Also if I enter this command:

> sendmail -bt -d0.1 </dev/null

I get some pretty clear evidence that the new name hasn't 'stuck':

> Version 8.13.8
>  Compiled with: DNSMAP HESIOD HES_GETMAILHOST LDAPMAP LOG MAP_REGEX
>                 MATCHGECOS MILTER MIME7TO8 MIME8TO7 NAMED_BIND NETINET
> NETINET6
>                 NETUNIX NEWDB NIS PIPELINING SASLv2 SCANF SOCKETMAP
> STARTTLS
>                 TCPWRAPPERS USERDB USE_LDAP_INIT
> 
> ============ SYSTEM IDENTITY (after readcf) ============
>       (short domain name) $w = lower
>   (canonical domain name) $j = lower.gisnet.local
>          (subdomain name) $m = gisnet.local
>               (node name) $k = lower.gisnet.local
> ========================================================

I don't really want edit sendmail.cf, but from the Internet research I've
been doing it looks some do exactly that. Beacuse I found three ways to
solve this (supposedly) and all of them seem fairly complicated, I thought
I'd ask here and get some clarification before I try something I don't
understand. Here's the two (old) web sites I've got that claim to have the
solution (I think):
http://www.linuxquestions.org/questions/linux-server-73/change-sender-address-of-outgoing-emails-in-sendmail-571828/
and 
http://cbl.abuseat.org/sendmailhelp.html 

TIA,

- Bill Thoen



More information about the PLUG mailing list