Cannot preseed partman-auto/disk

Bug #40186 reported by Jo Shields
30
Affects Status Importance Assigned to Milestone
debian-installer (Ubuntu)
Invalid
Medium
Unassigned
partman-auto (Ubuntu)
Fix Released
Medium
Colin Watson

Bug Description

The preseed setting "d-i partman-auto/disk /dev/somedrive" should allow you to select which drive to apply a given partman setup to. However, this setting is being ignored by Dapper flight6's installer - regardless of the configured disk, the attached message is shown.

I've tried forcing this through with both "d-i partman-auto/disk /dev/sda" and "d-i partman-auto/init_automatically_partition select Erase entire disk: SCSI1 (0,0,0) (sda) - 8.6GB VMware, VMware Virtual S" but it is ignored every time.

Without some method for bypassing this screen, I cannot see a way to create an unattended installer, which is frustrating for me

Revision history for this message
Colin Watson (cjwatson) wrote :

Boot with DEBCONF_DEBUG=5 to get a debconf trace in /var/log/syslog, which will tell you what question is being asked. I suspect it's partman-auto/automatically_partition.

Revision history for this message
Tim Jackson (tim-jackson) wrote :

this looks basically the same as #39932

Revision history for this message
Jo Shields (directhex) wrote : Repeatedly asked question

Sorry I didn't attach this yesterday, I was unable to connect to launchpad or security.ubuntu.com yesterday afternoon

Revision history for this message
Jo Shields (directhex) wrote :

Tim, yes, it looks like a duplication. My mistake.

Colin, I'll get that later - however, it should be noted that both partman-auto/disk and partman-auto/init_automatically_partition were valid options for Breezy, as per http://archive.ubuntu.com/ubuntu/dists/breezy/main/installer-i386/current/doc/manual/en/apcs01.html

Revision history for this message
Colin Watson (cjwatson) wrote :

I'm afraid the exact form of preseeding is never guaranteed to be stable from release to release.

Revision history for this message
Jo Shields (directhex) wrote :

Okay, the question being asked is indeed partman-auto/automatically_partition

However, now we touch upon a major usability bug - since partman-auto/automatically_partition is a Select, the only working options available are of the format "Erase entire disk: SCSI1 (0,0,0) (sda) - xx.yGB DRIVELABEL" - meaning I need a new ISO with a new preseed file for every potential different hard disk model number that hardware vendors provide - rather than the somewhat more sensible option of "use the first SCSI/SATA drive please". I'd say it was imperative that partman-auto/disk or similar be read, understood, and suppress the interactive partman-auto/automatically_partition question.

I'm also now having an issue that I'm trying to work around - if I preseed "d-i partman-auto/automatically_partition select Erase entire disk: SCSI1 (0,0,0) (sda) - 8.6GB VMware, VMware Virtual S", then I bypass the message that this bug is complaining about - but get an error straight afterwards, complaining that no root device is found (see attached image)

Revision history for this message
Jo Shields (directhex) wrote : New partman problem

Attached error only occurs when preseeding partman-auto/automatically_partition

Revision history for this message
Tim Jackson (tim-jackson) wrote :

I had tried to preseed the partman-auto/automatically_partition select Erase entire disk: IDE1 master (hda) ... and got the same error. It is interesting that preseeding this doesn't work but entering on the same answer works when not preseeded.

Revision history for this message
Jo Shields (directhex) wrote : Re: [Bug 40186] Re: Cannot preseed partman-auto/disk

Okay, so it seems this is definitely now two bugs:

1) Cannot preseed partman-auto with anything even remotely re-usable, as
partman-auto/automatically_partition varies depending on a disk drive's
size, manufacturer & model number

2) Preseeding partman-auto/automatically_partition causes no partitions
to actually be created, leading to "no root partition defined" message

I'd say both are pretty high up the list for fixing before Dapper releases

Revision history for this message
Jo Shields (directhex) wrote :

