Recently, a formal version of RHEL 6 was downloaded, and an unattended installation using Kickstart was tested in VMware. The method and steps are as follows:
Method: FTP + TFTP + DHCP + Kickstart + PXE
Prepare two virtual machines, one as the test environment RHEL 6 with IP address 192.168.0.100) and the other as the RHEL 6 installation end.
1. Install the required services and modify the corresponding configuration files:
1. I will use yum to install the required software package. First, I will build the yum disc Source:
[root@localhost ~]# mount /dev/cdrom /mnt
Create a file ending with. repo in the/etc/yum. repos. d directory:
[root@localhost ~]# vi /etc/yum.repos.d/serverl.repo
The configuration is as follows:
2. Install vsftpd and enable the Service:
[root@localhost ~]# yum -y install vsftpd[root@localhost ~]# service vsftpd start
3. Install TFTP, modify the tftp configuration file, and enable the Service:
[root@localhost ~]# yum -y install tftp[root@localhost ~]# yum -y install tftp-server[root@localhost ~]# vim /etc/xinetd.d/tftp
[root@localhost ~]#service xinetd restart
To verify whether the tftp port is Enabled:
OK, no problem!
4. Install dhcp, modify the configuration file, and enable the Service:
[root@localhost ~]#yum -y install dhcp
Create a configuration file:
Modify the configuration file:
[root@localhost ~]#vi /etc/dhcp/dhcpd.conf
The following is the configuration file. The red box is used for adding and modifying the configuration file.
[root@localhost ~]#service dhcpd restart
2. Configure related files required to start with PXE:
[root@localhost ~]#mkdir /tftpboot[root@localhost ~]#mkdir /tftpboot/pxelinux.cfg[root@localhost ~]#cp /usr/share/syslinux/pxelinux.0 /tftpboot/[root@localhost Packages]# cp /mnt/isolinux/isolinux.cfg /tftpboot/pxelinux.cfg/default[root@localhost Packages]# cp /mnt/images/pxeboot/initrd.img /tftpboot/[root@localhost Packages]# cp /mnt/images/pxeboot/vmlinuz /tftpboot/[root@localhost Packages]# chmod 644 /tftpboot/pxelinux.cfg/default[root@localhost Packages]# vim /tftpboot/pxelinux.cfg/default
Add one of the following default files to mark them in red)