Re: Still puzzled by setup-storage

2010-04-13 Diskussionsfäden Michael Tautschnig
> Michael Tautschnig a écrit :
> >>Michael Tautschnig a écrit :
> >>>[...]
> >>>
> The much nicer approach is introducing something like preserve_lazy:1 (a 
> tribute
> to lazyformat...; but hints for better names are welcome) which causes 
> behaviour
> exactly as you described. Shouldn't be too much of a hassle, but I cannot 
> tell
> whether it'll be done in a day or a week.
> 
> >>>Now that one took effectively nearly three months... Sorry for the delay. 
> >>>I've
> >>>added a patch to the experimental builds, it's in version
> >>>3.3.4~beta1+experimental2. Testing of the new preserve_lazy option is much
> >>>appreciated.
> >>Looks like I'm the first one again :-) . It works as expected on a
> >>partitionless disk, but fails if the LVM volume already exists (I
> >>just tried to install again the same host) : although setup-storage
> >>claims that '(volume) will be preserved', it runs parted to create
> >>the volume group.
> >>
> >>Debug log is at http://paste.debian.net/65875/.
> >>
> >
> >Unfortunately, I was too busy recently and didn't manage to fix it quick 
> >enough:
> >The paste has timed out/is lost. Nicolas, could you do another try and paste 
> >the
> >logs again?
> >
> Sure, I've sent the same log again on http://paste.debian.net/67978/
> 

Ok, this will need some more experimental work I'm afraid. Could you try to do
some manual steps and report back before we actually build this into
setup-storage?

On that particular host, I'd like to know how

parted -s /dev/sda mklabel msdos
parted -s /dev/sda mkpart primary ext3 512B 536871423B
parted -s /dev/sda mkpart primary  536871424B 80026361855B
parted -s /dev/sda set 1 boot on
mkfs.ext3  /dev/sda1
parted -s /dev/sda set 2 lvm on
vgchange -a y vg0

behaves in comparison to

vgchange -a n vg0
parted -s /dev/sda mklabel msdos
parted -s /dev/sda mkpart primary ext3 512B 536871423B
parted -s /dev/sda mkpart primary  536871424B 80026361855B
parted -s /dev/sda set 1 boot on
mkfs.ext3  /dev/sda1
parted -s /dev/sda set 2 lvm on
vgchange -a y vg0

Thanks a lot,
Michael



pgpxh28n726wJ.pgp
Description: PGP signature


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Michael Tautschnig
[...]

> >>You will need one more try, as resize2fs is still complaining:
> >>
> >>(CMD) resize2fs /dev/vg0/usr 16777216s 1> /tmp/Hdv5kRmDAd 2> /tmp/FCrWPAlXCo
> >>Executing: resize2fs /dev/vg0/usr 16777216s
> >>Command resize2fs /dev/vg0/usr 16777216s had exit code 1
> >>(STDERR) resize2fs 1.41.11 (14-Mar-2010)
> >>(STDERR) Please run 'e2fsck -f /dev/vg0/usr' first.
> >>
> >>The full log is at http://paste.debian.net/68019/.
> >>
> >
> >Could you briefly hack a "-f" to the resize2fs calls in Commands.pm? The man
> >page doesn't quite tell whether this will override this e2fsck requirement; 
> >if
> >not, we'll really need to do so, which might be pretty time consuming.
> >
> >
> It does override the e2fsck requirement, resize2fs seems ok, but the
> result is well, unexpected :-) :
> 
> Filesystem   1K-blocks  Used Available Use% Mounted on
> /dev/mapper/vg0-usr6159800  -1278720   7123948   -  /target/usr
> 
> After the end of the installation, the partition is still 6G wide.
> 

Could you give 3.4~beta1+experimental4 another try? This one does the suggested
e2fsck instead of forcing something on resize2fs.

Best,
Michael



pgp3brxaNYeGM.pgp
Description: PGP signature


Re: setup-storage + grub2

2010-04-13 Diskussionsfäden Michael Tautschnig
> Hi,
> Adrian von Bidder wrote,
> 
> > Issues confirmed, and I've reported these twice on this list already.
> > 
> > I just switched to LILO, works for me.
> 
> I think the patch in the experimental tree does not work as
> expected. To boot from LVM boot volume I changed the script to
> following:
> 
> error=0 ; trap "error=$((error|1))" ERR
> 
> $ROOTCMD grub-mkimage --output=/boot/grub/core.img biosdisk part_msdos ext2 
> lvm 

