NetBSD Problem Report #48140

From gson@gson.org  Wed Aug 21 08:51:54 2013
Return-Path: <gson@gson.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 84DD1710B4
	for <gnats-bugs@gnats.NetBSD.org>; Wed, 21 Aug 2013 08:51:54 +0000 (UTC)
Message-Id: <20130821085142.9465075E3B@guava.gson.org>
Date: Wed, 21 Aug 2013 11:51:42 +0300 (EEST)
From: gson@gson.org (Andreas Gustafsson)
Reply-To: gson@gson.org (Andreas Gustafsson)
To: gnats-bugs@gnats.NetBSD.org
Subject: dhcpcd fails to get lease in -current
X-Send-Pr-Version: 3.95

>Number:         48140
>Category:       bin
>Synopsis:       dhcpcd fails to get lease in -current
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    roy
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Aug 21 08:55:00 +0000 2013
>Closed-Date:    Sat Oct 18 16:44:07 +0000 2014
>Last-Modified:  Sun Oct 19 23:30:00 +0000 2014
>Originator:     Andreas Gustafsson
>Release:        NetBSD-current, cvs date >= 2013.06.21.19.47.29
>Organization:
>Environment:
System: NetBSD
Architecture: i386
Machine: i386
>Description:

Previously, when I have run NetBSD under qemu and specified the options
"--net user --net nic,model=ne2k_pci" on the qemu command line, I have
been able to connect to the Internet from the qemu guest.

I recently tried the same thing using a fresh NetBSD-current, and was
unable to get a DHCP lease.  Running "dhcpcd" as root, I see:

  dhcpcd[382]: version 6.0.0 starting
  dhcpcd[382]: ne2: waiting for carrier
  dhcpcd[382]: timed out
  Aug 21 08:17:07  dhcpcd[382]: timed out
  dhcpcd[382]: allowing 8 seconds for IPv4LL timeout
  dhcpcd[382]: timed out
  dhcpcd[382]: forked to background, child pid 381

Using an automated binary search, I have determined that the last
working version was CVS date 2013.06.21.19.16.01, and the first broken
one is 2013.06.21.19.47.29.  This is when dhcpcd-6.0.0 was imported.

This was tested using qemu version 1.2.0.  I have not tried
reproducing the problem on a physical machine, so those may or may not
be affected.

If I manually run "ifconfig ne2 up" before starting dhcpcd, it works.

>How-To-Repeat:

$ sudo pkg_add qemu
$ ftp http://nyftp.netbsd.org/pub/NetBSD-daily/HEAD/201308200140Z/i386/installation/cdrom/boot-com.iso
$ qemu-system-i386 --nographic --snapshot --cdrom boot-com.iso --net user --net nic,model=ne2k_pci

When prompted for a terminal type, just hit enter.

When sysinst starts, type control-c to get a shell prompt.

# dhcpcd

>Fix:

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: bin-bug-people->roy
Responsible-Changed-By: gson@NetBSD.org
Responsible-Changed-When: Sat, 07 Sep 2013 15:36:46 +0000
Responsible-Changed-Why:
Roy has a patch.


