Use centos 6.5 mkisofs Kickstart to create an automatic installation ISO image disc

Source: Internet
Author: User

Use Kickstart to create an automatically installed ISO Disk


1. Mount the centos disc and copy the content of the disc to a specified folder.

Mount/dev/SR1/Media/CDROM/-T iso9660 # note that I use a virtual machine, note that when using your optical drive device mkdir-P/root/auto_installcp-ASON/Media/CDROM/root/auto_install/# Be sure to pay attention when using CP, I spent one afternoon on this part. # I started using CP-r/CDROM/* to copy the file. I found that this method would not copy the hidden file, # However, some hidden files in/CDROM are required for boot, failed. # the correct method is to use archive copy CP-A/Media/CDROM/root/auto_install/to copy the file.

2. Copy the Kickstart profile anaconda-ks.cfg to this directory

cp /root/anaconda-ks.cfg /root/auto_install/cdrom/ks.cfg

3. Configure the Kickstart configuration file (depending on the actual configuration of the user)

vim /root/auto_install/cdrom/ks.cfg# Kickstart file automatically generated by anaconda.#version=DEVELinstallcdromlang en_US.UTF-8keyboard usnetwork --onboot yes --device eth0 --bootproto dhcp --noipv6rootpw  --iscrypted $6$lRieOm2AuzqOKJk1$16DB6y2KHugFfuqkcj0Rmcw8568g304tkOSkOg7V7vt04MPvg30iemq48ljTX9iaWlZTVs8wQ5x7dR1.bi6Gc1firewall --service=sshauthconfig --enableshadow --passalgo=sha512selinux --disabledtimezone Asia/Seoulbootloader --location=mbr --driveorder=sda --append="crashkernel=auto rhgb quiet"# 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 worktextzerombrclearpart --all --drives=sdapart /boot --fstype=ext4 --size=500part pv.008002 --grow --size=1volgroup vg_stu --pesize=4096 pv.008002logvol / --fstype=ext4 --name=lv_root --vgname=vg_stu --grow --size=1024 --maxsize=51200logvol swap --name=lv_swap --vgname=vg_stu --grow --size=2016 --maxsize=2016repo --name="CentOS"  --baseurl=cdrom:0 --cost=100%packages@base@console-internet@core@debugging@directory-client@java-platform@mysql-client@network-file-system-client@php@performance@perl-runtime@postgresql-client@server-platform@server-policy@turbogears@web-server@web-servlet@workstation-policyoddjobsgpiodevice-mapper-persistent-datapaxsamba-winbindcertmongerpam_krb5krb5-workstationperl-DBD-SQLitecertmongerperl-CGI%postsed -i ‘[email protected]:[0-9]:initdefault:@id:3:initdefault:@g‘ /etc/inittab%end

4. Set the Automatic startup and installation of the CD, and locate the KS File

Chmod + w/root/auto_install/CDROM/isolinux. export Vim/root/auto_install/CDROM/isolinux. using default vesamenu. c32 # prompt 1 timeout 600 display boot. msgmenu background splash.jpg menu title welcome to centos 6.5! Menu color border 0 # ffffffff #00000000 menu color sel 7 # ffffffff # ff000000menu Color title 0 # ffffffff #00000000 menu color tabmsg 0 # ffffffff #00000000 menu color unsel 0 # ffffffff #00000000 menu color hotsel 0 # ff000000 # ffffffffmenu color hotkey 7 # ffffffff # ff000000menu color scrollbar 0 # ffffffff #00000000 label Linux menu label ^ install or upgrade an existing system kernel vmlinuz append Ks = CDROM: /KS. CFG initrd = initrd. IMG # Add the KS file path parameter label VESA menu label install system with ^ basic video driver kernel vmlinuz append initrd = initrd. IMG xdriver = VESA nomodesetlabel rescue menu label ^ rescue installed system kernel vmlinuz append initrd = initrd. IMG rescuelabel local menu label boot from ^ local drive menu default # Add the default startup Item localboot 0 xfffflabel memtest86 menu label ^ memory test kernel memtest append-

5. Create a new ISO Image File

mkisofs -R -J -T -v --no-emul-boot --boot-load-size 4  --boot-info-table -V "CentOS 6.5 x86_64 AUTO Install"  -b isolinux/isolinux.bin -c isolinux/boot.cat  -o /root/centos6.4_auto_install.iso  /root/auto_install/cdrom/

6. Install and test the ISO.


This article is from the "imperial garden" blog, please be sure to keep this source http://diguojin.blog.51cto.com/5034509/1549780

Use centos 6.5 mkisofs Kickstart to create an automatic installation ISO image disc

Related Article

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.