Diskless Client2011/05/14 |
Boot your client computer that has no local drive from PXE server.
Set Basic PXE Configuration first.
|
|
[1] | Install required package |
[root@pxe ~]# yum -y install dracut-network
|
[2] | Install a system for Diskless Client on PXE server. This example shows to install "Base" and "Server Platform", but Install others if you need. If an error is shown with yum, replace a word "$releasever" to a version number in repository file uder /etc/yum.repos.d directory. |
[root@pxe ~]#
[root@pxe ~]# yum -y groupinstall "Base" "Server Platform" --installroot=/var/lib/tftpboot/sl6/root/ cp -f -R /root /var/lib/tftpboot/sl6/root/ [root@pxe ~]# chmod 600 /var/lib/tftpboot/sl6/root/etc/shadow [root@pxe ~]# $6$xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
[root@pxe ~]#
vi /var/lib/tftpboot/sl6/root/etc/shadow # set root password root:
$6$xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx :14937:0:99999:7:::
[root@pxe ~]#
vi /var/lib/tftpboot/sl6/root/etc/fstab none /tmp tmpfs defaults 0 0 tmpfs /dev/shm tmpfs defaults 0 0 sysfs /sys sysfs defaults 0 0 proc /proc proc defaults 0 0 [root@pxe ~]# cp /boot/vmlinuz-2.6.32-71.el6.x86_64 /var/lib/tftpboot/sl6/ [root@pxe ~]# dracut initramfs-2.6.32-71.el6.x86_64.img 2.6.32-71.el6.x86_64 [root@pxe ~]# mv initramfs-2.6.32-71.el6.x86_64.img /var/lib/tftpboot/sl6/
[root@pxe ~]#
vi /var/lib/tftpboot/pxelinux.cfg/default # create new default sl6 label sl6 kernel sl6/vmlinuz-2.6.32-71.el6.x86_64 append initrd=sl6/initramfs-2.6.32-71.el6.x86_64.img root=nfs:10.0.0.50:/var/lib/tftpboot/sl6/root rw selinux=0 |
[3] | Start NFS server in order to share files on the network that are copied above. |
[root@pxe ~]#
vi /etc/exports
/var/lib/tftpboot/sl6/root 10.0.0.0/24(rw,sync,no_root_squash,no_all_squash) /etc/rc.d/init.d/rpcbind start Starting rpcbind: [ OK ] [root@pxe ~]# /etc/rc.d/init.d/nfslock start Starting NFS statd: [ OK ] [root@pxe ~]# /etc/rc.d/init.d/nfs start RPC: Registered udp transport module. RPC: Registered tcp transport module. RPC: Registered tcp NFSv4.1 backchannel transport module. Installing knfsd (copyright (C) 1996 okir@monad.swb.de). Starting NFS services: [ OK ] Starting NFS daemon: NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory NFSD: starting 90-second grace period [ OK ] Starting NFS mountd: [ OK ] Starting RPC idmapd: [ OK ] |
[4] | PXE Server's configuration completed. Start your Diskless Client Computer with first boot priority is network, then boot from network like follows. |
Sponsored Link |
|