博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
6、PXE安装ESXI6.0
阅读量:5814 次
发布时间:2019-06-18

本文共 3642 字,大约阅读时间需要 12 分钟。

1、安装PXE环境涉及软件

yum -y install dhcp* httpd tftp-server*

2、配置DHCP

vim /etc/dhcp/dhcpd.conf 

allow booting;

allow bootp;

ignore client-updates;

option routers 192.168.130.229;

option subnet-mask 255.255.255.0;

subnet 192.168.130.0 netmask 255.255.255.0{

        range 192.168.130.10 192.168.130.20;

        next-server 192.168.130.229;

        filename "gpxelinux.0";

}

vim /etc/rc.d/init.d/dhcpd

将user=dhcpd、group=dhcpd改为user=root、group=root

chkconfig dhcpd on

service dhcpd start

3、配置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 /var/lib/tftpboot

        disable                 = no

        per_source              = 11

        cps                     = 100 2

        flags                   = IPv4

}

chkconfig xinetd on

service xinetd start

4、配置HTTP

chkconfig httpd on

service httpd start

5、配置引导文件

yum -y install syslinux

cp /usr/share/syslinux/gpxelinux.0 /var/lib/tftpboot/

6、配置选项菜单

vim /var/lib/tftpboot/boot.msg

#########################################################

1 esxi6.0

#########################################################

7、配置default文件

mkdir /var/lib/tftpboot/pxelinux.cfg

vim /var/lib/tftpboot/pxelinux.cfg/default

default 1

prompt 1

timeout 60

display boot.msg

label 1

  kernel http://192.168.130.229/iso/esxi6.0/mboot.c32

  append -c http://192.168.130.229/iso/esxi6.0/boot.cfg ks=http://192.168.130.229/ks/esxi6.0/ks.cfg

8、拷贝镜像并做相应修改

mkdir -p /var/www/html/ks/esxi6.0 /var/www/html/iso/esxi6.0

mount /dev/cdrom /mnt

cp -r /mnt/* /var/www/html/iso/esxi6.0

将所有的/删除,并添加prefix=http://192.168.130.229/iso/esxi6.0

vim /var/lib/tftpboot/esxi6.0/boot.cfg

bootstate=0

title=Loading ESXi installer

timeout=5

prefix=http://192.168.130.229/iso/esxi6.0

kernel=tboot.b00

kernelopt=runweasel

modules=b.b00 --- jumpstrt.gz --- useropts.gz --- k.b00 --- chardevs.b00 --- a.b00 --- user.b00 --- uc_intel.

b00 --- uc_amd.b00 --- sb.v00 --- s.v00 --- mtip32xx.v00 --- ata_pata.v00 --- ata_pata.v01 --- ata_pata.v02 -

-- ata_pata.v03 --- ata_pata.v04 --- ata_pata.v05 --- ata_pata.v06 --- ata_pata.v07 --- block_cc.v00 --- ehci

_ehc.v00 --- elxnet.v00 --- emulex_e.v00 --- weaselin.t00 --- esx_dvfi.v00 --- ima_qla4.v00 --- ipmi_ipm.v00 

--- ipmi_ipm.v01 --- ipmi_ipm.v02 --- lpfc.v00 --- lsi_mr3.v00 --- lsi_msgp.v00 --- lsu_hp_h.v00 --- lsu_lsi_

.v00 --- lsu_lsi_.v01 --- lsu_lsi_.v02 --- lsu_lsi_.v03 --- lsu_lsi_.v04 --- misc_cni.v00 --- misc_dri.v00 --

- net_bnx2.v00 --- net_bnx2.v01 --- net_cnic.v00 --- net_e100.v00 --- net_e100.v01 --- net_enic.v00 --- net_f

orc.v00 --- net_igb.v00 --- net_ixgb.v00 --- net_mlx4.v00 --- net_mlx4.v01 --- net_nx_n.v00 --- net_tg3.v00 -

-- net_vmxn.v00 --- nmlx4_co.v00 --- nmlx4_en.v00 --- nmlx4_rd.v00 --- nvme.v00 --- ohci_usb.v00 --- qlnative

.v00 --- rste.v00 --- sata_ahc.v00 --- sata_ata.v00 --- sata_sat.v00 --- sata_sat.v01 --- sata_sat.v02 --- sa

ta_sat.v03 --- sata_sat.v04 --- scsi_aac.v00 --- scsi_adp.v00 --- scsi_aic.v00 --- scsi_bnx.v00 --- scsi_bnx.

v01 --- scsi_fni.v00 --- scsi_hps.v00 --- scsi_ips.v00 --- scsi_meg.v00 --- scsi_meg.v01 --- scsi_meg.v02 ---

 scsi_mpt.v00 --- scsi_mpt.v01 --- scsi_mpt.v02 --- scsi_qla.v00 --- uhci_usb.v00 --- xhci_xhc.v00 --- tools.

t00 --- xorg.v00 --- imgdb.tgz --- imgpayld.tgz

build=

updated=0

9、配置KS文件

vim /var/www/html/ks/esxi6.0/ks.cfg 

#Accept the vmware End User License Agreement

accepteula

# Set the root password for the DCUI and Tech Support Mode

rootpw Test@2017

clearpart --firstdisk=local --overwritevmfs

#Part disk

install --firstdisk=local  --overwritevmfs

#Set the network to DHCP IP on the first network adapater

network --bootproto=dhcp --device=vmnic0

#Final reboot

reboot

      本文转自开源殿堂 51CTO博客,原文链接:http://blog.51cto.com/kaiyuandiantang/1953979,如需转载请自行联系原作者
你可能感兴趣的文章
ckeditor 键盘事件绑定
查看>>
Android的Aidl安装方法
查看>>
Linux中rc的含义
查看>>
NFS详解
查看>>
Linux gpm下console中使用鼠标
查看>>
曾鸣:区块链的春天还没有到来| 阿里内部干货
查看>>
如何通过Dataworks禁止MaxCompute 子账号跨Project访问
查看>>
js之无缝滚动
查看>>
17位女性科学家带你预测2017和2027
查看>>
Django 多表联合查询
查看>>
Freebsd系统故障导致系统不能正常启动的恢复数据方法[图]
查看>>
logging模块学习:basicConfig配置文件
查看>>
Golang 使用 Beego 与 Mgo 开发的示例程序
查看>>
DHCP服务器数据备份以及还原
查看>>
ntpdate时间同步
查看>>
Asp.Net MVC 插件化开发简化方案
查看>>
LH乱码转换
查看>>
+++++++子域授权与编译安装(一)
查看>>
编程修养(七)
查看>>
asp.net怎样在URL中使用中文、空格、特殊字符
查看>>