[linux-lvm] Dazed & Confused

Marcelo Tosatti marcelo at conectiva.com.br
Thu Aug 31 18:15:16 UTC 2000


On Tue, 29 Aug 2000, Andreas Dilger wrote:

> Ulf Bartelt writes:
> > /dev/vgkira/ftp on /home/ftp type ext2 (ro,errors=remount-ro)
> > /dev/vgkira/ftp2 on /home/ftp2 type ext2 (rw,errors=remount-ro)
> > 
> > (root at kira:/0)~# e2fsadm -L+1G /dev/vgkira/ftp
> > e2fsadm -- ERROR: "/dev/vgkira/ftp" is mounted on "/home/ftp2"
> > e2fsadm -- please umount it to resize
> 
> This is a bug in how e2fsadm checks to see if a filesystem is mounted.
> I have fixed this in my version of e2fsadm, as well as adding support
> for ext2resize and ext2online, so you don't even need to unmount the
> filesystem to resize it (if you have the ext2online kernel patch).
> 
> See ftp.lustre.org:/pub/adilger for an SRPM which has a patch to fix
> all known LVM user-tools bugs, as well as a kernel patch for 0.8final
> on 2.2.16.  I was told by Les Hazelton that my LVM kernel patch will
> apply cleanly to kernel-source-2.2.17-0.16mdk.i586.rpm, from the
> mandrake cooker section on rpmfind.net.

While looking at your patch I found something which seems to be wrong. 

The function lvm_snapshot_COW returns 1 on success. lvm_map() returns  
lvm_snapshot_COW() return code. ll_rw_block calls lvm_map_ptr() (which is
lvm_map()) and expects 0 on success: 

+                       if ((lvm_map_ptr) (bh[i], rw) != 0) {
+                               printk(KERN_ERR
+                                      "Bad lvm_map in ll_rw_block\n");
+                               goto sorry;
+                       }







More information about the linux-lvm mailing list