From some earlier post I gathered that biosdisk part_msdos ext2 were
auto-detected anyway and not necessary. Could somebody check whether they are
necessary are not?

> $ROOTCMD update-grub
> $ROOTCMD grub-install --modules="biosdisk part_msdos ext2 lvm" --no-floppy 
> "(hd0)"
> $ROOTCMD grub-setup "(hd0)"
> 
> exit $error
> 
> Having support for raid and serial and lvm seems to be to big for 
> core.img. 

I'm ok with dropping serial; is dropping raid necessary as well? Does it in fact
mean that one cannot combine raid and lvm?

> @Michael: I think we need some tweaking here. device2grub does not
> work correctly for LVM boot support for me. The method in svn trunk
> does work correctly for simple boot via primary partition.
> 

Could somebody send me their /boot/grub/device.map with LVM? As far as I
understand device2grub just parses this file, so probably it just requires a bit
of tweaking.

I'd be more than happy to make the grub2 stuff of experimental (and actually
also mainline FAI) finally work; it's just that I don't have any system running
grub2 and got not hosts to do any testing. I'm therefor relying on your help.

Best,
Michael



pgpapFw1J2pl5.pgp
Description: PGP signature


Re: setup-storage + grub2

2010-04-13 Diskussionsfäden Michael Tautschnig
> Hi,
> 
> I'm in trouble with setup-storage and installing Grub2.
> 
> The error I get is:
> 
> Performing GRUB install with command:
> /usr/sbin/grub-install --no-floppy --root-directory=/target /dev/sda
> /usr/sbin/grub-setup: warn: This msdos-style partition label has no post-MBR 
> gap; embedding won't be possible!.
> /usr/sbin/grub-setup: warn: Embedding is not possible.  GRUB can only be 
> installed in this setup by using blocklists.  However, blocklists are 
> UNRELIABLE and its use is discouraged..
> /usr/sbin/grub-setup: error: if you really want blocklists, use --force...
> 
> I've found something interesting there:
> http://www.mail-archive.com/debian-bugs-d...@lists.debian.org/msg682316.html
> 
> It is said that "the first partition starts at sector 63 like any normal
> partioning tool does."
> 
> On my machine, I've got the first partition starting at sector 1.
> 
> # fdisk -lu /dev/sda
> 
> Disk /dev/sda: 64.4 GB, 64424509440 bytes
> 255 heads, 63 sectors/track, 7832 cylinders, total 125829120 sectors
> Units = sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disk identifier: 0x0008e681
> 
>Device Boot  Start End  Blocks   Id  System
> /dev/sda1   *   1  204800  102400   83  Linux
> Partition 1 does not end on cylinder boundary.
> /dev/sda2  204801 2301952 1048576   82  Linux swap / Solaris
> Partition 2 does not end on cylinder boundary.
> /dev/sda3 2301953 4399104 1048576   83  Linux
> Partition 3 does not end on cylinder boundary.
> /dev/sda4 4399105   12582911960715007+   f  W95 Ext'd (LBA)
> /dev/sda5 4399168 7471167 1536000   83  Linux
> /dev/sda6 7471231 9568382 1048576   83  Linux
> /dev/sda7 956844610617021  524288   83  Linux
> /dev/sda81061708512714236 1048576   83  Linux
> /dev/sda912714300   12582911956557410   8e  Linux LVM
> 
> I'm using fai 3.3.5+experimental3.
> 

Could you give 3.4~beta1+experimental5 another chance? If you redo the
partitioning using this version, you'll get back the
first-partition-starts-at-sector-63 free space.

