LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Virtualization and Cloud (https://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/)
-   -   Kickstart: Problem with --initlabel (https://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/kickstart-problem-with-initlabel-4175420733/)

phatrik 08-06-2012 09:14 PM

Kickstart: Problem with --initlabel
 
I'm having a problem when using kickstart to deploy CentOS 6.3 KVM guest OS and no one seems to know why so I figured I'd ask in the KVM SF :) Details:


- Tyring to install CentOS 6.3
- Doing a netinstall using a FTP site
- The installation is for a guest OS (KVM).

The install is being launched with:

virt-install -n server1.example.com -r 768 -l /media/netinstall -x "ks=ftp://192.168.100.2/pub/ks.cfg"


The install starts and gets to the point where I see "Error processing drive. This device may need to be re-initialized." The relevant part of my KS file:


clearpart --initlabel --all
# Disk partitioning information
part /boot --fstype="ext4" --size=500
part /home --fstype="ext4" --size=2048
part swap --fstype="swap" --size=2048
part / --fstype="ext4" --grow --size=1


When I switch to the 3rd terminal for information, here's what I see:

required disklable type for sda (1) is None
default diskalbel type for sda is msdos
selecting msdos diskalbel for sda based on size


Based on "required diskalbel type for sda (1) is none" I decided to remove the --initlabel parm, however I still face the same problem (prompted to initialize the disk).



TIA


Erik

dyasny 08-07-2012 02:39 AM

I'd just abandon virt-install and deploy VMs from a template instead. Much faster and easier to do

phatrik 08-07-2012 02:59 AM

Thank you for your reply, but that's obviously not the answer I'm looking for. Yes I know virt-clone could be used but what I'm truly interested in is getting at the bottom of this problem.

wungad 08-07-2012 08:14 AM

From RedHat Knowledge base
 
Issue
The 'clearpart --initlabel' option in a kickstart no longer initializes drives in RHEL 6.3.

Environment
Red Hat Enterprise Linux 6.3
Anaconda (kickstart)

Resolution
Use the 'zerombr' option in the kickstart to initialize disks and create a new partition table.
Use the 'ignoredisk' option in the kickstart to limit which disks are initialized by the 'zerombr' option. The following example will limit initialization to the 'vda' disk only:
zerombr
ignoredisk --only-use=vda

phatrik 08-07-2012 11:16 AM

Thank you for your reply, that's exactly what I was looking for.


Quote:

Originally Posted by wungad (Post 4748079)
Issue
The 'clearpart --initlabel' option in a kickstart no longer initializes drives in RHEL 6.3.

Environment
Red Hat Enterprise Linux 6.3
Anaconda (kickstart)

Resolution
Use the 'zerombr' option in the kickstart to initialize disks and create a new partition table.
Use the 'ignoredisk' option in the kickstart to limit which disks are initialized by the 'zerombr' option. The following example will limit initialization to the 'vda' disk only:
zerombr
ignoredisk --only-use=vda



All times are GMT -5. The time now is 11:19 PM.