setup-storage fails when preserving LVM volume
Nicolas Courtel
courtel at cena.fr
Wed Dec 8 17:29:05 CET 2010
Hello,
When installing in Squeeze a host which was in Lenny, I want to preserve
user data, using a setup-storage config that has worked with an older
version of FAI (well, I'm not so sure, let's say it might have work some
day...); the result is the same with 3.4.4, 3.4.5, and 4.0experimental45 :
disk_config disk1
primary /boot 512 ext3 rw
primary - 32000- - -
disk_config lvm fstabkey:uuid preserve_lazy:vg0-local
vg vg0 disk1.2
vg0-swap swap 2GiB swap sw
vg0-root / 1GiB ext3 rw
vg0-var /var 4GiB ext3 rw
vg0-usr /usr 8GiB ext3 rw
vg0-opt /opt 2GiB ext3 rw
vg0-local /local 20GiB ext3 rw
On an empty disk, this disk config works fine. But when the volumes
already exist, it does preserve vg0-local as expected, but after having
correctly built all the volumes setup-storage tries to set a label on
the disk; it fails miserably, and removes all the disk's partitions .
There are a couple of other errors in the debug log, too, that might be
related to the problem:
[...]
Use of uninitialized value $p in concatenation (.) or string at
/usr/share/fai/setup-storage//Init.pm line 289.
/dev/sda2 will be preserved
vg0/local will be preserved
[...]
(CMD) parted -s /dev/sda mklabel msdos 1> /tmp/A_p3dpsLFC 2> /tmp/ZQLJLH5omp
Executing: parted -s /dev/sda mklabel msdos
Command had non-zero exit code
(STDOUT) Error: Partition(s) 2 on /dev/sda have been written, but we
have been unable to inform the kernel of the change, probably because
it/they are in use. As a result, the old partition(s) will remain in
use. You should reboot now before making further changes.
I have tried to replace disk1 by sda, preserve_lazy by
preserve_reinstall, but the result is always the same.
The full log is there: http://paste.debian.net/101879/
--
Nicolas
More information about the linux-fai
mailing list