From: "Roy Marples" <roy@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/48140 CVS commit: src/external/bsd/dhcpcd/dist
Date: Fri, 20 Sep 2013 10:51:30 +0000

 Module Name:	src
 Committed By:	roy
 Date:		Fri Sep 20 10:51:30 UTC 2013

 Update of /cvsroot/src/external/bsd/dhcpcd/dist
 In directory ivanova.netbsd.org:/tmp/cvs-serv2867

 Log Message:
 Import dhcpcd-6.1.0 with the following changes:
 * Fixed a segfault when configuring a static route in dhcpcd.conf
 * Merged IPv6 ND and RA codebases
 * Persistent configuration is now a default option in dhcpcd.conf
 * Store configured IPv4 addresses against the interface so we only add
   them if actually missing to avoid RTM_DELADDR/NEWADDR loops on some OS's
 * waitip now supports waiting for any, IPv4, IPv6 or both protocols
 * DHCPv6 addresses are added with a /128 prefix and should not attempt to
   associate with any existing prefix or make one up as per RFC 5942
 * Fix initial carrier status
 * Fix requesting >1 DHCPv6 address

 Fixes PR bin/48140


 Status:

 Vendor Tag:	roy
 Release Tags:	dhcpcd-6-1-0

 U src/external/bsd/dhcpcd/dist/common.c
 U src/external/bsd/dhcpcd/dist/control.c
 U src/external/bsd/dhcpcd/dist/dhcpcd.c
 U src/external/bsd/dhcpcd/dist/duid.c
 U src/external/bsd/dhcpcd/dist/eloop.c
 U src/external/bsd/dhcpcd/dist/if-options.c
 U src/external/bsd/dhcpcd/dist/if-pref.c
 C src/external/bsd/dhcpcd/dist/net.c
 U src/external/bsd/dhcpcd/dist/script.c
 U src/external/bsd/dhcpcd/dist/dhcp-common.c
 U src/external/bsd/dhcpcd/dist/bpf.c
 U src/external/bsd/dhcpcd/dist/if-bsd.c
 U src/external/bsd/dhcpcd/dist/platform-bsd.c
 U src/external/bsd/dhcpcd/dist/arp.c
 C src/external/bsd/dhcpcd/dist/dhcp.c
 U src/external/bsd/dhcpcd/dist/ipv4.c
 U src/external/bsd/dhcpcd/dist/ipv4ll.c
 U src/external/bsd/dhcpcd/dist/ipv6.c
 N src/external/bsd/dhcpcd/dist/ipv6nd.c
 U src/external/bsd/dhcpcd/dist/dhcp6.c
 C src/external/bsd/dhcpcd/dist/dhcpcd.conf
 U src/external/bsd/dhcpcd/dist/dhcpcd-run-hooks.8.in
 U src/external/bsd/dhcpcd/dist/dhcpcd-run-hooks.in
 C src/external/bsd/dhcpcd/dist/dhcpcd.8.in
 C src/external/bsd/dhcpcd/dist/dhcpcd.conf.5.in
 U src/external/bsd/dhcpcd/dist/arp.h
 U src/external/bsd/dhcpcd/dist/bpf-filter.h
 U src/external/bsd/dhcpcd/dist/common.h
 U src/external/bsd/dhcpcd/dist/config.h
 U src/external/bsd/dhcpcd/dist/control.h
 U src/external/bsd/dhcpcd/dist/defs.h
 N src/external/bsd/dhcpcd/dist/dev.h
 U src/external/bsd/dhcpcd/dist/dhcp-common.h
 U src/external/bsd/dhcpcd/dist/dhcp.h
 U src/external/bsd/dhcpcd/dist/dhcp6.h
 U src/external/bsd/dhcpcd/dist/dhcpcd.h
 U src/external/bsd/dhcpcd/dist/duid.h
 U src/external/bsd/dhcpcd/dist/eloop.h
 U src/external/bsd/dhcpcd/dist/if-options.h
 U src/external/bsd/dhcpcd/dist/if-pref.h
 U src/external/bsd/dhcpcd/dist/ipv4.h
 U src/external/bsd/dhcpcd/dist/ipv4ll.h
 U src/external/bsd/dhcpcd/dist/ipv6.h
 N src/external/bsd/dhcpcd/dist/ipv6nd.h
 U src/external/bsd/dhcpcd/dist/net.h
 U src/external/bsd/dhcpcd/dist/platform.h
 U src/external/bsd/dhcpcd/dist/script.h
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/01-test
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/02-dump
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/10-mtu
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/10-wpa_supplicant
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/15-timezone
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/20-resolv.conf
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/29-lookup-hostname
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/30-hostname
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/50-ntp.conf
 U src/external/bsd/dhcpcd/dist/dhcpcd-hooks/50-ypbind

 5 conflicts created by this import.
 Use the following command to help the merge:

 	cvs checkout -jroy:yesterday -jroy src/external/bsd/dhcpcd/dist

State-Changed-From-To: open->closed
State-Changed-By: roy@NetBSD.org
State-Changed-When: Sat, 05 Oct 2013 11:37:06 +0000
State-Changed-Why:
Fixed


From: Andreas Gustafsson <gson@gson.org>
To: roy@NetBSD.org
Cc: gnats-bugs@NetBSD.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 2 Aug 2014 10:09:34 +0300

 Hi Roy,

 The problem of bin/48140 has reappeared: dhcpcd again fails
 to get a lease unless you manually do an "ifconfig up" first.
 The output when failing is:

   dhcpcd[469]: version 6.4.2 starting
   dhcpcd[469]: ne2: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[469]: no interfaces have a carrier
   dhcpcd[469]: forked to background, child pid 527

 Using an automated binary search, I have determined that the
 last working version was CVS date 2014.07.14.11.36.39, and the
 first broken one was 2014.07.14.14.07.02; this is when 
 dhcpcd-6.4.1 was imported.

 This was tested using qemu 2.0.0nb4.  I have not tried a physical
 machine.
 -- 
 Andreas Gustafsson, gson@gson.org

