Bug 741728

Summary: raid --useexisting errors without partitions
Product: [Fedora] Fedora Reporter: Bradley Peterson <despite>
Component: pykickstartAssignee: Chris Lumens <clumens>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: bcl, clumens, slords, wnefal+redhatbugzilla
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 832688 (view as bug list) Environment:
Last Closed: 2012-10-22 14:44:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Bradley Peterson 2011-09-27 19:04:46 UTC
Description of problem:
The following kickstart command, which worked as expected in older versions of kickstart, errors with "Partitions required for raid":

raid /boot --fstype=ext4 --level=1 --device=md0 --useexisting

Partitions should not be required when --useexisting is used.  The cause is commit 3fa478da.. which added this check at pykickstart/commands/raid.py:207:

         if len(extra) == 1:
             raise KickstartValueError, formatErrorMsg(self.lineno, msg=_("Partitions required for %s") % "raid")

That should allow for --useexisting.

Version-Release number of selected component (if applicable):
At least Fedora 14 and newer.

How reproducible:
Always.

Steps to Reproduce:
1. Create a kickstart with 'raid /boot --fstype=ext4 --level=1 --device=md0 --useexisting'
2.
3.
  
Actual results:
Before Anaconda fully loads you get "Error parsing kickstart: Partitions required for raid"

Expected results:
Kickstart parses correctly, Anaconda installs system.

Additional info:
I've confirmed that everything works when these lines are removed.  I am not sure how to check for useexisting at that spot in the code.

Comment 1 Chris Lumens 2011-10-05 14:51:23 UTC
Patch to fix this posted:

https://www.redhat.com/archives/anaconda-devel-list/2011-October/msg00028.html