Install linux on the network
1. Install tftp-server ftp hdcp on another server
Yum install tftp-server vsftpd dhcp-y
During installation, the dependency is automatically checked and the xinetd (super daemon) is automatically installed.
2. Configure xinetd
Vim/etc/xinetd. d/tftp open the tftp configuration file and you can see that the default disable is Yes to change it to no. There are two ways: directly edit the file or
Exit first, chkconfig tftp off
Iii. mounting an iso Image
Umount/media/RHEL_6.4 \ x86_64 \ Disc \ 1/the CD image is mounted to/media by default.
Cd/var/ftp/pub/
Mkdir dvd
Mount/dev/cdrom/var/ftp/pub/dvd
4. Extract the subsystem required for installing the system from the iso Image
Cd/var/ftp/pub/dvd to iso
Cd isolinux
Cp initrd. img vesamenu. c32 vmlinuz isolinux. cfg splash.jpg/var/lib/tftpboot/copy these files to/var/lib/tftpboot/
Cd/var/lib/tftpboot/
Mkdir pxelinux. cfg
Cp isolinux. cfg pxelinux. cfg/default
Rm-rf isolinux. cfg
Install syslinux:
Configure the yum Library first:
Vim/etc/yum. repos. d/dvd. repo
File Content:
[DVD]
Name = DVD
Baseurl = file: // var/ftp/pub/dvd
Gpgcheck = 0
Yum clean all clear yum Library
Yum install syslinux-y
Cp/usr/share/syslinux/pxelinux.0/var/lib/tftpboot/cp the small image to the tftpboot directory
Preparations for installing linux are complete.
5. Configure dhcp
Vim/etc/dhcp/dhcpd. conf
File Content:
Option domain-name "example.com ";
Default-lease-time 600;
Max-lease-time 7200;
Log-facility local7;
Subnet 192.168.4.0 netmask 255.255.255.0 {
Range 192.168.4.30 192.168.4.50;
Filename "pxelinux.0"; # file to be uploaded
Next-server 192.168.4.103; # enter the local address for the next server.
}
# Note that the CIDR Block 192.168.4.0 must be in the same CIDR block as your server (Local Machine ).
/Etc/init. d/dhcpd restart start dhcp Service
6. enable the Service to close the Firewall
Service xinetd start
Iptable-F
Setenforce 0
7. Create an empty Virtual Machine and enable it
Select bridge !!
Normally, you can see the dhcp allocation address tftp transfer file and then you can see the installation interface.
8. Automatic Installation through the response File
Yum install system-config-kickstart.noarch-y install system-config-kickstart.noarch
System-config-kickstart
Note:
Select ftp configuration address for installlation source in installation method: ftp: // 192.168.4.103 # ftp server address (Local Machine)
Directory: pub/dvd
Click save to desktop.
Cd ~
Cpdesktop/ks. cfg/var/ftp/pub/
Vim/var/lib/tftpboot/pxelinux. cfg/default
Add:
Ks = ftp: // 192.168.4.103/pub/ks. cfg
Save and exit
9. enable the new virtual machine and select the first installation phase to start automatic installation.