mounting root from NFS via ROOTDEVNAME
    Ian Lepore 
    ian at FreeBSD.org
       
    Mon Jan 28 15:24:17 UTC 2013
    
    
  
On Mon, 2013-01-28 at 15:13 +0000, Eggert, Lars wrote:
> Hi,
> 
> I'm trying to netboot a system where the root device is specified in the kernel via ROOTDEVNAME:
> 
> options         BOOTP
> options         BOOTP_NFSROOT
> options         BOOTP_NFSV3
> options         BOOTP_COMPAT
> options         BOOTP_WIRED_TO=em4
> options         ROOTDEVNAME=\"nfs:10.11.12.13:/usr/home/elars/dst\"
> 
> I was under the assumption that specifying a ROOTDEVNAME in the kernel config would override the "root-path" option in DHCP, or at least take effect when "root-path" wasn't provided via DHCP, but that doesn't seem to be the case. The system configures it's address correctly over em4, but then enters a loop:
> 
> em4: link state changed to UP
> Received DHCP Offer packet on em4 from 0.0.0.0 (accepted) (no root path)
> Sending DHCP Request packet from interface em4 (XX:XX:XX:XX:XX:XX)
> Received DHCP Ack packet on em4 from 0.0.0.0 (accepted) (no root path)
> Received DHCP Ack packet on em4 from 0.0.0.0 (accepted) (no root path)
> DHCP/BOOTP timeout for server 255.255.255.255
> Received DHCP Ack packet on em4 from 0.0.0.0 (accepted) (no root path)
> DHCP/BOOTP timeout for server 255.255.255.255
> ...
> 
> If I hand out a root path via DHCP the system boots fine, but the idea here is to be able to boot different root devices without needing to diddle dhcpd.conf. Can this be done?
Remove the BOOTP_NFSROOT option, it tells the bootp/dhcp code to keep
querying the server until a root path is delivered.  Without it, the
ROOTDEVNAME option should get used (and I think even override a path
from the server, if it delivers one).
-- Ian
    
    
More information about the freebsd-current
mailing list