Linux__kickstart Unattended Batch installation system

Source: Internet
Author: User

A. Pre-deployment installation environment:

1.centos6.3 system environment.

first server set up ip 192.168.0.253 nfs service, and install kickstart auto answer file ip 192.168.0.254

2 need to install DHCP Services (Assigning clients IP address to boot from the network)

3 installation TFTP ( ftp,http ) service (provided to download the system image).

4 installation Kickstart ( used to automatically install the system ) .

two Installation:

1 mount the disc with rpm mode of installation.

2withYuminstall the way to ensure that your computer can surf the internet. such as installationDHCPService:yum–y Install DHCP. InstallationTFTPService:yum–y Install Tftp-server yum–yinstall NFS(NFSservices used to share files)yum–y Install Rpcbind (portmapService) installationKickstartAuto Answer fileyum–y install System-config-kickstart.

Three specific configurations

    1. 1. DHCP Setting up the environment: first of all, there must be a fixed IP specific paths and configuration files such as: path: /etc/sysconfig/network-scripts/ifcfg-eth0

Restart the NIC service after all settings are complete: Service Network Restart appears " OK "can.


650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M02/80/EF/wKiom1dFD-uDBBotAAA7Tbi3_m4239.png "title=" 1.png " alt= "Wkiom1dfd-udbbotaaa7tbi3_m4239.png"/>


2. The DHCP configuration method first needs the first time

CP-/usr/share/doc/dhcp*/dhcpd.conf.sample/etc/dhcp/dhcpd.conf Next, and then open the file that needs to be changed as shown:

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M00/80/ED/wKioL1dFER7B4m73AABXcS-WtU8456.png "title=" 2.png " alt= "Wkiol1dfer7b4m73aabxcs-wtu8456.png"/>


save exit after change, restart DHCP Services, Service DHCPD Restart Show OK for normal! You can also run chkconfig dhcpd on to keep the boot from booting.

3. Configuration of the TFTP service: After installing this package,vim/etc/xinetd.d/tftp, The file appears as follows:

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M00/80/ED/wKioL1dFEWGQpBG7AAA0S92jjw0297.png "title=" 3.png " alt= "Wkiol1dfewgqpbg7aaa0s92jjw0297.png"/>


Note that you must put Disable instead " No " , to enable sharing.

then copy the boot files required by the client to the shared directory /var/lib/tftpboot/ below, you first need to install Syslinux ( is a system boot program, see Baidu Encyclopedia ) yum–y install Syslinux run after the installation is complete.

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

Mounting Discs Mount/dev/cdrom/media

(/dev/cdrom different operating systems may not be exactly the same )

Copy the disc under the Isolinux all the files inside /var/lib/tftpboot under ( Note: All files are not Isolinux this directory) operation commands are:

cp-r./isolinux */var/lib/tftpboot .

Mkdir/var/lib/tftpboot/pxelinux.cfg

Cp/media/isolinux/isolinux.cfg>/var/lib/tftpboot/pxelinux.cfg/default .

Then change the permissions:

Chmod 644/var/lib/tftpboot/pxelinux.cfg/default

Modify the Startup profile: path to /var/lib/tftpboot/pxelinux.cfg/default

650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M00/80/EF/wKiom1dFEMbAXP7nAABh4ym57zM812.png "title=" 4.png " alt= "Wkiom1dfembaxp7naabh4ym57zm812.png"/>


Restart after Setup is complete TFTP Service: Service xinetd Restart

set to boot from: chkconfig xinetd on

To turn off the firewall: serviceiptables Stop (selinux preferably also off )


4 in the 0.254 Install the auto answer file above Kickstart Auto Answer file

Run yum-y Install System-config-kickstart

Mkdir/ks easy to store a generated Kickstart file

First Change /etc/exports This configuration file is as follows:

650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M01/80/ED/wKioL1dFEeag2C2WAAAeOCqScNI161.png "title=" 5.png " alt= "Wkiol1dfeeag2c2waaaeocqscni161.png"/>

Start after Setup is complete NFS Service

Service Portmap Restart

Service NFS Restart

If you are prompted not to install the two services Yum–y Install NFS

yum–y Install Rpcbind (portmap service ) If all display ' OK ' is normal.


Finally, it can be run on the machine again. Exportfs This command tests whether sharing is successful , if displayed as:

650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M01/80/ED/wKioL1dFEh_gj0MVAAATZcWoNO0033.png "title=" 6.png " alt= "Wkiol1dfeh_gj0mvaaatzcwono0033.png"/>


The share is successful!


Quad Configuration ks.cfg configuration file


Run System-config-kickstart This command, to configure ks.cfg file

650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M00/80/ED/wKioL1dFEn-hdO0hAADvnlEfIx0288.png "title=" 7.png " alt= "Wkiol1dfen-hdo0haadvnlefix0288.png"/>

This is the configuration of NFS the address and shared directory of the server.

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M02/80/ED/wKioL1dFEr-BrZmDAADXej-i_Xs077.png "title=" 8.png " alt= "Wkiol1dfer-brzmdaadxej-i_xs077.png"/>

650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M02/80/ED/wKioL1dFEuPARFt4AAF2viFJPG8549.png "style=" float: none; "title=" 9.png "alt=" Wkiol1dfeuparft4aaf2vifjpg8549.png "/>

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M00/80/ED/wKioL1dFEufRjXhXAAE8FC0Kcjg434.png "style=" float: none; "title=" 10.png "alt=" Wkiol1dfeufrjxhxaae8fc0kcjg434.png "/>

650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M01/80/ED/wKioL1dFEuuS2M2WAAFxtlfGgk0645.png "style=" float: none; "title=" 11.png "alt=" Wkiol1dfeuus2m2waafxtlfggk0645.png "/>

650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M02/80/ED/wKioL1dFEuzDxIJqAAETPgEV0oQ579.png "style=" float: none; "title=" 12.png "alt=" Wkiol1dfeuzdxijqaaetpgev0oq579.png "/>

The next four items have nothing to do with this experiment, and all of them are not listed.

finally generate a ks.cfg a file and put him in the /ks directory (build it yourself) and then change the permissions under this path , so that the client can access it.

Chmod 777/ks/ks.cfg

Five Copy disc files

Finally, put all the contents of the attached CD into the shared directory . /media

because the CD is mounted directly to the /media at the bottom of this, the path will change, so the last client cannot find the disc, all my side directly copy everything inside the disc to the /media

cp-r/media/centos_6.3 ... /media ( time may be longer )

In fact, you can also put the figure 4 -( 2 It is also possible to change the path in the.

The settings on this server are all complete.


Finally, find a client to set up a network boot.




This article is from the "Drifting Away" blog, make sure to keep this source http://825536458.blog.51cto.com/4417836/1782897

Linux__kickstart Unattended Batch installation system

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.