State-Changed-From-To: closed->open
State-Changed-By: gson@NetBSD.org
State-Changed-When: Sat, 02 Aug 2014 07:10:44 +0000
State-Changed-Why:
Problem has reappeared.


From: Roy Marples <roy@marples.name>
To: Andreas Gustafsson <gson@gson.org>
Cc: roy@netbsd.org, gnats-bugs@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 02 Aug 2014 11:09:18 +0100

 Hi Andreas

 On 2014-08-02 08:09, Andreas Gustafsson wrote:
 > The problem of bin/48140 has reappeared: dhcpcd again fails
 > to get a lease unless you manually do an "ifconfig up" first.
 > The output when failing is:
 > 
 >   dhcpcd[469]: version 6.4.2 starting
 >   dhcpcd[469]: ne2: adding address fe80::59c1:f175:aeb3:433
 >   dhcpcd[469]: no interfaces have a carrier
 >   dhcpcd[469]: forked to background, child pid 527
 > 
 > Using an automated binary search, I have determined that the
 > last working version was CVS date 2014.07.14.11.36.39, and the
 > first broken one was 2014.07.14.14.07.02; this is when
 > dhcpcd-6.4.1 was imported.
 > 
 > This was tested using qemu 2.0.0nb4.  I have not tried a physical
 > machine.

 Ca you test dhcpcd-6.4.3 which was imported a few days ago please?

 Thanks

 Roy

From: Andreas Gustafsson <gson@gson.org>
To: Roy Marples <roy@marples.name>
Cc: roy@netbsd.org, gnats-bugs@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 2 Aug 2014 15:48:44 +0300

 Roy Marples wrote:
 > Ca you test dhcpcd-6.4.3 which was imported a few days ago please?

 I retested using sources from CVS date 2014.08.02.07.20.08, and it
 worked.  Thank you!
 -- 
 Andreas Gustafsson, gson@gson.org

State-Changed-From-To: open->closed
State-Changed-By: gson@NetBSD.org
State-Changed-When: Sat, 02 Aug 2014 12:52:15 +0000
State-Changed-Why:
Problem has been fixed again.


From: Andreas Gustafsson <gson@gson.org>
To: Roy Marples <roy@marples.name>
Cc: roy@netbsd.org, gnats-bugs@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Fri, 10 Oct 2014 13:24:31 +0300

 Hi Roy,

 Since the latest dhcpcd import, I'm once again having problems getting
 a DHCP lease in a qemu VM.

 Console output before the import, source date 2014.10.06.14.42.08:

   dhcpcd[1607]: version 6.4.7 starting
   dhcpcd[1607]: ne2: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1607]: DUID 00:01:00:01:1b:c9:c2:59:52:54:00:12:34:56
   dhcpcd[1607]: ne2: IAID 00:12:34:56
   dhcpcd[1607]: ne2: soliciting a DHCP lease
   dhcpcd[1607]: ne2: offered 10.0.2.15 from 10.0.2.2
   dhcpcd[1607]: ne2: soliciting an IPv6 router
   dhcpcd[1607]: ne2: leased 10.0.2.15 for 86400 seconds
   dhcpcd[1607]: ne2: adding host route to 10.0.2.15 via 127.0.0.1
   dhcpcd[1607]: ne2: adding route to 10.0.2.0/24
   dhcpcd[1607]: ne2: adding default route via 10.0.2.2
   dhcpcd[1607]: forked to background, child pid 1747

 Console output after the import, source date 2014.10.06.18.30.24:

   dhcpcd[1571]: version 6.5.0 starting
   dhcpcd[1571]: ne2: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1571]: timed out
   Oct  9 20:55:16  dhcpcd[1571]: timed out
   dhcpcd[1571]: allowing 8 seconds for IPv4LL timeout
   dhcpcd[1571]: timed out
   dhcpcd[1571]: forked to background, child pid 1305

 This is NetBSD-current/i386 is under qemu-2.0.0nb4 from pkgsrc,
 with qemu command line options --net user --net nic,model=ne2k_pci.

 Regards,
 -- 
 Andreas Gustafsson, gson@gson.org

State-Changed-From-To: closed->open
State-Changed-By: gson@NetBSD.org
State-Changed-When: Fri, 10 Oct 2014 10:26:41 +0000
State-Changed-Why:
It's failing again.


