1009 通过网络无人值守安装 Linux
作者 佚名技术
来源 Linux系统
浏览
发布时间 2012-04-30
通过网络无人值守安装 Linux
Boot Server (dhcp,tftp) Installation Server (nfs)
------------------------------------------------------------------------------------------------------ mount -t cifs //192.168.50.8/ISOS /mnt -o username=''user'',passwd=''123'' mkdir -p /data/rhel5u2 cp /mnt/CentOS-5.2-i386-bin-DVD.iso /data/rhel5u2/ yum install -y dhcp tftp-server nfs-utils yum install -y syslinux cp /usr/lib/syslinux/pxelinux.0 /tftpboot/ ------------------------------------------------------------------------------------------------------ dhcp配置: vim /etc/dhcpd.conf ddns-update-style interim; ignore client-updates; filename "pxelinux.0"; subnet 172.16.0.0 netmask 255.255.0.0 { option domain-name "domain.org"; option domain-name-servers 172.16.0.1; range dynamic-bootp 172.16.0.128 172.16.0.254; default-lease-time 21600; max-lease-time 43200; } service httpd start ------------------------------------------------------------------------------------------------------ tftp配置: vim /etc/xinetd.d/tftp service tftp { socket_type = dgram protocol = udp wait = yes user = root server = /usr/sbin/in.tftpd server_args = -s /tftpboot disable = no per_source = 11 cps = 100 2 flags = IPv4 } service xinetd start mount -t iso9660 -o loop,ro /data/rhel5u2/CentOS-5.2-i386-bin-DVD.iso /mnt cp /mnt/isolinux/initrd.img /tftpboot/initrd-rhel5u2-i386.img cp /mnt/isolinux/vmlinuz /tftpboot/vmlinuz-rhel5u2-i386
cp /mnt/isolinux/isolinux.cfg /tftpboot/pxelinux.cfg/default vim /tftpboot/pxelinux.cfg/default default rhel5u2-i386 prompt 1 timeout 10 display pxelinux.cfg/list label rhel5u2-i386 kernel vmlinuz-rhel5u2-i386 append ks=nfs:172.16.0.1:/data/rhel5u2/ks.cfg initrd=initrd-rhel5u2-i386.img text label vmlinuz-rhel5-x86_64 kernel vmlinuz-rhel5-x86_64 append initrd=initrd-rhel5-x86_64.img text vim /tftpboot/pxelinux.cfg/list Choose one of the following Linux distributions for your installation: Name Distribution Arch. Installation media ------------------------------------------------------------------------- rhel5u2-i386 RHEL 5 AS U2 i386 192.168.138.1:/data/rhel5u2 rhel5-x86_64 RHEL 5 AS x86_64 192.168.138.1:/data/rhel5 ------------------------------------------------------------------------------------------------------ nfs配置: vim /etc/exports /data 172.16.0.0/24(ro,no_root_squash,sync) service portmap start service nfs start showmount -e localhost ------------------------------------------------------------------------------------------------------ kickstart配置: cp /root/anaconda-ks.cfg /data/rhel5u2/ks.cfg vim /data/rhel5u2/ks.cfg install nfs --server=172.16.0.1 --dir=/data/rhel5u2 lang en_US.UTF-8 keyboard us network --device eth0 --bootproto dhcp rootpw --iscry |
|
凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢! |
你可能对下面的文章感兴趣
关于1009 通过网络无人值守安装 Linux的所有评论