On further inspection, there is a THIRD problem with partman on the current installer.

If one preseeds partman-auto/automatically_partition in any way, installation fails. If one manually selects "Manually edit partition table" when one has a partman-auto/expert_recipe defined, then instalation fails. If one selects "Erase entire disk", then the partman-auto/expert_recipe is completely ignored.

It seems there's simply no way to do anything partition-related from a preseed file.

Revision history for this message
Tim Jackson (tim-jackson) wrote :

My experience is different regarding that last report
When I preseed the following

d-i partman-auto/disk string /dev/discs/disc0/disc
d-i partman-auto/expert_recipe string __stuff cut out__
d-i partman/confirm_write_new_label boolean true
d-i partman/choose_partition select Finish partitioning and write changes to disk
d-i partman/confirm boolean true

after answering "Erase entire disk" to the question, partman-auto picks up the expert_recipe and successfully partitions as requested without further user input.

Revision history for this message
Jo Shields (directhex) wrote :

You're right - the combined minimum size of two of my defined partitions was smaller than the maximum capacity of the drive - which caused the installer to go with sda1=/,sda5=swap

Is this the expected behaviour when a partman recipe can't be resolved on a given machine?

Revision history for this message
Tim Jackson (tim-jackson) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

directhex wrote:
> You're right - the combined minimum size of two of my defined partitions was smaller than the maximum capacity of the drive - which caused the installer to go with sda1=/,sda5=swap
>
> Is this the expected behaviour when a partman recipe can't be resolved on a given machine?
>

I thought that partman would die and go back to the install menu with an
error when it couldn't resolve the recipe. I have always had to grow at
least one partition to fill the drive to successfully get the recipe to
run on drives of differing sizes.

Tim
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFET54ugLVM9zV5AaMRAsXYAJ4uwRPBJSSoEi/7RrxySs4iz77sLgCcD2C6
O6bPGs4yIfCXU9bt7fkUVZU=
=8Gf7
-----END PGP SIGNATURE-----

Revision history for this message
Jo Shields (directhex) wrote :

The recipe stipulated 5GB for /var and 5GB for / minimum (plus swap and
/boot). The VMware disk I'm working with is 8.6GB - the recipe was
simply ignored as a result

Colin Watson (cjwatson)
Changed in debian-installer:
assignee: nobody → kamion
status: Unconfirmed → Confirmed
Revision history for this message
Colin Watson (cjwatson) wrote :

partman-auto (45ubuntu10) dapper; urgency=low

  * Rename disk selector question to partman-auto/select_disk, and restore
    partman-auto/disk to its former use in preseeding. Trying to overload
    the two turned out to be too complicated, since people who are
    preseeding partman-auto/disk generally just want to apply a recipe to
    the whole disk, and subsequent questions such as
    partman-auto/automatically_partition are hard to preseed (closes: Malone
    #40186).
  * Adjust the way we ask partman-auto/select_disk to make it easier to
    preseed.
  * Update Ubuntu-specific and previously-untranslated translations from
    Rosetta: Bulgarian, Italian, Kurdish, Latvian.

 -- Colin Watson <email address hidden> Fri, 28 Apr 2006 13:15:37 +0100

Changed in partman-auto:
status: Confirmed → Fix Released
Revision history for this message
Jo Shields (directhex) wrote :

Clicked the wrong link. Sorry.

Changed in debian-installer:
status: Unconfirmed → Rejected
Revision history for this message
Carl Karsten (carlfk) wrote :

This works for me in Hardy:

d-i partman-auto/disk string /dev/sda
d-i partman-auto/method string regular

Various issues have been brought up in this report - are there any sill outstanding?

Revision history for this message
hummus (hummus) wrote :

Carl, could you post the full partitioning/partman section(or whole preseed)? I'm having difficulties using the default 8.04 preseed.txt given on the ubuntu site with your two lines.(resulting in the same directhex image from above).

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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