From: Roy Marples <roy@marples.name>
To: Andreas Gustafsson <gson@gson.org>
Cc: gnats-bugs@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 11 Oct 2014 16:39:51 +0100

 Hi Andreas

 On 2014-10-10 11:24, Andreas Gustafsson wrote:
 > Since the latest dhcpcd import, I'm once again having problems getting
 > a DHCP lease in a qemu VM.
 > 
 > Console output before the import, source date 2014.10.06.14.42.08:
 > 
 >   dhcpcd[1607]: version 6.4.7 starting
 >   dhcpcd[1607]: ne2: adding address fe80::59c1:f175:aeb3:433
 >   dhcpcd[1607]: DUID 00:01:00:01:1b:c9:c2:59:52:54:00:12:34:56
 >   dhcpcd[1607]: ne2: IAID 00:12:34:56
 >   dhcpcd[1607]: ne2: soliciting a DHCP lease
 >   dhcpcd[1607]: ne2: offered 10.0.2.15 from 10.0.2.2
 >   dhcpcd[1607]: ne2: soliciting an IPv6 router
 >   dhcpcd[1607]: ne2: leased 10.0.2.15 for 86400 seconds
 >   dhcpcd[1607]: ne2: adding host route to 10.0.2.15 via 127.0.0.1
 >   dhcpcd[1607]: ne2: adding route to 10.0.2.0/24
 >   dhcpcd[1607]: ne2: adding default route via 10.0.2.2
 >   dhcpcd[1607]: forked to background, child pid 1747
 > 
 > Console output after the import, source date 2014.10.06.18.30.24:
 > 
 >   dhcpcd[1571]: version 6.5.0 starting
 >   dhcpcd[1571]: ne2: adding address fe80::59c1:f175:aeb3:433
 >   dhcpcd[1571]: timed out
 >   Oct  9 20:55:16  dhcpcd[1571]: timed out
 >   dhcpcd[1571]: allowing 8 seconds for IPv4LL timeout
 >   dhcpcd[1571]: timed out
 >   dhcpcd[1571]: forked to background, child pid 1305
 > 
 > This is NetBSD-current/i386 is under qemu-2.0.0nb4 from pkgsrc,
 > with qemu command line options --net user --net nic,model=ne2k_pci.

 Are you sure it's dhcpcd at fault here?
 Also, did you trim some lines as theres clue what it's waiting on - try 
 adding the -d flag for more information.
 I'm running exactly what was imported on FreeBSD and OpenBSD qemu images 
 just fine *, and of course on the NetBSD host as well. All i386.
 For reference my qemu is at version 2.1.0 from pkgsrc and I did not 
 specify a nic model type.

 Roy

 * fine here means it gets a DHCP lease, there are other issues on other 
 BSD's I'm working on fixing

