You need to create a file in /tftpboot to describe the DISKLESS node. It should be named cfg.{DOMAIN_ADDR}.{CLIENT_ADDR}, and would look like this:
rootfs {DOMAIN_ADDR}.{HOST_ADDR}:/usr/rootfs/{CLIENT_NAME} swapfs {DOMAIN_ADDR}.{HOST_ADDR}:/usr/swapfs swapsize {SWAP_FILE_SIZE} hostname {CLIENT_NAME}.{DOMAIN_NAME}
Once placed into /tftpboot, change its permissions:
# chmod 644 /tftpboot/cfg.{DOMAIN_ADDR}.{CLIENT_ADDR}
Each DISKLESS node must have an entry added to the end of /etc/bootptab. Note that it adds onto the information already defined in the default section:
{CLIENT_NAME}:\ :tc=.default:\ :ha={ETHERNET_ADDR}:\ :ip={DOMAIN_ADDR}.{CLIENT_ADDR}:
The file /etc/exports is edited to allow the DISKLESS node to NFS mount HOST:
/usr -maproot=0:0 -alldirs {CLIENT_NAME}
Once this has been done you need to inform the mountd daemon to reread /etc/exports:
# ps -ax | grep mountd # kill -HUP {MOUNTD_PID}
A SWAP file must be created for the node:
# dd if=/dev/zero of=/usr/swapfs/swap.{DOMAIN_ADDR}.{CLIENT_ADDR} bs=1024 count={SWAP_FILE_SIZE} # chmod 600 /usr/swapfs/swap.{DOMAIN_ADDR}.{CLIENT_ADDR}
A home must be created for this DISKLESS node:
# mkdir /usr/rootfs/{CLIENT_NAME} # chmod 755 /usr/rootfs/{CLIENT_NAME}
Several needed directories are created:
# cd /usr/rootfs/{CLIENT_NAME} # mkdir mnt proc tmp usr # chown bin:bin tmp # chmod 1777 tmp # chmod 555 proc
You might need to build a unique kernel for a specific machine, but most often you can just make a link to the common kernel:
# chflags noschg ../common/kernel # ln ../common/kernel kernel # chflags schg ../common/kernel
Finally, you need to link to the common files:
# cd /usr/rootfs/common # find bin lkm sbin stand | cpio -pvdlm /usr/rootfs/{CLIENT_NAME}
Create a tree of unique files used by this DISKLESS node:
# cd / # cp COPYRIGHT .cshrc .profile /usr/rootfs/{CLIENT_NAME} # find dev etc root var | cpio -pvdm /usr/rootfs/{CLIENT_NAME} # chmod 755 /usr/rootfs/{CLIENT_NAME}/dev
Several files must be cleaned up in /usr/rootfs/{CLIENT_NAME}/etc:
# cd /usr/rootfs/{CLIENT_NAME}/etc # rm exports fstab
The new /usr/rootfs/{CLIENT_NAME}/etc/fstab should have the following contents:
{HOST_NAME}:/usr/rootfs/{CLIENT_NAME} / nfs rw 0 0 {HOST_NAME}:/usr /usr nfs rw 0 0
Change its permissions:
# chmod 644 /usr/rootfs/{CLIENT_NAME}/etc/fstab
The file /usr/rootfs/{CLIENT_NAME}/etc/rc must be patched to change the point at which the kernel mounts its NFS partition(s). /usr/rootfs/{CLIENT_NAME}/etc/sysconfig must also be patched