[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Debian preseed: How to choose the hdd for partman?



Hi All,

I'm setting up a preseed installation scheme. Considering the partitioning the 
docs on the debian-websites are not specific enough. It is not possible for 
me to spedify the hdd for automatic partition creation. In the following I 
shall describe, what I have done and where the problem is.

My setup is:
* USB stick for booting, which loads a preseed from my http-server 
* USB stick is /dev/sda 
* HDD where debian should be installed is /dev/sdb

This is the relevant section for the partition creation:
**************************************************************************
# REFERENCE (a)
d-i preseed/early_command string dd if=/dev/zero of=/dev/sdb count=64

# REFERENCE (b)
d-i    partman-auto/disk               string  /dev/discs/disc1/disc #/dev/sdb
d-i    partman-auto/method             string regular
d-i    partman/confirm_new_label  boolean  true
d-i    partman-auto/choose_recipe      select one-small-partition
# ok
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

# needed to shut up complaint about unused keep_2 lv
d-i partman-basicmethods/method_only boolean false

d-i partman-auto/expert_recipe string one-small-partition :: \
   10000 10000 10000 ext3 $primary{ } $bootable{ } method{ format } \
      format{ } use_filesystem{ } filesystem{ ext3 } mountpoint{ / } .\
   64 512 300% linux-swap method{ swap } format{ } .  \
   100 10000 1000000000 ext2 method{ keep } .
**************************************************************************

Problem:
The problem is now, that reference (b) in the snipplet doesn't choose disk1 
aka sdb - even though the disk is recognized after the additional modules 
have been loaded (I verified this in another console). The installer always 
uses the scheme for sda - aka the usb stick and the debian stuff is installed 
on my installation-usb-stick...
How can I configure the hdd choice - the snipplet above is extracted from the 
example of the debian website and obiously doesn't work. Maybe this part of 
the installer is evaluated, before the hdd-controller modules are loaded and 
therefore no sdb exists yet? Is there any way to debug stuff like this? Or is 
there a more elegant way to exclude just the usb stick (by uuid) from the 
partman-choices?

Additional question:
Further I'm wondering if there is another way to delete old partitions 
automatically. In reference (a) in the snipplet I try to do this the hard 
way. By the way: Also this line is not working. It has been extracted from my 
old patched initrd-scheme.

Best regards & much thanks for your efforts:
	Gerolf

-- 
http://gerolf.ziegenhain.com

Attachment: signature.asc
Description: Digital signature


Reply to: