CentOS 7.3: kickstart automatic partitioning fails

General support questions
Post Reply
techies
Posts: 2
Joined: 2017/08/21 11:53:39

CentOS 7.3: kickstart automatic partitioning fails

Post by techies » 2017/08/21 12:00:33

Hi all!

I am scripting installation of virtual machines using a kickstart file.

Installation fails and I get a "Failed to save storage configuration" into "No disks selected" error messages in the Anaconda UI.

Image


This is the main part of the kickstart file I am using:

Code: Select all

zerombr
ignoredisk --only-use=vda
clearpart --all --initlabel --drives=vda 
bootloader --append="crashkernel=auto" --location=mbr --boot-drive=vda
part /boot --fstype="xfs" --ondisk=vda --size=500
part pv.16 --fstype="lvmpv" --ondisk=vda --size=9739
volgroup vg00 --pesize=4096 pv.16
logvol swap --fstype="swap" --size=500 --name=swap --vgname=vg00
logvol /home --fstype="xfs" --size=300 --name=home --vgname=vg00
logvol / --fstype="xfs" --size=9230 --name=root --vgname=vg00

Would someone mind providing some pointers so this may work?


Thank you!!
Last edited by techies on 2017/08/22 09:09:10, edited 2 times in total.

User avatar
TrevorH
Site Admin
Posts: 33215
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: CentOS 7.3: kickstart automatic partitioning fails

Post by TrevorH » 2017/08/21 13:46:55

Do you have a vda drive?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

techies
Posts: 2
Joined: 2017/08/21 11:53:39

Re: CentOS 7.3: kickstart automatic partitioning fails

Post by techies » 2017/08/22 08:40:08

Thanks for replying so promptly TrevorH!

Host machine:

Code: Select all

[root@localhost centos7]# fdisk -l

Disk /dev/sda: 45.1 GB, 45097156608 bytes, 88080384 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x000c5022

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048     2099199     1048576   83  Linux
/dev/sda2         2099200    20971519     9436160   8e  Linux LVM
/dev/sda3        20971520    31457279     5242880   8e  Linux LVM
/dev/sda4        31457280    88080383    28311552   8e  Linux LVM

Disk /dev/mapper/cl-root: 42.9 GB, 42937090048 bytes, 83861504 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes


Disk /dev/mapper/cl-swap: 1073 MB, 1073741824 bytes, 2097152 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
The storage volume I'll be using. Screenshot from Virtual Machine Manager:
Image

Screenshot of the disk that appears during, after the installation is halted:
Image


I'm a touch confused which one I should be using in the .cfg file
When the .cfg file had sda, error appeared advising sda was not found, so it must be vda?

Hope you're able to enlighten on what I'm doing wrong.

Thanks Trevor and anybody else reading!! :D

User avatar
TrevorH
Site Admin
Posts: 33215
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: CentOS 7.3: kickstart automatic partitioning fails

Post by TrevorH » 2017/08/22 10:35:51

Your host has /dev/sda, your guest has /dev/vda.

I'm going to guess that you've tried to use more space than is available on the disk. You have hard coded values of 500 and 9739 which comes to a total of 10239MB. If that's even 1MB larger than the size of the disk you've given it then it will fail. Might be better to use --grow and make the specified --size of your lvmpv a lot smaller like --size 500 --grow. Same thing also applies to your / logvol
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Post Reply