NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: bin/46423: dhcpcd does not send hostname to server, even if requested to do.
The following reply was made to PR bin/46423; it has been noted by GNATS.
From: Thomas Schweikle <tschweikle%googlemail.com@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc:
Subject: Re: bin/46423: dhcpcd does not send hostname to server, even if
requested
to do.
Date: Tue, 08 May 2012 16:41:03 +0200
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enig362411AD5C47DB1EB2925246
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
Am 07.05.2012 22:20, schrieb Roy Marples:
> The following reply was made to PR bin/46423; it has been noted by GNAT=
S.
>=20
> From: Roy Marples <roy%marples.name@localhost>
> To: <gnats-bugs%netbsd.org@localhost>
> Cc:=20
> Subject: Re: bin/46423: dhcpcd does not send hostname to server, even i=
f
> requested to do.
> Date: Mon, 07 May 2012 21:19:45 +0100
>=20
> dhcpcd-5.1.3 on my amd64 NetBSD-5.1 server works fine
> Here's a tcpdump demonstrating this.
> =20
> With "hostname fooey" in /etc/dhcpcd.conf
> =20
> uberserver$ sudo tcpdump -i rtk0 -vvv -s 0 port bootps =
=20
does not ;-)
---
$ cat /var/lib/misc/dnsmasq.leases
1336485899 00:0c:29:d1:98:bc 172.19.8.141 * *
---
---
15:34:59.562519 IP (tos 0x10, ttl 32, id 0, offset 0, flags [none],
proto UDP (17), length 328)
0.0.0.0.68 > 255.255.255.255.67: [udp sum ok] BOOTP/DHCP,
Request from 00:0c:29:d1:98:bc, length 300, xid 0xa616ae26, Flags
[none] (0x0000)
Client-Ethernet-Address 00:0c:29:d1:98:bc
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Discover
Requested-IP Option 50, length 4: 172.19.8.141
Parameter-Request Option 55, length 7:
Subnet-Mask, BR, Time-Zone, Default-Gateway
Domain-Name, Domain-Name-Server, Hostname
---
Asking for Hostname, even if configured not to.
Not handling a hostname to the server, even if configured to.
---
END Option 255, length 0
PAD Option 0, length 0, occurs 41
15:34:59.598406 IP (tos 0x0, ttl 64, id 61945, offset 0, flags
[none], proto UDP (17), length 331)
172.19.8.1.67 > 172.19.8.141.68: [udp sum ok] BOOTP/DHCP, Reply,
length 303, xid 0xa616ae26, Flags [none] (0x0000)
Your-IP 172.19.8.141
Server-IP 172.19.8.1
Client-Ethernet-Address 00:0c:29:d1:98:bc
file "boot/grub/i386-pc/core.0"
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Offer
Server-ID Option 54, length 4: 172.19.8.1
Lease-Time Option 51, length 4: 1800
RN Option 58, length 4: 900
RB Option 59, length 4: 1575
Subnet-Mask Option 1, length 4: 255.255.255.0
Domain-Name Option 15, length 9: "fritz.box"
Domain-Name-Server Option 6, length 4: 172.19.8.1
Default-Gateway Option 3, length 4: 172.19.8.2
BR Option 28, length 4: 172.19.8.255
END Option 255, length 0
---
/etc/dhcpcd.conf:
---
# $NetBSD: dhcpcd.conf,v 1.1.1.1.8.3 2009/11/23 03:13:28 snj Exp $
#
# A sample configuration for dhcpcd.
# See dhcpcd.conf(5) for details.
# Inform the DHCP server of our hostname for DDNS.
hostname arve
# To share the DHCP lease across OSX and Windows a ClientID is needed.
# Enabling this may get a different lease than the kernel DHCP client.
# Some upstream DHCP servers may also require a ClientID, such as
FRITZ!Box.
#clientid
# A list of options to request from the DHCP server.
#option domain_name_servers, domain_name, domain_search, host_name
option domain_name_servers, domain_name, domain_search
option classless_static_routes
# Most distributions have NTP support.
option ntp_servers
# Respect the network MTU.
option interface_mtu
# A ServerID is required by RFC2131.
require dhcp_server_identifier
# A hook script is provided to lookup the hostname if not set by the
DHCP
# server, but it should not be run by default.
nohook lookup-hostname
---
Even if the manual states dhcpcd shall be used, dhclient is started.
After creating the neccessary configuration file, dhclient now sends
the hostname. Looks like docs are wrong here: dhclient is default,
not dhcpcd. Changing to dhcpcd in rc.conf makes the whole thing work
too.
--=20
Thomas
--------------enig362411AD5C47DB1EB2925246
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: GnuPT 2.9.2
iEYEARECAAYFAk+pMIUACgkQJuPdOes4UCQBzwCgnwcZGVrmcbvCEwHF5zntJugR
VtwAn3981xxfbH+iu9szKXgQDooPjhDi
=IU52
-----END PGP SIGNATURE-----
--------------enig362411AD5C47DB1EB2925246--
Home |
Main Index |
Thread Index |
Old Index