CentOS 6.5 PXE一鍵安裝Linux作業系統

來源:互聯網
上載者:User

標籤:linux一鍵安裝   pxe   

#安裝配置DHCPyum -y install dhcpcp /usr/share/doc/dhcp-4.2.5/dhcpd.conf.example /etc/dhcp/dhcpd.confvim /etc/dhcp/dhcpd.conf        subnet 192.168.3.0 netmask 255.255.255.0 {  range 192.168.3.100 192.168.3.200;  option domain-name-servers server.example.com;  option domain-name "8.8.8.8";  option routers 192.168.3.1;  option broadcast-address 192.168.3.255;  next-server 192.168.3.100;  filename "pxelinux.0";  default-lease-time 60000;  max-lease-time 720000;}service dhcpd startchkconfig dhcpd on#配置xinetd伺服器yum -y install syslinux tftp-servervim /etc/xinetd.d/tftpdisable=noservice xinetd startchkconfig xinetd on#拷貝引導檔案cd /var/lib/tftpboot   cp /mnt/isolinux/* .cp /usr/share/syslinux/pxelinux.0 .mkdir pxelinux.cfgcd pxelinux.cfgcp /mnt/isolinux/isolinux.cfg ./default  vim default    label Install RHEL6.5   kernel vmlinuz  append initrd=initrd.img ks=nfs:192.168.3.100:/var/lib/tftpboot/ks.cfg   #配置NFS服務yum -y install nfs*    mkdir /rhel6mount /dev/cdrom /rhel6vim /etc/exports    /rhel6    192.168.3.0/24(rw,sync)service nfs startchkconfig nfs onyum -y install system-config-kickstgartsystem-config-kickstart#建立一鍵安裝指令碼#手動寫入指令碼#platform=x86, AMD64, or Intel EM64T#version=DEVEL# Firewall configurationfirewall --disabled# Install OS instead of upgradeinstall# Use NFS installation medianfs --server=192.168.3.100 --dir=/mnt# Root passwordrootpw --iscrypted $1$3X.jwnPp$90YJQkQsBqTdL4aPRsgKc/# System authorization informationauth  --useshadow  --passalgo=sha512# Use graphical installgraphicalfirstboot --disable# System keyboardkeyboard us# System languagelang en_US# SELinux configurationselinux --enforcing# Installation logging levellogging --level=info# Reboot after installationreboot# System timezonetimezone --isUtc Asia/Shanghai# Network informationnetwork  --bootproto=dhcp --device=eth0 --onboot=on# System bootloader configurationbootloader --location=mbr# Clear the Master Boot Recordzerombr# Partition clearing informationclearpart --all --initlabel# Disk partitioning informationpart /boot --fstype="ext4" --size=200part / --fstype="ext4" --grow --size=1%packages@basic-desktop@desktop-debugging@desktop-platform@fonts@general-desktop@graphical-admin-tools@input-methods@kde-desktop@legacy-x@remote-desktop-clients@x11%end


本文出自 “吳善強” 部落格,請務必保留此出處http://shanqiangwu.blog.51cto.com/8067564/1653988

CentOS 6.5 PXE一鍵安裝Linux作業系統

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.