|
Thanks Dave for taking an interest. I am wondering what is populating the SI_DHCP_CACHE value in the kernel cache (that is the one that sysinfo in dhcpagent/dhcp_adopt() is asking for) Do you know? For Sparc this seems to be populated from the netdev-path eeprom variable, but for x64 there is no such thing (I am using x64 nevada b159 here, but had the same problems with other builds, e.g. b151a, too). As far as I found this is where SI_DHCP_CACHE is populated in the kernel? http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/uts/common/os/swapgeneric.c 461 /* 462 * Fetch the "netdev-path" boot property (if it exists), and 463 * stash it for later use by sysinfo(SI_DHCP_CACHE, ...). 464 */ 465 proplen = BOP_GETPROPLEN(bootops, "netdev-path"); 466 if (proplen > 0) { 467 netdev_path = kmem_zalloc(proplen, KM_SLEEP); 468 if (BOP_GETPROP(bootops, "netdev-path", 469 (uchar_t *)netdev_path) == -1) { 470 cmn_err(CE_WARN, "BOP_GETPROP of " 471 "\"netdev-path\" failed\n"); 472 kmem_free(netdev_path, proplen); 473 goto out; 474 } 475 } I am not very good with all the kernel source code. If you have any insight how this is supposed to work that would be super. Right now, I am wondering if this is even a bug. There are not that many people doing diskless netboots that rely on "dhcpagent -a" to hold the network address it seems. On my sparc miniroot this all works fine, but on my x64 miniroot the "dhcpagent -a" run (from /lib/svc/method/net-physical) will *try* to adopt the interface (for 15 seconds or so) and then just die - with an exit status of 0!!! Running dhcpagent without the -a flag will work though and this is my workaround for now. Note however, that the net-physical SMF service will only start it with the -a flag, so this is unrealiable. And because of the clean 0 exit status SMF won't pick it up as a failure either, I guess. [email protected]:/etc/dhcp# /sbin/dhcpagent -a Mar 15 04:00:58 192.168.4.107 /sbin/dhcpagent[1237]: dhcp_adopt: cannot fetch kernel cache <15 or so seconds later> [email protected]:/etc/dhcp# echo $? 0 <--- NOTE the 0 exit status even though it failed [email protected]:/etc/dhcp# ps -ef | grep dhcpagent | grep -v grep [email protected]:/etc/dhcp# /sbin/dhcpagent [email protected]:/etc/dhcp# ps -ef | grep dhcpagent | grep -v grep root 1248 1 0 04:05:28 ? 0:00 /sbin/dhcpagent I think I would already be happy if somebody could confirm that in a recent nevada build the "dhcpagent -a" does REALLY work with a netboot for them and not just die with this 0 exit status like it does for me. At least then I would know for sure the problem has to do somewhat with my customizations. I appreciate any insight you might have - or even if you can point me to an engineer who works the dhcpagent side of the kernel source Thanks so much for replying at all, --Marcus Dave Miner wrote on 03/14/11 19:59: On 03/11/11 10:18 AM, Marcus Heine wrote: |
_______________________________________________ caiman-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