From: Andreas Gustafsson <gson@gson.org>
To: Roy Marples <roy@marples.name>
Cc: gnats-bugs@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 11 Oct 2014 19:33:06 +0300

 Roy Marples wrote:
 > Are you sure it's dhcpcd at fault here?

 I'm not saying dhcpcd is necessarily at fault - it could be that the
 new dhcpcd version just exposed a bug somewhere else - but I am sure
 that the problem appeared with the recent 6.5.0 import.  I noticed it
 by running the same automated test I had used to bisect the two
 earlier failures in this PR against the current sources.  I have since
 run the same test multiple times against both the pre- and post-import
 sources, and the results are consistent.

 > Also, did you trim some lines as theres clue what it's waiting on

 I did not trim any of the dhcpcd output.

 > - try adding the -d flag for more information.

 Done.  Before the import:

   dhcpcd[1294]: version 6.4.7 starting
   dhcpcd[1294]: ne2: disabling Kernel IPv6 auto link-local support
   dhcpcd[1294]: ne2: disabling Kernel IPv6 RA support
   dhcpcd[1294]: ne2: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1294]: ne2: vltime infinity, pltime infinity
   dhcpcd[1294]: ne2: executing `/libexec/dhcpcd-run-hooks' PREINIT
   dhcpcd[1294]: DUID 00:01:00:01:1b:cc:13:9a:52:54:00:12:34:56
   dhcpcd[1294]: ne2: IAID 00:12:34:56
   dhcpcd[1294]: ne2: delaying IPv6 router solictation for 1.0 seconds
   dhcpcd[1294]: ne2: delaying IPv4 for 0.5 seconds
   dhcpcd[1294]: ne2: soliciting a DHCP lease
   dhcpcd[1294]: ne2: sending DISCOVER (xid 0xd7cefa51), next in 4.6 seconds
   dhcpcd[1294]: ne2: offered 10.0.2.15 from 10.0.2.2
   dhcpcd[1294]: ne2: sending REQUEST (xid 0xd7cefa51), next in 3.3 seconds
   dhcpcd[1294]: ne2: acknowledged 10.0.2.15 from 10.0.2.2
   dhcpcd[1294]: ne2: checking for 10.0.2.15
   dhcpcd[1294]: ne2: sending ARP probe (1 of 3), next in 1.6 seconds
   dhcpcd[1294]: ne2: soliciting an IPv6 router
   dhcpcd[1294]: ne2: sending Router Solicitation
   dhcpcd[1294]: ne2: sending ARP probe (2 of 3), next in 1.3 seconds
   dhcpcd[1294]: ne2: sending ARP probe (3 of 3), next in 2.0 seconds
   dhcpcd[1294]: ne2: sending Router Solicitation
   dhcpcd[1294]: ne2: leased 10.0.2.15 for 86400 seconds
   dhcpcd[1294]: ne2: renew in 43200 seconds, rebind in 75600 seconds
   dhcpcd[1294]: ne2: adding IP address 10.0.2.15/24
   dhcpcd[1294]: ne2: adding host route to 10.0.2.15 via 127.0.0.1
   dhcpcd[1294]: ne2: adding route to 10.0.2.0/24
   dhcpcd[1294]: ne2: adding default route via 10.0.2.2
   dhcpcd[1294]: ne2: writing lease `/var/db/dhcpcd-ne2.lease'
   dhcpcd[1294]: ne2: executing `/libexec/dhcpcd-run-hooks' BOUND
   dhcpcd[1294]: forking to background
   dhcpcd[1294]: forked to background, child pid 1749

 After the import:

   dhcpcd[1587]: version 6.5.0 starting
   dhcpcd[1587]: ne2: disabling Kernel IPv6 auto link-local support
   dhcpcd[1587]: ne2: disabling Kernel IPv6 RA support
   dhcpcd[1587]: ne2: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1587]: ne2: vltime infinity, pltime infinity
   dhcpcd[1587]: ne2: executing `/libexec/dhcpcd-run-hooks' PREINIT
   dhcpcd[1587]: timed out
   dhcpcd[1587]: allowing 8 seconds for IPv4LL timeout
   Oct 11 16:15:06  dhcpcd[1587]: timed out
   dhcpcd[1587]: timed out
   dhcpcd[1587]: forking to background
   dhcpcd[1587]: forked to background, child pid 1662

 > I'm running exactly what was imported on FreeBSD and OpenBSD qemu images 
 > just fine *, and of course on the NetBSD host as well. All i386.
 > For reference my qemu is at version 2.1.0 from pkgsrc and I did not 
 > specify a nic model type.

 It is also working for me on real hardware.
 -- 
 Andreas Gustafsson, gson@gson.org

From: Andreas Gustafsson <gson@gson.org>
To: gnats-bugs@NetBSD.org
Cc: roy@NetBSD.org,
    gnats-admin@netbsd.org,
    netbsd-bugs@netbsd.org,
    gson@gson.org (Andreas Gustafsson)
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 11 Oct 2014 19:57:15 +0300

 Roy,

 You wrote:
 >  For reference my qemu is at version 2.1.0 from pkgsrc and I did not 
 >  specify a nic model type.

 I'm using qemu 2.0.0nb4.  I just reran the tests without the --net
 user and --net nic,model=ne2k_pci options, and it still works with the
 NetBSD disk image built from pre-import sources and fails with the one
 built from post-import sources.  Here is the output, pre-import:

   dhcpcd[1597]: version 6.4.7 starting
   dhcpcd[1597]: wm0: disabling Kernel IPv6 auto link-local support
   dhcpcd[1597]: wm0: disabling Kernel IPv6 RA support
   dhcpcd[1597]: wm0: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1597]: if_addaddress6: No buffer space available
   dhcpcd[1597]: wm0: executing `/libexec/dhcpcd-run-hooks' PREINIT
   Oct 11 16:35:22  dhcpcd[1597]: if_addaddress6: No buffer space available
   dhcpcd[1597]: DUID 00:01:00:01:1b:cc:18:ce:52:54:00:12:34:56
   dhcpcd[1597]: wm0: IAID 00:12:34:56
   dhcpcd[1597]: wm0: delaying IPv6 router solictation for 0.1 seconds
   dhcpcd[1597]: wm0: delaying IPv4 for 0.2 seconds
   dhcpcd[1597]: wm0: soliciting an IPv6 router
   dhcpcd[1597]: wm0: delaying Router Solicitation for LL address
   dhcpcd[1597]: wm0: soliciting a DHCP lease
   dhcpcd[1597]: wm0: sending DISCOVER (xid 0xff84e467), next in 3.6 seconds
   dhcpcd[1597]: wm0: offered 10.0.2.15 from 10.0.2.2
   dhcpcd[1597]: wm0: sending REQUEST (xid 0xff84e467), next in 3.7 seconds
   dhcpcd[1597]: wm0: acknowledged 10.0.2.15 from 10.0.2.2
   dhcpcd[1597]: wm0: checking for 10.0.2.15
   dhcpcd[1597]: wm0: sending ARP probe (1 of 3), next in 1.7 seconds
   dhcpcd[1597]: wm0: sending ARP probe (2 of 3), next in 1.9 seconds
   dhcpcd[1597]: wm0: sending ARP probe (3 of 3), next in 2.0 seconds
   dhcpcd[1597]: wm0: leased 10.0.2.15 for 86400 seconds
   dhcpcd[1597]: wm0: renew in 43200 seconds, rebind in 75600 seconds
   dhcpcd[1597]: wm0: adding IP address 10.0.2.15/24
   dhcpcd[1597]: wm0: adding host route to 10.0.2.15 via 127.0.0.1
   dhcpcd[1597]: wm0: adding route to 10.0.2.0/24
   dhcpcd[1597]: wm0: adding default route via 10.0.2.2
   dhcpcd[1597]: wm0: writing lease `/var/db/dhcpcd-wm0.lease'
   dhcpcd[1597]: wm0: executing `/libexec/dhcpcd-run-hooks' BOUND
   dhcpcd[1597]: forking to background
   dhcpcd[1597]: forked to background, child pid 1743

 And post-import:

   dhcpcd[1605]: version 6.5.0 starting
   dhcpcd[1605]: wm0: disabling Kernel IPv6 auto link-local support
   dhcpcd[1605]: wm0: disabling Kernel IPv6 RA support
   dhcpcd[1605]: wm0: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1605]: if_addaddress6: No buffer space available
   Oct 11 16:36:31  dhcpcd[1605]: if_addaddress6: No buffer space available
   dhcpcd[1605]: wm0: executing `/libexec/dhcpcd-run-hooks' PREINIT
   dhcpcd[1605]: timed out
   Oct 11 16:37:06  dhcpcd[1605]: timed out
   dhcpcd[1605]: allowing 8 seconds for IPv4LL timeout
   dhcpcd[1605]: timed out
   dhcpcd[1605]: forking to background
   dhcpcd[1605]: forked to background, child pid 1209

 -- 
 Andreas Gustafsson, gson@gson.org

