kickseed partition handler "forgets" about LVM physical volumes

Bug #1133045 reported by Aaron Knister
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
debian-installer (Ubuntu)
New
Undecided
Unassigned

Bug Description

Hi Everyone,

When kickstarting Ubuntu Precise x64 (I haven't tested with any other version) I was unable to get the installer to recognize more than one volume group unless I specify each volume group immediately after its partition definition. What I mean by that is this:

part pv.01 --size 40960 --asprimary --fstype ext3 --ondisk=1
part pv.02 --size 1 --asprimary --fstype ext3 --ondisk=1 --grow

volgroup sysvg1 pv.01
volgroup usrvg1 pv.02

does not work, but this:

part pv.01 --size 40960 --asprimary --fstype ext3 --ondisk=1
volgroup sysvg1 pv.01

part pv.02 --size 1 --asprimary --fstype ext3 --ondisk=1 --grow
volgroup usrvg1 pv.02

does.

The problem appears to be in handlers/volgroup.sh in volgroup_pull_recipe(). After the pending_lvm tag is parsed it is not put back in the event it isn't used which means that only one volume group will ever match and be recognized. Here's a proposed fix:

diff --git a/handlers/volgroup.sh b/handlers/volgroup.sh
index b3a4ea5..48b7638 100644
--- a/handlers/volgroup.sh
+++ b/handlers/volgroup.sh
@@ -18,6 +18,7 @@ volgroup_pull_recipe () {
     if [ "$want_pvname" = "$got_pvname" ]; then
      partition_recipe_append "$line vg_name{ $vgname }"
     else
+ [ -n "$got_pvname" ] && line="$line \$pending_lvm{ $got_pvname }"
      rest="${rest:+$rest }$line ."
     fi
     line=

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.