1
2
3
4
5
6
7
8
|
vi
/etc/yum
.repos.d
/local
.repo
[localbase]
name=localcdrom
baseurl=
file
:
///mnt/Server
enabled=1
gpgcheck=0
保存退出!
mount
/dev/cdrom
/mnt
|
1
2
3
|
yum
install
-y vsftpd
service vsftpd start
chkconfig vsftpd on
|
1
2
3
4
5
6
7
|
yum
install
-y tftp tftp-server xinetd
vi
/etc/xinetd
.d
/tftp
#修改以下两行
server_args=-s
/tftpboot
disable=no
service xinetd start
lsof
-i:69
#已经启动tftp
xinetd 4702 root 5u IPv4 25976 0t0 UDP *:tftp
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
yum
install
-y dhcp
vi
/etc/dhcp/dhcpd
.conf
ddns-update-style interim;
ignore client-updates;
subnet 192.168.0.0 netmask 255.255.255.0{
filename
"pxelinux.0"
;
#指定启动文件路径
next-server 192.168.1.205;
#指定tftp地址
option routers 192.168.0.205;
option subnet-mask 255.255.255.0;
option domain-name
"test.com"
;
option domain-name-servers 8.8.8.8;
range 192.168.0.10 192.168.0.20;
default-lease-
time
3600;
max-lease-
time
7200;
}
service dhcpd start
chkconfig dhcpd on
|
1
2
3
4
5
6
7
8
9
|
yum
install
-y system-config-kickstart
mkdir
/tftpboot
mkdir
/tftpboot/pxelinux
.cfg
cp
/usr/share/syslinux/pxelinux
.0
/tftpboot/
cp
/mnt/isolinux/isolinux
.cfg
/tftpboot/pxelinux
.cfg
/default
cp
/mnt/images/pxeboot/initrd
.img
/tftpboot/
cp
/mnt/images/pxeboot/vmlinuz
/tftpboot/
chmod
644
/tftpboot/pxelinux
.cfg
/default
vi
/tftpboot/pxelinux
.cfg
/default
#修改下面两行
|