Installing Ubuntu as KVM guest is not possible because the installer fails to detect Virtual Disk correctly

Bug #1548411 reported by bugproxy on 2016-02-22
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu on IBM z Systems
Undecided
Unassigned
debian-installer (Debian)
Fix Released
Unknown
debian-installer (Ubuntu)
Undecided
Dimitri John Ledkov
parted (Ubuntu)
Undecided
Viktor Mihajlovski
partman-base (Ubuntu)
Undecided
Unassigned
partman-partitioning (Ubuntu)
Undecided
Unassigned

Bug Description

Parted package:
- fails to create dasd partitioning table, on qcow2 backed virtio ccw drives.
- it can create dasd partitioning table, if said virtio ccw drive is backed by a real DASD drive.

== Comment: #0 - Michael Roesch - 2016-02-18 11:09:27 ==
Installer version: 421
Kernel: 4.4.0.4

When trying to partition a KVM Virtual Disk, in my case based on a qcow2 image file, the partitioner is detecting the disk to be a DASD

Virtual disk 1 (vda) - 10.7 GB Virtio Block Device
> #1 10.7 GB f ext4 /
> 8.7 kB FREE SPACE

It then uses fdasd to partition it. This fails with the error:

"fdasd: Unsupported disk type -- Disk geometry does not match a DASD device of type 3390."

I have attached the syslog and partman log files, as well as my guest definition file.

Default Comment by Bridge

tags: added: architecture-s39064 bugnameltc-137464 severity-critical targetmilestone-inin1604

Default Comment by Bridge

Changed in ubuntu:
assignee: nobody → Skipper Bug Screeners (skipper-screen-team)
Kevin W. Rudd (kevinr) on 2016-02-22
affects: ubuntu → debian-installer (Ubuntu)
dann frazier (dannf) on 2016-02-22
Changed in debian-installer (Ubuntu):
assignee: Skipper Bug Screeners (skipper-screen-team) → Dimitri John Ledkov (xnox)
Dimitri John Ledkov (xnox) wrote :

It works if the disk is backed by / pass-through an actual DASD drive.
One can change partitioning table to msdos or gpt by using preseed keys in the paramfile.

However, msdos & gpt partitioning tables fail on the disks backed by / pass-through an actual DASD drive.

So at the moment, one cannot have a partition table that works in all configs, on all virtualisation types with support for automatic recipes throughout.

I believe this is actually an upstream bug in parted, and it should be able to created dasd partition tables on virtio hard-drives in KVM which are backed by simple qcow2 file.

Let me email further details.

description: updated
Changed in parted (Ubuntu):
assignee: nobody → Viktor Mihajlovski (mihajlov)
Phillip Susi (psusi) wrote :

IIRC, this was a defect in the s390 architecture rather than parted: you don't partition a dasd disk by writing the correct metadata to the correct sector, but instead have to use an ioctl to partition the disk out of band.

Viktor Mihajlovski (mihajlov) wrote :

The issue is that partman is chosing the partition type based on the system architecture, not on the disk type. I suggest changes to partman-base and partman-partitioning to determine the correct default partition type per disk on s390. Patches en route.

Viktor Mihajlovski (mihajlov) wrote :

Parted is able to partition DASDs both natively attached and via virtio_blk. It doesn't really make sense to attempt a simulation on top of image files.

The attachment "partman-base patch to record disk label type" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Viktor Mihajlovski (mihajlov) wrote :

Parted is innocent here.

Changed in parted (Ubuntu):
status: New → Invalid
Changed in debian-installer (Debian):
status: Unknown → New
Viktor Mihajlovski (mihajlov) wrote :

The initial patch in comment #6 introduced a regression with pristine, non-DASD disks.

------- Comment From <email address hidden> 2016-02-26 08:14 EDT-------
Please let us know an installer version of xenial-proposed, to verify this as early as possible

Viktor Mihajlovski (mihajlov) wrote :

I accidentally attached the same version of the faulty patch. See also upstream Debian bug.

Changed in partman-partitioning (Ubuntu):
status: New → Fix Committed
Dimitri John Ledkov (xnox) wrote :

debian-installer task is irrelevant, as the partman-* udebs are fetched from the cdrom or over the network, they are not built into the d-i initrd. Marking as invalid.

Changed in debian-installer (Ubuntu):
status: New → Invalid
Changed in partman-base (Ubuntu):
status: New → Fix Committed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package partman-partitioning - 110ubuntu4

---------------
partman-partitioning (110ubuntu4) xenial; urgency=medium

  [ Viktor Mihajlovski ]
  * Revert to using msdos partitioning table on s390x as a fallback,
    however use dasd partitioning table if advised to do so by
    partman. LP: #1548411

 -- Dimitri John Ledkov <email address hidden> Mon, 29 Feb 2016 14:27:51 +0000

Changed in partman-partitioning (Ubuntu):
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package partman-base - 187ubuntu2

---------------
partman-base (187ubuntu2) xenial; urgency=medium

  [ Viktor Mihajlovski ]
  * Add disk label type to device directory, such that
    e.g. partman-partitioning can elect dasd partitioning table for dasd
    drives. LP: #1548411.

 -- Dimitri John Ledkov <email address hidden> Mon, 29 Feb 2016 14:47:30 +0000

Changed in partman-base (Ubuntu):
status: Fix Committed → Fix Released

------- Comment From <email address hidden> 2016-03-01 04:38 EDT-------
I have just verified, that this bug is fixed. Installation on a qcow2 image is now possible and the disk is correctly detected.

bugproxy (bugproxy) wrote :

------- Comment From <email address hidden> 2016-03-01 10:21 EDT-------
Closed after Fix verification

dann frazier (dannf) on 2016-04-26
Changed in ubuntu-z-systems:
status: New → Fix Released
Changed in debian-installer (Debian):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

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