Lookupip() was already reading rootpath, but it didn't read the address of the swap server (called rootserver in some systems). As they are very related it makes sense to read them at the same time.
This patch also fixes a typo, where vendorclass was used instead of vendor, resulting that vendor ndb attribute was never used. diff -r b1cb12e81f18 sys/src/cmd/ip/dhcpd/ndb.c --- a/sys/src/cmd/ip/dhcpd/ndb.c Sun Jan 20 12:55:31 2019 +0100 +++ b/sys/src/cmd/ip/dhcpd/ndb.c Tue Jan 22 18:50:26 2019 +0000 @@ -116,10 +116,11 @@ *p++ = "@tftp2"; *p++ = "rootpath"; *p++ = "dhcp"; - *p++ = "vendorclass"; + *p++ = "vendor"; *p++ = "dom"; *p++ = "@fs"; *p++ = "@auth"; + *p++ = "@swap"; } if(hwattr != nil) *p++ = hwattr; @@ -153,6 +154,9 @@ if(strcmp(nt->attr, "ipgw") == 0) setipaddr(iip->gwip, nt->val); else + if(strcmp(nt->attr, "swap") == 0) + setipaddr(iip->swapip, nt->val); + else if(strcmp(nt->attr, "dhcp") == 0){ if(iip->dhcpgroup[0] == 0) strncpy(iip->dhcpgroup, nt->val, sizeof(iip->dhcpgroup)-1);