From: Andreas Gustafsson <gson@gson.org>
To: Roy Marples <roy@marples.name>
Cc: gnats-bugs@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -current)
Date: Sat, 11 Oct 2014 20:43:27 +0300

 Roy,

 > For reference my qemu is at version 2.1.0 from pkgsrc

 To eliminate one more difference between our environments, I have now
 updated my qemu to 2.1.0.  Since some of the earlier logs contained
 the message "No buffer space available", I also increased the memory
 size from 32M to 128M.

 Here is the output from the failing (post-import) version and the
 output from ifconfig, including the command lines as logged by
 "sh -x":

   + dhcpcd -d
   dhcpcd[1599]: version 6.5.0 starting
   dhcpcd[1599]: wm0: disabling Kernel IPv6 auto link-local support
   dhcpcd[1599]: wm0: disabling Kernel IPv6 RA support
   dhcpcd[1599]: wm0: adding address fe80::59c1:f175:aeb3:433
   dhcpcd[1599]: wm0: vltime infinity, pltime infinity
   dhcpcd[1599]: wm0: executing `/libexec/dhcpcd-run-hooks' PREINIT
   dhcpcd[1599]: timed out
   Oct 11 17:33:40  dhcpcd[1599]: timed out
   dhcpcd[1599]: allowing 8 seconds for IPv4LL timeout
   dhcpcd[1599]: timed out
   dhcpcd[1599]: forking to background
   dhcpcd[1599]: forked to background, child pid 1686
   + ifconfig wm0
   wm0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
 	  capabilities=2bf80<TSO4,IP4CSUM_Rx,IP4CSUM_Tx,TCP4CSUM_Rx>
 	  capabilities=2bf80<TCP4CSUM_Tx,UDP4CSUM_Rx,UDP4CSUM_Tx,TCP6CSUM_Tx>
 	  capabilities=2bf80<UDP6CSUM_Tx>
 	  enabled=0
 	  ec_capabilities=7<VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU>
 	  ec_enabled=0
 	  address: 52:54:00:12:34:56
 	  media: Ethernet autoselect (1000baseT full-duplex)
 	  status: active
 	  inet6 fe80::59c1:f175:aeb3:433%wm0 prefixlen 64 scopeid 0x1

 -- 
 Andreas Gustafsson, gson@gson.org

From: Andreas Gustafsson <gson@gson.org>
To: "roy@marples.name" <roy@marples.name>
Cc: gnats-bugs@NetBSD.org,
    roy@NetBSD.org,
    gnats-admin@netbsd.org,
    netbsd-bugs@netbsd.org,
    gson@gson.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur
 rent)
Date: Sat, 11 Oct 2014 20:31:49 +0300

 Roy,

 You wrote:
 > And can you post non working debug output please?

 I already did.
 -- 
 Andreas Gustafsson, gson@gson.org

From: Roy Marples <roy@marples.name>
To: Andreas Gustafsson <gson@gson.org>
Cc: gnats-bugs@netbsd.org, roy@netbsd.org
Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
Date: Sat, 18 Oct 2014 01:03:45 +0100

 I just imported dhcpcd-6.5.1 but forgot to reference this PR :/

 Anyway, it should fix the problem here, two other people have confirmed 
 it should.

 Roy

State-Changed-From-To: open->feedback
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sat, 18 Oct 2014 06:55:01 +0000
State-Changed-Why:
please try the new version


State-Changed-From-To: feedback->closed
State-Changed-By: gson@NetBSD.org
State-Changed-When: Sat, 18 Oct 2014 16:44:07 +0000
State-Changed-Why:
Confirmed fixed, thanks.


From: Justin Cormack <justin@specialbusservice.com>
To: gnats-bugs@netbsd.org
Cc: roy@netbsd.org, gnats-admin@netbsd.org, netbsd-bugs@netbsd.org, 
	Andreas Gustafsson <gson@gson.org>
Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
Date: Sun, 19 Oct 2014 09:32:22 +0100

 On Sat, Oct 18, 2014 at 1:05 AM, Roy Marples <roy@marples.name> wrote:
 > The following reply was made to PR bin/48140; it has been noted by GNATS.
 >
 > From: Roy Marples <roy@marples.name>
 > To: Andreas Gustafsson <gson@gson.org>
 > Cc: gnats-bugs@netbsd.org, roy@netbsd.org
 > Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
 > Date: Sat, 18 Oct 2014 01:03:45 +0100
 >
 >  I just imported dhcpcd-6.5.1 but forgot to reference this PR :/
 >
 >  Anyway, it should fix the problem here, two other people have confirmed
 >  it should.

 hmm, I just installed 201410181210Z amd64 snapshot on Xen and the
 installer still failed to get a dhcp lease. I reconfigured the machine
 to use dhcp after install and it works fine, so this is possibly a
 slightly different issue.

 Justin

From: Justin Cormack <justin@specialbusservice.com>
To: "roy@marples.name" <roy@marples.name>
Cc: gnats-bugs@netbsd.org, roy@netbsd.org, gnats-admin@netbsd.org, 
	netbsd-bugs@netbsd.org, Andreas Gustafsson <gson@gson.org>
Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
Date: Sun, 19 Oct 2014 23:11:48 +0100

 On Sun, Oct 19, 2014 at 11:22 AM, roy@marples.name <roy@marples.name> wrote:
 > Is the dhcpcd version the same in the installer as after install? Can you
 > say how the installer one failed?

 ok so they arent the same, the installer is
 dhcpcd 6.5.1
 Copyright (c) 2006-2014 Roy Marples
 while installed is
 isc-dhcpd-4.3.0

 (why?)

 During install it is getting an ipv6 address fine (if only
 nyftp.org.uk had ipv6 I would never have noticed lack of ipv4), which
 alas means the messages scroll a bit fast but seem to be:

 (the lack of printf on the installer may not be helping the messages).

 xennet0: executing `/libexec/dhcpcd-run-hooks' PREINIT
 printf: not found
 xennet0: executing `/libexec/dhcpcd-run-hooks' CARRIER
 printf: not found
 DUID 00:01:00:01:1b:XXXXXXXXXXXXXXXXXXX
 xennet0: IAID 31:52:23:e4
 xennet0: delaying IPv6 router solictation for 0.4 seconds
 xennet0: delaying IPv4 for 0.8 seconds
 xennet0: soliciting an IPv6 router
 xennet0: sending Router Solicitation
 dhcp_openudp: m (Can't assign requested address)
 xennet0: Router Advertisement from fe80::c001:88ff:fea9:e1f5
 xennet0: adding address 2a01:XXXXXXXXXXXXXXXXXXX/64
 xennet0: vltime 86400 seconds, pltime 14400 seconds
 xennet0: adding route to 2a01:XXXXXXXX/64
 xennet0: adding default route via fe80::c001:88ff:fea9:e1f5
 xennet0: executing `/libexec/dhcpcd-run-hooks' ROUTERADVERT
 printf: not found
 xennet0: No DHCPv6 instruction in RA


 xennet0: delaying IPv4 for 1.0 seconds
 xennet0: soliciting an IPv6 router
 xennet0: sending Router Solicitation
 dhcp_openudp: m (Can't assign requested address)
 xennet0: Router Advertisement from fe80::c001:88ff:fea9:e1f5
 xennet0: adding address 2a01:XXXXXXXXXXXXXXXXXXXXX/64
 xennet0: vltime 86400 seconds, pltime 14400 seconds
 xennet0: adding route to 2a01:XXXXXXXXXXX:/64
 xennet0: adding default route via fe80::c001:88ff:fea9:e1f5
 xennet0: waiting for Router Advertisement DAD to complete
 xennet0: No DHCPv6 instruction in RA
 xennet0: Router Advertisement DAD completed
 xennet0: executing `/libexec/dhcpcd-run-hooks' ROUTERADVERT
 printf: not found
 xennet0: Router Advertisement from fe80::c001:88ff:fea9:e1f5
 xennet0: adding address 2a01:XXXXXXXXXXXXXXXXX/64
 xennet0: vltime 86400 seconds, pltime 14400 seconds
 xennet0: executing `/libexec/dhcpcd-run-hooks' ROUTERADVERT
 printf: not found

From: John Nemeth <jnemeth@cue.bc.ca>
To: Justin Cormack <justin@specialbusservice.com>,
        "roy@marples.name" <roy@marples.name>
Cc: gnats-bugs@netbsd.org, roy@netbsd.org, gnats-admin@netbsd.org,
        netbsd-bugs@netbsd.org, Andreas Gustafsson <gson@gson.org>
Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
Date: Sun, 19 Oct 2014 16:16:23 -0700

 On Oct 19, 11:11pm, Justin Cormack wrote:
 } On Sun, Oct 19, 2014 at 11:22 AM, roy@marples.name <roy@marples.name> wrote:
 } > Is the dhcpcd version the same in the installer as after install? Can you
 } > say how the installer one failed?
 } 
 } ok so they arent the same, the installer is
 } dhcpcd 6.5.1
 } Copyright (c) 2006-2014 Roy Marples
 } while installed is
 } isc-dhcpd-4.3.0
 } 
 } (why?)

      Probably be because somebody isn't paying attention.  dhcpcd
 is not the same as dhcpd.  Actually, they are kind of opposites,
 dhcpcd is a DHCP client while dhcpd is a DHCP server.

      BTW, the only dhcpcd could be different during install and
 afterwards is if install dhcpcd from pkgsrc (or, deliberately update
 it in base).

 }-- End of excerpt from Justin Cormack

