我似乎无法用netinstall执行centos5.8的kickstart安装。 它正确进入文本安装程序,但不断发送一个DHCP服务器的请求,并失败。 我试图手动设置IP到处。 这是我的pxelinux.cfg文件
DEFAULT menu PROMPT 0 MENU TITLE Ubuntu MAAS TIMEOUT 200 TOTALTIMEOUT 6000 ONTIMEOUT local LABEL centos5.8-net kernel /images/centos5.8-net/vmlinuz MENU LABEL centos5.8-net append initrd=/images/centos5.8-net/initrd.img ip=192.168.1.163 netmask=255.255.255.0 hostname=client101 gateway=192.168.1.1 ksdevice=eth0 dns=8.8.8.8 ks=http://192.168.1.125/cblr/svc/op/ks/profile/centos5.8-net MENU end
这里是我的kickstart文件:
# Kickstart file for a very basic Centos 5.8 system # Assigns the server ip: 192.211.48.163 # DNS 8.8.8.8, 8.8.4.4 # London TZ install url --url http://mirror.centos.org/centos-5/5.8/os/i386 lang en_US.UTF-8 keyboard us network --device=eth0 --bootproto=static --ip=192.168.1.163 --netmask=255.255.255.0 --gateway=192.168.1.1 --nameserver=8.8.8.8,8.8.4.4 --hostname=client1-server --onboot=on rootpw --iscrypted $1$Snrd2bB6$CuD/07AX2r/lHgVTPZyAz/ firewall --enabled --port=22:tcp authconfig --enableshadow --enablemd5 selinux --enforcing timezone --utc Europe/London bootloader --location=mbr --driveorder=xvda --append="console=xvc0" # The following is the partition information you requested # Note that any partitions you deleted are not expressed # here so unless you clear all partitions first, this is # not guaranteed to work part /boot --fstype ext3 --size=100 --ondisk=xvda part pv.2 --size=0 --grow --ondisk=xvda volgroup VolGroup00 --pesize=32768 pv.2 logvol swap --fstype swap --name=LogVol01 --vgname=VolGroup00 --size=528 --grow --maxsize=1056 logvol / --fstype ext3 --name=LogVol00 --vgname=VolGroup00 --size=1024 --grow %packages @base @core @dialup @editors @text-internet keyutils iscsi-initiator-utils trousers bridge-utils fipscheck device-mapper-multipath sgpio emacs
这是我的dhcp文件:
ddns-update-style interim; allow booting; allow bootp; ignore client-updates; set vendorclass = option vendor-class-identifier; subnet 192.168.1.0 netmask 255.255.255.0 { host tower { hardware ethernet 50:E5:49:18:D5:C6; fixed-address 192.168.1.163; option routers 192.168.1.1; option domain-name-servers 8.8.8.8,8.8.4.4; option subnet-mask 255.255.255.0; filename "/pxelinux.0"; default-lease-time 21600; max-lease-time 43200; next-server 192.168.1.125; } }
在试图从网上安装之前,是不可能阻止它要求一个dynamic的IP? 也许我的文件有错误?
我的DHCP服务器被设置为忽略客户端更新,并被设置为仅在testing时使用一个MAC地址。
根据我的经验,导致这个问题有两个共同的问题。
1)您可能在控制台输出中发现,安装程序的第二阶段之前,第二个DHCP请求启动之前,您的引导设备尚未被安装程序释放。 一些硬件供应商已经发布BIOS更新来解决这个问题。 您将在控制台输出中看到一条消息,明确指出无法使用该接口(如果是这种情况)。
2)如果你的接口是自动双工的,并且交换机没有设置为“portfast”(思科特定术语),那么在尝试发送DHCP请求之前,kickstart可能没有等待足够长的时间。 即使启用portfast,服务器/交换机组合可能只是需要很长时间才能进行协商。
你可以尝试添加到你的tftp启动文件:
dhcptimeout=180 nicdelay=50 linksleep=50
尝试ping您正在设置的IP,您也可以设置ksdevice = eth0(如果这是适当的networking电缆插入)尝试切换它们,他们可能会以不同的顺序来。
据我所知,你不能明确禁用DHCP,如果由于某种原因静态设置失败,DHCP将回退。 如果它不能到达kickstart文件,它将认为界面不起来,它会后备。