[Bug 1701102] Re: partman-auto-raid refuses to allow /boot inside raid + LVM when using preseed.cfg partman-auto/expert_recipe

Colin Watson cjwatson at canonical.com
Wed Jun 28 22:28:10 UTC 2017


https://anonscm.debian.org/git/d-i/partman-auto-
raid.git/commit/?id=d851cf0f7c5926b9ceb6208bf6464d85fbce9237

** Changed in: partman-auto-raid (Ubuntu)
       Status: In Progress => Fix Committed

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to partman-auto-raid in Ubuntu.
https://bugs.launchpad.net/bugs/1701102

Title:
  partman-auto-raid refuses to allow /boot inside raid + LVM when using
  preseed.cfg partman-auto/expert_recipe

Status in partman-auto-raid package in Ubuntu:
  Fix Committed

Bug description:
  Having /boot reside inside a logical volume as part of a mdraid mirror
  does work when configured manually, however it is impossible to
  preseed with partman-auto/expert_recipe.

  At some point, preseeding "partman-auto-lvm/no_boot boolean true" started to allow /boot to be inside LVM - partman-auto-lvm-56ubuntu1/lib/auto-lvm.sh contains:
          # Make sure a boot partition isn't marked as lvmok, unless the user
          # has told us it is ok for /boot to reside on a logical volume
          if echo "$scheme" | grep lvmok | grep -q "[[:space:]]/boot[[:space:]]"; then
                  db_input critical partman-auto-lvm/no_boot || true
                  db_go || return 255
                  db_get partman-auto-lvm/no_boot || true
                  [ "$RET" = true ] || bail_out unusable_recipe
          fi
  )

  However, partman-auto-raid-30ubuntu1/display.d/initial_auto_raid_lvm doesn't allow exceptions, and /boot can not be inside an lvm on raid volumes:
  # Make sure a boot partition isn't marked as lvmok
  if echo "$scheme" | grep lvmok | grep -q "[[:space:]]/boot[[:space:]]"; then
          bail_out unusable_recipe
  fi

  
  Could a relaxed check similar to partman-auto-lvm be added to partman-auto-raid, so that /boot inside LVM inside mdraid can be preseeded as part of partman-auto/expert_recipe?

  Thanks
  James


  
  d-i partman-auto/method string raid
  d-i partman-auto/disk string /dev/sda /dev/sdb
  d-i partman-auto-lvm/no_boot boolean true
  d-i partman-auto-raid/recipe string                     \
          1 2 0 lvm - raidid=1 .
  d-i partman-auto/expert_recipe string                   \
          myrecipe ::                                     \
                  1000 5000 40000 raid                    \
                          $lvmignore{ }                   \
                          $primary{ }                     \
                          method{ raid }                  \
                          raidid{ 1 }                     \
                  .                                       \
                  1000 1000 1000 ext4                     \
                          $defaultignore{ }               \
                          $lvmok{ }                       \
                          method{ format }                \
                          format{ }                       \
                          use_filesystem{ }               \
                          filesystem{ ext4 }              \
                          mountpoint{ /boot }             \
                  .                                       \
                  6000 6000 6000 ext4                     \
                          $defaultignore{ }               \
                          $lvmok{ }                       \
                          method{ format }                \
                          format{ }                       \
                          use_filesystem{ }               \
                          filesystem{ ext4 }              \
                          mountpoint{ / }                 \
                  .

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/partman-auto-raid/+bug/1701102/+subscriptions



More information about the foundations-bugs mailing list