[sles-beta] SLES12 x86_64 Beta3 autoyast issue /etc/hosts no hostname entry
Marius Tomaschewski
mt at suse.de
Wed Mar 26 01:52:37 MDT 2014
Am 25.03.2014 17:02, schrieb urs.frey at post.ch:
> Hi
Hi!
BTW: You don't need to add me to Cc -- I'm on the list too :-)
I don't have much clue about all the yast2 stuff -- I'm one from
the backend (wicked + sysconfig) side.... but let's try:
> In my autoinst.xml I do have DNS and hostname definition included.
> But on the installed server in /etc/hosts there gets only localhost defined,
> the entry of the own IP address and hostname is missing
>
> <networking>
> <dns>
> <dhcp_hostname config:type="boolean">false</dhcp_hostname>
AFAIS, this causes to set DHCLIENT_SET_HOSTNAME="no"
> <dhcp_resolv config:type="boolean">false</dhcp_resolv>
A "grep -rl dhcp_resolv $(rpm -ql autoyast2-installation)" does not show
any match.
> <domain>pnet.ch</domain>
> <hostname>h063uz</hostname>
-> AFAIS, it causes to write $hostname.$domain into /etc/HOSTNAME
> <nameservers config:type="list">
> <nameserver>10.1.121.11</nameserver>
> <nameserver>10.2.121.11</nameserver>
> </nameservers>
-> NETCONFIG_DNS_STATIC_SERVERS
> <searchlist config:type="list">
> <search>pnet.ch</search>
> <search>post.ch</search>
> </searchlist>
-> NETCONFIG_DNS_STATIC_SEARCHLIST
> </dns>
[...]
> /etc/hosts file I get
>
> h063uz:~ # cat /etc/hosts
[...]
> h063uz:~ #
IMO it looks fine with this profile.
> Do I look at the wrong end? I mean in all our /etc/hosts files there is an entry
> When I do install the very same server manually and configure the network in yast2
> I do end up with an /etc/hosts entry
>
> 127.0.0.1 localhost
> 10.226.154.19 h063uz.pnet.ch h063uz
This is caused by the yast2 only setting WRITE_HOSTNAME_TO_HOSTS=yes [it
is never used by anything else] -- default is "no" and it may be
set by some per-product defaults.
Note: it disables dns lookups for the own hostname & ip completely
and may break things.
I'd say, you profile is missing this statement in <dns>:
<write_hostname config:type="boolean">true</write_hostname>
Gruesse / Regards,
Marius Tomaschewski <mt at suse.de>, <mt at suse.com>
--
SUSE LINUX Products GmbH, HRB 16746 (AG Nürnberg),
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer,
Maxfeldstraße 5, 90409 Nürnberg, Germany
More information about the sles-beta
mailing list