Centos Kickstart Installation From Usb
Kickstart file to work with USB Centos. Hard disk but since this is an automatic installation perhaps there is an kickstart option to explicitly specify it.
- Centos Kickstart Installation From Usb
- Kickstart Centos 7 Install
- Centos Kickstart Tutorial
- Centos Kickstart Usb
- Centos 7.4 Kickstart
- I copied the repodata directory from the original ISO, but regenerated the filelists, other, primary and repomd XML files since I only have a subset of the packages (plus my custom one).
- How to Use Kickstart to Install CentOS 7. You can install CentOS 7 automatically with a Kickstart. Now save the Kickstart configuration file to a USB drive as ks.cfg.
After managing to get a Fedora ISO to rebuild successfully (for a USB stick) after adding a kickstart file (https://serverfault.com/questions/548405/), I now have an issue with locating the kickstart file on the USB media.
When this is done from a CDROM you can simply kickckstart by adding this parameter to boot: Dompdf install new fonts.
This will kickstart (providing the kickstart file is named ks.cfg and is in the root of the disk).
Now, obviously this will be different for the USB drive, so from my research, I assumed that this line would do the job:
Evidently this does not work. I get an error informing me this drive is already mounted and cannot be remounted.
EDIT: Actual error message:
To test that the syntax was correct I placed the kickstart file on another USB stick and loaded the same command to grab ks.cfg from the new location:
This does work (providing USB sticks are mounted in order, boot -> sdb1, kickstart -> sdc1). The install will kickstart and complete the install with no issue. Obviously having to use 2 pen drives is somewhat frustrating and unreliable.
Is there a way around this?
5 Answers
I've tried everything, but only this seems to work: put the ks.cfg inside the initrd. So the steps below extract initrd, add the ks.cfg in there, and recreate it. Tested with CentOS7
First mount the original .iso image on your pc, and copy its contents under tmp/
Then,
Then proceed with creating the image as usual:
Centos Kickstart Installation From Usb
I was able to solve this by doing the following:
- Place the kickstart file at the top of the
isolinux
directory and make sure it is namedks.cfg
my
isolinux.cfg
file looks like this:
Using the drive label when referencing ks.cfg
makes the resulting iso image more portable. (it can turned into a bootable USB drive)
My favourite method is to use UUID, because it is stable.
I use two pendrive, first with the CentOS, second with kickstart.After save a kickstart on second pendrive I check its UUID in linux with blkid command:/dev/sdg1: UUID='885E:0BD1' TYPE='vfat'
And after that I use it in installation page:ks=hd:UUID=885E:0BD1:/ks.cfg
It really works!
You have to point to /sda1 because when you boot from USB sda is the USB, sdb is the first hard disk and so on
Kickstart Centos 7 Install
Now you have one partition on the USB stick of size of the ISO image.Just create another partition on the USB stick using the rest space, format it and place your kickstart files there.
UPD: try fdisk
, since parted
seems to be not working this case.
UPD1: iso must be receated with xorriso
Centos Kickstart Tutorial
UPD2: see https://serverfault.com/a/551307/134234