Bug 596163 - System does not use the hostname from dhcp server
Summary: System does not use the hostname from dhcp server
Status: RESOLVED FIXED
Alias: None
Product: openSUSE 11.3
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: Factory
Hardware: i386 Other
: P3 - Medium : Major (vote)
Target Milestone: RC 2
Assignee: Bin Li
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-13 13:57 UTC by Maximilian Maher
Modified: 2016-04-15 11:01 UTC (History)
2 users (show)

See Also:
Found By: Component Test
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maximilian Maher 2010-04-13 13:57:37 UTC
In openSUSE 11.3 Milestone 5 the Machine gets some random hostname.
In Milestone 4 the same machine, after the installation got the hostname from the
dhcp server.
Comment 1 Marc Schütz 2010-04-14 13:13:05 UTC
I can confirm this. Neither the hostname, nor the search domains are set. I'm raising importance to "major", as for some services to work correctly (e.g. kerberos), a correct hostname is necessary.
Comment 2 Marius Tomaschewski 2010-04-16 08:28:58 UTC
Do you have NetworkManager running or ifup / sysconfig?
Comment 3 Marius Tomaschewski 2010-04-16 08:35:24 UTC
And provide also the output from "dhcpcd-test eth0" please and
also "host IP.ADD.RE.SS".
Comment 4 Marc Schütz 2010-04-20 09:02:11 UTC
Here is the ouput of "dhcpcd-test eth1":
info, eth1: hardware address = 00:0d:61:06:d9:17
info, eth1: broadcasting for a lease
debug, eth1: sending DHCP_DISCOVER with xid 0x4f26a5b2
debug, eth1: waiting for 10 seconds
debug, eth1: got a packet with xid 0x4f26a5b2
info, eth1: offered 132.180.194.66 from 132.180.194.192
IPADDR='132.180.194.66'
NETMASK='255.255.255.0'
NETWORK='132.180.194.0'
BROADCAST='132.180.194.255'
ROUTES=''
GATEWAYS='132.180.194.254'
DNSDOMAIN='inf.uni-bayreuth.de'
DNSSERVERS='132.180.194.192 132.180.17.1 132.180.17.129'
NTPSERVERS='132.180.194.192'
DHCPSID='132.180.194.192'
LEASETIME='6000'
RENEWALTIME='3000'
REBINDTIME='5250'
INTERFACE='eth1'
CLASSID='dhcpcd 3.2.3'
CLIENTID='01:00:0d:61:06:d9:17'
DHCPCHADDR='00:0d:61:06:d9:17'
info, eth1: exiting

host 132.180.194.66:
66.194.180.132.in-addr.arpa domain name pointer resy-techniker.inf.uni-bayreuth.de.

host resy-server:
Host resy-server not found: 3(NXDOMAIN)
=> does not use search path "inf.uni-bayreuth.de"

This is while using ifup. With NetworkManager the output of dhcpcd-test is the same, but the domain search path is correctly set in /etc/resolv.conf now:

host resy-server:
resy-server.inf.uni-bayreuth.de has address 132.180.194.192

Interestingly, if I switch back to if-up again (and call rcnetwork restart), the entries in /etc/resolv.conf are not removed, so it is still working.

After I've played around a bit with /etc/resolv.conf, I noticed that rcnetwork restart now prints:

ATTENTION: You have modified /etc/resolv.conf.  Leaving it untouched...
You can find my version in /etc/resolv.conf.netconfig ...

Although I hadn't manually modified /etc/resolv.conf when it stopped working, maybe a modification made during factory update was mis-detected as a manual modification?

When I delete both /etc/resolv.conf and /etc/resolv.conf.netconfig and restart the network, everything seems to work now.

(Not removing NEEDINFO because I'm not the original reporter. @mmaher: Would be nice if you can confirm my findings.)
Comment 5 Maximilian Maher 2010-04-20 09:08:22 UTC
@marc: i can confirm you information.
Comment 6 Marius Tomaschewski 2010-04-26 08:10:34 UTC
(In reply to comment #4)
> Although I hadn't manually modified /etc/resolv.conf when it stopped working,
> maybe a modification made during factory update was mis-detected as a manual
> modification?

Hmm... Maybe. But I think, some program modified it (dhcp client started by
the initrd / yast2 copied a config from install system / another software?).

Do you have the "modified original"? When yes, please reopen and attach.
Usually it is visible in the comment what modified it.

I'm closing this bug report for now, because it didn't happened during my
updates, but please reopen and attach the resolv.conf when it happens again.

> When I delete both /etc/resolv.conf and /etc/resolv.conf.netconfig and restart
> the network, everything seems to work now.

BTW:
A "netconfig update -f" or "netconfig update -m dns -f" should fix it too.
Comment 7 Marius Tomaschewski 2010-05-07 23:04:00 UTC
NetworkManager writes the resolv.conf directly too instead via netconfig.
Comment 9 Bin Li 2010-06-29 09:28:10 UTC
Fixed.
The request id is 42233.
Comment 10 Bernhard Wiedemann 2016-04-15 11:01:02 UTC
This is an autogenerated message for OBS integration:
This bug (596163) was mentioned in
https://build.opensuse.org/request/show/42233 11.3 / NetworkManager