> I also get a bunch messages about uninitialized value
> 
> Calling task_partition
> Partitioning local harddisks using setup-storage
> Starting setup-storage 1.2.1+exp
> Using config file: /var/lib/fai/config/disk_config/DEFAULT
> Executing: parted -s /dev/sda unit TiB print
> Use of uninitialized value $fs in substitution (s///) at 
> /usr/share/fai/setup-storage//Volumes.pm line 257.
> [...]
> Use of uninitialized value $fs in substitution (s///) at 
> /usr/share/fai/setup-storage//Volumes.pm line 257.

[...]

Could you send the output of

parted -s /dev/sda unit TiB print

? Maybe the format has changed, so probably also parted -v would be useful.

Thanks a lot,
Michael



pgpaJEpwpd7Oc.pgp
Description: PGP signature


Re: Still puzzled by setup-storage

2010-04-13 Diskussionsfäden Nicolas Courtel



Ok, this will need some more experimental work I'm afraid. Could you try to do
some manual steps and report back before we actually build this into
setup-storage?

On that particular host, I'd like to know how

parted -s /dev/sda mklabel msdos
parted -s /dev/sda mkpart primary ext3 512B 536871423B
parted -s /dev/sda mkpart primary  536871424B 80026361855B
parted -s /dev/sda set 1 boot on
mkfs.ext3  /dev/sda1
parted -s /dev/sda set 2 lvm on
vgchange -a y vg0

behaves in comparison to

vgchange -a n vg0
parted -s /dev/sda mklabel msdos
parted -s /dev/sda mkpart primary ext3 512B 536871423B
parted -s /dev/sda mkpart primary  536871424B 80026361855B
parted -s /dev/sda set 1 boot on
mkfs.ext3  /dev/sda1
parted -s /dev/sda set 2 lvm on
vgchange -a y vg0
  


Apart from the extra output line, I can see no difference : in both 
cases, the LVM volumes are back and active after the last vgchange.

Here's the full output of the second command list.

r...@lutil:~# vgchange -a n vg0
 0 logical volume(s) in volume group "vg0" now active
r...@lutil:~# parted -s /dev/sda mklabel msdos
r...@lutil:~# parted -s /dev/sda mkpart primary ext3 512B 536871423B
r...@lutil:~# parted -s /dev/sda mkpart primary  536871424B 80026361855B
r...@lutil:~# parted -s /dev/sda set 1 boot on
r...@lutil:~# mkfs.ext3  /dev/sda1
mke2fs 1.41.11 (14-Mar-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
32768 inodes, 131072 blocks
6553 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=134217728
4 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
   32768, 98304

Writing inode tables: done   
Creating journal (4096 blocks): done

Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 29 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
r...@lutil:~# parted -s /dev/sda set 2 lvm on
r...@lutil:~# vgchange -a y vg0
 7 logical volume(s) in volume group "vg0" now active
r...@lutil:~#

--
Nicolas




Re: Still puzzled by setup-storage

2010-04-13 Diskussionsfäden Michael Tautschnig
> 
> >Ok, this will need some more experimental work I'm afraid. Could you try to 
> >do
> >some manual steps and report back before we actually build this into
> >setup-storage?
> >
> >On that particular host, I'd like to know how
> >
> >parted -s /dev/sda mklabel msdos
> >parted -s /dev/sda mkpart primary ext3 512B 536871423B
> >parted -s /dev/sda mkpart primary  536871424B 80026361855B
> >parted -s /dev/sda set 1 boot on
> >mkfs.ext3  /dev/sda1
> >parted -s /dev/sda set 2 lvm on
> >vgchange -a y vg0
> >
> >behaves in comparison to
> >
> >vgchange -a n vg0
> >parted -s /dev/sda mklabel msdos
> >parted -s /dev/sda mkpart primary ext3 512B 536871423B
> >parted -s /dev/sda mkpart primary  536871424B 80026361855B
> >parted -s /dev/sda set 1 boot on
> >mkfs.ext3  /dev/sda1
> >parted -s /dev/sda set 2 lvm on
> >vgchange -a y vg0
> 
> Apart from the extra output line, I can see no difference : in both
> cases, the LVM volumes are back and active after the last vgchange.
> Here's the full output of the second command list.
> 

[...]

Could you maybe do an explicit vgchange -a y vg0 beforehand? Somehow it should
be possible to reprocduce the error that parted reports when doing, e.g., the
second mkpart. That error was

Error: Error informing the kernel about modifications to partition /dev/sda2 --
Device or resource busy.

in http://paste.debian.net/67978/.

Thanks a lot for your help!!!

Best,
Michael



pgpivPHo4uDtN.pgp
Description: PGP signature


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Nicolas Courtel


  

You will need one more try, as resize2fs is still complaining:

(CMD) resize2fs /dev/vg0/usr 16777216s 1> /tmp/Hdv5kRmDAd 2> /tmp/FCrWPAlXCo
Executing: resize2fs /dev/vg0/usr 16777216s
Command resize2fs /dev/vg0/usr 16777216s had exit code 1
(STDERR) resize2fs 1.41.11 (14-Mar-2010)
(STDERR) Please run 'e2fsck -f /dev/vg0/usr' first.

The full log is at http://paste.debian.net/68019/.



Could you give 3.4~beta1+experimental4 another try? This one does the suggested
e2fsck instead of forcing something on resize2fs.
  


Still failing, the last option given to e2fsck seems to be wrong:

[...]
Executing: lvresize -L 8192 vg0/usr
(STDOUT)   Extending logical volume usr to 8.00 GiB
(STDOUT)   Logical volume usr successfully resized
(CMD) e2fsck -f /dev/vg0/usr 16777216s 1> /tmp/7enTWTQVxG 2> /tmp/U_mywiuc75
Executing: e2fsck -f /dev/vg0/usr 16777216s
Command e2fsck -f /dev/vg0/usr 16777216s had exit code 16
(STDERR) Usage: e2fsck [-panyrcdfvtDFV] [-b superblock] [-B blocksize]
[...]

The full log is at http://paste.debian.net/68671/.

--
Nicolas


linux-2.6/linux-base libata transition

2010-04-13 Diskussionsfäden Toomas Tamm
Hi,

Debian release team has published the latest "Bits from the Release
Team" (dated April 1st) and this document
http://lists.debian.org/debian-devel-announce/2010/04/msg1.html
includes the following:

> There are some other transitions that we are aware of that are
> currently prepared and/or already going on:

[...]

>  * linux-2.6/linux-base libata transition
> New drivers using 'libata' are about to replace the old IDE
> drivers. linux-base will prompt you on x86 to upgrade your
> configuration files (fstab, bootloader) to refer to stable UUIDs
> instead of unpredictable device names.

I wonder how this will affect FAI; both the disk partitioning and
bootloader configuration? Is this a good thing to wait for, or a major
headache ahead?

Toomas Tamm


Re: linux-2.6/linux-base libata transition

2010-04-13 Diskussionsfäden Michael Tautschnig
> Hi,
> 
> Debian release team has published the latest "Bits from the Release
> Team" (dated April 1st) and this document
> http://lists.debian.org/debian-devel-announce/2010/04/msg1.html
> includes the following:
> 
> > There are some other transitions that we are aware of that are
> > currently prepared and/or already going on:
> 
> [...]
> 
> >  * linux-2.6/linux-base libata transition
> > New drivers using 'libata' are about to replace the old IDE
> > drivers. linux-base will prompt you on x86 to upgrade your
> > configuration files (fstab, bootloader) to refer to stable UUIDs
> > instead of unpredictable device names.
> 
> I wonder how this will affect FAI; both the disk partitioning and
> bootloader configuration? Is this a good thing to wait for, or a major
> headache ahead?
> 

I'm not sure how this upgrade will proceed if UUIDs are already in use;
setup-storage has supported UUIDs ever since (using the fstabkey:uuid option)
and myself I'm also using a preinst script to put the UUIDs into grub's
menu.lst. That seems to work really well as device names weren't usable as keys
on (multiple) SCSI devices anyway.

Best,
Michael



pgppm7p60VSA2.pgp
Description: PGP signature


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Michael Tautschnig
> 
> You will need one more try, as resize2fs is still complaining:
> 
> (CMD) resize2fs /dev/vg0/usr 16777216s 1> /tmp/Hdv5kRmDAd 2> 
> /tmp/FCrWPAlXCo
> Executing: resize2fs /dev/vg0/usr 16777216s
> Command resize2fs /dev/vg0/usr 16777216s had exit code 1
> (STDERR) resize2fs 1.41.11 (14-Mar-2010)
> (STDERR) Please run 'e2fsck -f /dev/vg0/usr' first.
> 
> The full log is at http://paste.debian.net/68019/.
> 
> >Could you give 3.4~beta1+experimental4 another try? This one does the 
> >suggested
> >e2fsck instead of forcing something on resize2fs.
> 
> Still failing, the last option given to e2fsck seems to be wrong:
> 
> [...]
> Executing: lvresize -L 8192 vg0/usr
> (STDOUT)   Extending logical volume usr to 8.00 GiB
> (STDOUT)   Logical volume usr successfully resized
> (CMD) e2fsck -f /dev/vg0/usr 16777216s 1> /tmp/7enTWTQVxG 2> /tmp/U_mywiuc75
> Executing: e2fsck -f /dev/vg0/usr 16777216s
> Command e2fsck -f /dev/vg0/usr 16777216s had exit code 16
> (STDERR) Usage: e2fsck [-panyrcdfvtDFV] [-b superblock] [-B blocksize]
> [...]
> 
> The full log is at http://paste.debian.net/68671/.
> 

Oh well, copy&paste is evil, isn't it? Could you please give
3.4~beta1+experimental6 another try?

Thanks,
Michael



pgpQ6hbhBJclA.pgp
Description: PGP signature


Re: Still puzzled by setup-storage

2010-04-13 Diskussionsfäden Nicolas Courtel

Michael Tautschnig a écrit :

Ok, this will need some more experimental work I'm afraid. Could you try to do
some manual steps and report back before we actually build this into
setup-storage?

On that particular host, I'd like to know how

parted -s /dev/sda mklabel msdos
parted -s /dev/sda mkpart primary ext3 512B 536871423B
parted -s /dev/sda mkpart primary  536871424B 80026361855B
parted -s /dev/sda set 1 boot on
mkfs.ext3  /dev/sda1
parted -s /dev/sda set 2 lvm on
vgchange -a y vg0

behaves in comparison to

vgchange -a n vg0
parted -s /dev/sda mklabel msdos
parted -s /dev/sda mkpart primary ext3 512B 536871423B
parted -s /dev/sda mkpart primary  536871424B 80026361855B
parted -s /dev/sda set 1 boot on
mkfs.ext3  /dev/sda1
parted -s /dev/sda set 2 lvm on
vgchange -a y vg0
  

Apart from the extra output line, I can see no difference : in both
cases, the LVM volumes are back and active after the last vgchange.
Here's the full output of the second command list.




[...]

Could you maybe do an explicit vgchange -a y vg0 beforehand? Somehow it should
be possible to reprocduce the error that parted reports when doing, e.g., the
second mkpart. That error was

Error: Error informing the kernel about modifications to partition /dev/sda2 --
Device or resource busy.

in http://paste.debian.net/67978/.
  
I had started lvm before running the commands, but it's not enough to 
reproduce the problem. I have also tried to run them after having 
stopped the installation, didn't work either.
I finally inserted the vgchange line in Commands.pm, it seems to have 
been run as expected, and the result is still an error that happens later.
The result is at http://paste.debian.net/68689/, and my (quite sloppy 
:-) ) patch is below:


--- Commands.pm.~1~ 2010-04-13 13:32:32.0 +0200
+++ Commands.pm 2010-04-13 15:20:11.0 +0200
@@ -806,6 +806,7 @@
or die "Can't change disklabel, partitions are to be preserved\n";

  # write the disklabel to drop the previous partition table
+&FAI::push_command( "vgchange -a n vg0", "vg_created_vg0", 
"vg_disabled_vg0" );

  &FAI::push_command( "parted -s $disk mklabel $label", "exist_$disk",
"cleared1_$disk" );

--
Nicolas


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Nicolas Courtel



Still failing, the last option given to e2fsck seems to be wrong:

[...]



Oh well, copy&paste is evil, isn't it? Could you please give
3.4~beta1+experimental6 another try?

  

e2fsck is still grumpy:

(CMD) e2fsck -f /dev/vg0/usr 1> /tmp/2jcv6xhbVE 2> /tmp/qT7zDl1RU4
Executing: e2fsck -f /dev/vg0/usr
Command e2fsck -f /dev/vg0/usr had exit code 8
(STDERR) e2fsck 1.41.11 (14-Mar-2010)
(STDERR) e2fsck: need terminal for interactive repairs

http://paste.debian.net/68701/

--
Nicolas


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Michael Tautschnig
> 
> >>Still failing, the last option given to e2fsck seems to be wrong:
> >>
> >>[...]
> >
> >Oh well, copy&paste is evil, isn't it? Could you please give
> >3.4~beta1+experimental6 another try?
> >
> e2fsck is still grumpy:
> 
> (CMD) e2fsck -f /dev/vg0/usr 1> /tmp/2jcv6xhbVE 2> /tmp/qT7zDl1RU4
> Executing: e2fsck -f /dev/vg0/usr
> Command e2fsck -f /dev/vg0/usr had exit code 8
> (STDERR) e2fsck 1.41.11 (14-Mar-2010)
> (STDERR) e2fsck: need terminal for interactive repairs
> 
> http://paste.debian.net/68701/
> 

Could you run e2fsck interactively, doing

e2fsck -p -f /dev/vg0/usr

to see whether a safe repair can be done non-interactively? I wonder if your
filesystem is corrupted anyway and that e2fsck run before resize2fs wouldn't
even be necessary otherwise.

Thanks,
Michael



pgpscpKOIQLld.pgp
Description: PGP signature


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Nicolas Courtel



e2fsck is still grumpy:

(CMD) e2fsck -f /dev/vg0/usr 1> /tmp/2jcv6xhbVE 2> /tmp/qT7zDl1RU4
Executing: e2fsck -f /dev/vg0/usr
Command e2fsck -f /dev/vg0/usr had exit code 8
(STDERR) e2fsck 1.41.11 (14-Mar-2010)
(STDERR) e2fsck: need terminal for interactive repairs

http://paste.debian.net/68701/




Could you run e2fsck interactively, doing

e2fsck -p -f /dev/vg0/usr

to see whether a safe repair can be done non-interactively? I wonder if your
filesystem is corrupted anyway and that e2fsck run before resize2fs wouldn't
even be necessary otherwise.
  

Works fine after an fai-sysinfo boot:

r...@lutil:~# e2fsck -p -f /dev/vg0/usr
/dev/vg0/usr: 41374/393216 files (0.6% non-contiguous), 227117/1572864 
blocks

r...@lutil:~#

At this time resize2fs doesn't require a prior e2fsck, though.

--
Nicolas


Re: setup-storage + grub2

2010-04-13 Diskussionsfäden Mathieu Alorent
Le mardi 13 avril 2010 à 11:09 +0200, Michael Tautschnig a écrit :
> > Hi,
Hi

[...]
> 
> Could you give 3.4~beta1+experimental5 another chance? If you redo the
> partitioning using this version, you'll get back the
> first-partition-starts-at-sector-63 free space.

No problem with "first-partition-starts-at-sector-63" since 3.4~beta1
+experimental5. Thanks.

> 
> > I also get a bunch messages about uninitialized value
> > 
> > Calling task_partition
> > Partitioning local harddisks using setup-storage
> > Starting setup-storage 1.2.1+exp
> > Using config file: /var/lib/fai/config/disk_config/DEFAULT
> > Executing: parted -s /dev/sda unit TiB print
> > Use of uninitialized value $fs in substitution (s///) at 
> > /usr/share/fai/setup-storage//Volumes.pm line 257.
> > [...]
> > Use of uninitialized value $fs in substitution (s///) at 
> > /usr/share/fai/setup-storage//Volumes.pm line 257.
> 
> [...]
> 
> Could you send the output of
> 
> parted -s /dev/sda unit TiB print
> 
> ? Maybe the format has changed, so probably also parted -v would be useful.

r...@ubuntu-fai-srv:~# parted -s /dev/sda unit TiB print
Model: ATA VBOX HARDDISK (scsi)
Disk /dev/sda: 0.06TiB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  StartEnd  Size Type  File system Flags
 1  0.00TiB  0.00TiB  0.00TiB  primary   ext3boot
 2  0.00TiB  0.00TiB  0.00TiB  primary   linux-swap(v1)
 3  0.00TiB  0.00TiB  0.00TiB  primary   ext3
 4  0.00TiB  0.06TiB  0.06TiB  extended  lba
 5  0.00TiB  0.00TiB  0.00TiB  logical   ext3
 6  0.00TiB  0.00TiB  0.00TiB  logical   ext3
 7  0.00TiB  0.00TiB  0.00TiB  logical   ext3
 8  0.00TiB  0.01TiB  0.00TiB  logical   ext3
 9  0.01TiB  0.06TiB  0.05TiB  logical   lvm

r...@ubuntu-fai-srv:~# 


> 
> Thanks a lot,
> Michael
> 

Regards.

-- 
Mathieu Alorent
Shell&Core Sophia-Antipolis
AUSY
Pour France Telecom – OPF/PORTAILS/DOP/HEBEX/SOPHIA

Tél: 04 97 12 6226

malorent@orange-ftgroup.com

La signature de ce mail peut être vérifiée en installant les autorités de 
certifications CAcert (Class1 et Class3) :
http://www.cacert.org/certs/root.crt
http://www.cacert.org/certs/class3.crt.

http://www.cacert.org/index.php?id=3


smime.p7s
Description: S/MIME cryptographic signature


Re: FAI 3.3.3 + Ubuntu Lucid

2010-04-13 Diskussionsfäden Mathieu Alorent
Le jeudi 18 mars 2010 à 21:08 +0100, Stephan Hermann a écrit :
> Console: switching to colour framebuffer device 80x30
> 
> I tried to disable it via modeset but failed here.. 

Using a -server flavoured kernel (on ubuntu) seem to don't change the
screen mode... I didn't found how to disable fb on -generic kernels.

-- 
Mathieu Alorent
Shell&Core Sophia-Antipolis
AUSY
Pour France Telecom – OPF/PORTAILS/DOP/HEBEX/SOPHIA

Tél: 04 97 12 6226

malorent@orange-ftgroup.com

La signature de ce mail peut être vérifiée en installant les autorités de 
certifications CAcert (Class1 et Class3) :
http://www.cacert.org/certs/root.crt
http://www.cacert.org/certs/class3.crt.

http://www.cacert.org/index.php?id=3


smime.p7s
Description: S/MIME cryptographic signature


Re: setup-storage + grub2

2010-04-13 Diskussionsfäden Mathieu Alorent
Le mardi 13 avril 2010 à 19:56 +0200, Mathieu Alorent a écrit :
> 
> > ? Maybe the format has changed, so probably also parted -v would be
> useful. 

I forgot to say, this is an Ubuntu Lucid nfsroot.

# parted -v
parted (GNU parted) 2.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later .
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by .


-- 
Mathieu Alorent
Shell&Core Sophia-Antipolis
AUSY
Pour France Telecom – OPF/PORTAILS/DOP/HEBEX/SOPHIA

Tél: 04 97 12 6226

malorent@orange-ftgroup.com

La signature de ce mail peut être vérifiée en installant les autorités de 
certifications CAcert (Class1 et Class3) :
http://www.cacert.org/certs/root.crt
http://www.cacert.org/certs/class3.crt.

http://www.cacert.org/index.php?id=3


smime.p7s
Description: S/MIME cryptographic signature


Re: setup-storage + grub2

2010-04-13 Diskussionsfäden Waldemar Brodkorb
Hi Michael,
Michael Tautschnig wrote,

> > Hi,
> > Adrian von Bidder wrote,
> > 
> > > Issues confirmed, and I've reported these twice on this list already.
> > > 
> > > I just switched to LILO, works for me.
> > 
> > I think the patch in the experimental tree does not work as
> > expected. To boot from LVM boot volume I changed the script to
> > following:
> > 
> > error=0 ; trap "error=$((error|1))" ERR
> > 
> > $ROOTCMD grub-mkimage --output=/boot/grub/core.img biosdisk part_msdos ext2 
> > lvm 
> 
> From some earlier post I gathered that biosdisk part_msdos ext2 were
> auto-detected anyway and not necessary. Could somebody check whether they are
> necessary are not?

I checked again, they are really necessary. At least for
Ubuntu/Lucid with with grub 1.98. Without them I only get the grub
rescue console.
 
> > $ROOTCMD update-grub
> > $ROOTCMD grub-install --modules="biosdisk part_msdos ext2 lvm" --no-floppy 
> > "(hd0)"
> > $ROOTCMD grub-setup "(hd0)"
> > 
> > exit $error
> > 
> > Having support for raid and serial and lvm seems to be to big for 
> > core.img. 
> 
> I'm ok with dropping serial; is dropping raid necessary as well? Does it in 
> fact
> mean that one cannot combine raid and lvm?

Dropping serial is required, raid can be included without breaking
LVM boot.
 
> > @Michael: I think we need some tweaking here. device2grub does not
> > work correctly for LVM boot support for me. The method in svn trunk
> > does work correctly for simple boot via primary partition.
> > 
> 
> Could somebody send me their /boot/grub/device.map with LVM? As far as I
> understand device2grub just parses this file, so probably it just requires a 
> bit
> of tweaking.

device.map looks like usual:
(hd0)   /dev/sda

..
for device in $BOOT_DEVICE; do
  grub_dev=$(device2grub $device)
  if [ -z "$grub_dev" ] ; then
grub_dev=$(echo $device | sed 's#^/dev/##')
  fi

BOOT_DEVICE is in case of LVM usage: /dev/mapper/VolGroup00-rootlv.
Which does not match with this regular expression used in
device2grub:
$device=~ m#^(/dev/(?:[shv]d\D|i2o/hd\D|ida/c\d*d\d*|cciss/c\d*d\d*))p*(\d*)$# 

And if $grub_dev is empty, then "mapper/VolGroup00-rootlv" is also
wrong. We would need to add some code to parse pvdisplay to get the
real device node used by the VolumeGroup, where the RootLV is
created on. 

Just as a site note, I think it does not match Xen para virt block
devices. (.f.e xvda)
 
> I'd be more than happy to make the grub2 stuff of experimental (and actually
> also mainline FAI) finally work; it's just that I don't have any system 
> running
> grub2 and got not hosts to do any testing. I'm therefor relying on your help.
> 
> Best,
> Michael

have fun,
Waldemar



Re: FAI 3.3.3 + Ubuntu Lucid

2010-04-13 Diskussionsfäden Waldemar Brodkorb
Hi,
Mathieu Alorent wrote,

> Le jeudi 18 mars 2010 à 21:08 +0100, Stephan Hermann a écrit :
> > Console: switching to colour framebuffer device 80x30
> > 
> > I tried to disable it via modeset but failed here.. 
> 
> Using a -server flavoured kernel (on ubuntu) seem to don't change the
> screen mode... I didn't found how to disable fb on -generic kernels.

If your graphics card uses KMS, you can try "nomodeset" to disable 
the framebuffer switching. Otherwise deleting of any frambuffer
kernel modules in the nfsroot or initrd might help, too. (worst case
:))
 
bye
 Waldemar


Re: resizing an lvm volume with setup-storage

2010-04-13 Diskussionsfäden Michael Tautschnig
> 
> >>e2fsck is still grumpy:
> >>
> >>(CMD) e2fsck -f /dev/vg0/usr 1> /tmp/2jcv6xhbVE 2> /tmp/qT7zDl1RU4
> >>Executing: e2fsck -f /dev/vg0/usr
> >>Command e2fsck -f /dev/vg0/usr had exit code 8
> >>(STDERR) e2fsck 1.41.11 (14-Mar-2010)
> >>(STDERR) e2fsck: need terminal for interactive repairs
> >>
> >>http://paste.debian.net/68701/
> >>
> >
> >Could you run e2fsck interactively, doing
> >
> >e2fsck -p -f /dev/vg0/usr
> >
> >to see whether a safe repair can be done non-interactively? I wonder if your
> >filesystem is corrupted anyway and that e2fsck run before resize2fs wouldn't
> >even be necessary otherwise.
> Works fine after an fai-sysinfo boot:
> 
> r...@lutil:~# e2fsck -p -f /dev/vg0/usr
> /dev/vg0/usr: 41374/393216 files (0.6% non-contiguous),
> 227117/1572864 blocks
> r...@lutil:~#
> 
> At this time resize2fs doesn't require a prior e2fsck, though.
> 

So I hope that the addition of -p fixes this (3.4~beta1+experimental7).

Best,
Michael



pgp4jVcRQvTTe.pgp
Description: PGP signature