On Thu, May 14, 2020 at 11:19:04AM +0200, Andreas Kusalananda Kähäri wrote: > On Thu, May 14, 2020 at 10:43:56AM +0200, Kusalananda Kähäri wrote: > > >Synopsis: em0 does not get address from DHCP server in time > > >Category: system amd64 > > >Environment: > > System : OpenBSD 6.7 > > Details : OpenBSD 6.7-current (GENERIC.MP) #186: Thu May 14 > > 00:13:53 MDT 2020 > > > > dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP > > > > Architecture: OpenBSD.amd64 > > Machine : amd64 > > >Description: > > > > In recent snapshots, it seems that em0 sometimes does not get a link > > and/or IP address from the DHCP server quick enough and the interface > > is left without a proper IP address. This has the knock-on effect that > > ntpd does not start properly, and, since it happened to the OpenBSD > > machine running my local unbound, my home network was left without being > > able to resolve local names, mount NFS shares, etc.
Hi Andreas, More of a comment than a solution but it might still improve your case or provide you with a better workaround. To me that doesn't sounds like a matter of how quickly em0 get his IP from the DHCP server. It looks like the time it takes to get its status "active". Typically on my system an 'ifconfig em0 up' will take ~23s to get active, but less than ~3s if I just specify the media type and opts. To see your supported media type: # ifconfig em0 media You could then specify the media type in your /etc/hostname.em0 dhcp options options being something like : media 100baseTX mediaopt full-duplex This is well documented in hostname.if(5) and ifconfig(8). Hope this help. Cheers, -- clematis (0xA2C87EDB507B4C53)