From: Justin Cormack <justin@specialbusservice.com>
To: gnats-bugs@netbsd.org
Cc: roy@netbsd.org, gnats-admin@netbsd.org, netbsd-bugs@netbsd.org, 
	Andreas Gustafsson <gson@gson.org>
Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
Date: Mon, 20 Oct 2014 00:25:37 +0100

 On Mon, Oct 20, 2014 at 12:15 AM, John Nemeth <jnemeth@cue.bc.ca> wrote:
 > The following reply was made to PR bin/48140; it has been noted by GNATS.
 >
 > From: John Nemeth <jnemeth@cue.bc.ca>
 > To: Justin Cormack <justin@specialbusservice.com>,
 >         "roy@marples.name" <roy@marples.name>
 > Cc: gnats-bugs@netbsd.org, roy@netbsd.org, gnats-admin@netbsd.org,
 >         netbsd-bugs@netbsd.org, Andreas Gustafsson <gson@gson.org>
 > Subject: Re: bin/48140 (dhcpcd fails to get lease in -cur rent)
 > Date: Sun, 19 Oct 2014 16:16:23 -0700
 >
 >  On Oct 19, 11:11pm, Justin Cormack wrote:
 >  } On Sun, Oct 19, 2014 at 11:22 AM, roy@marples.name <roy@marples.name> wrote:
 >  } > Is the dhcpcd version the same in the installer as after install? Can you
 >  } > say how the installer one failed?
 >  }
 >  } ok so they arent the same, the installer is
 >  } dhcpcd 6.5.1
 >  } Copyright (c) 2006-2014 Roy Marples
 >  } while installed is
 >  } isc-dhcpd-4.3.0
 >  }
 >  } (why?)
 >
 >       Probably be because somebody isn't paying attention.  dhcpcd
 >  is not the same as dhcpd.  Actually, they are kind of opposites,
 >  dhcpcd is a DHCP client while dhcpd is a DHCP server.

 Indeed, it is late here and trying to do too many things at once. They
 are of course the same version, dhcpcd 6.5.1.

 Justin

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.