Linux LVM - Logical Volume Manager for Linux - LVM v0.8 final Known problems and workarounds ----------------------------------------------------------------------- As of 2.3.47 LVM is now included in the main kernel. A few bits went wrong during the merge and you need to add a patch to get 2.3.47 to 2.3.49 to compile with LVM. patch-2.3.47-lvm-2 - patch against kernel 2.3.47 patch-2.3.48-lvm - patch against kernel 2.3.48 patch-2.3.49-LVM-0.8final.gz - patch against kernel 2.3.49 patch-2.3.99-pre1-LVM-0.8final.gz - patch against kernel 2.3.99-pre1 patch-2.3.99-pre5-LVM-0.8final.gz - patch against kernel 2.3.99-pre5 The "final" LVM 0.8 version requires updated user space tools. Otherwise you end up with a IOP protocol revision conflict. At least for glibc2.1 you need a patch for the user mode tools. patch-lvm_0.8final-2 - patch against LVM 0.8final user mode tools ------------------------------------------------------------------------------ If you compile devfs into the kernel but use the kernel commandline option devfs=nomount (to prohibit mounting of devfs in /dev) vgscan fails because it makes use of /proc/partitions which refers to devfs names when devfs is compiled in the kernel. In this case /proc/partitions returns block device names relative to the devfs mount point. The patch below will work around a problem with the LVM scan code. If no valid block devices could be found using /proc/partitions the LVM scan code will fallback to scan /dev. --- 0.8final/tools/lib/lvm_dir_cache.c.orig Sun Feb 27 20:46:41 2000 +++ 0.8final/tools/lib/lvm_dir_cache.c Sun Feb 27 20:47:23 2000 @@ -91,7 +91,8 @@ } } fclose ( proc); - } else { + } + if(!cache_size) { for ( d = 0; devdir[d] != NULL; d++) { dirname = devdir[d]; #ifdef DEBUG ------------------------------------------------------------------------------ Arjan Filius noted the following problem with kernel version 2.3.99-pre[23]: I noticed a change in patch-2.3.99-pre2 which prevents compiling. ./drivers/block/lvm.c: @@ -931,8 +931,8 @@ printk(KERN_DEBUG "%s -- lvm_blk_ioctl -- BLKRAGET\n", lvm_name); #endif - copy_to_user((long *) arg, &lv_ptr->lv_read_ahead, - sizeof(lv_ptr->lv_read_ahead)); + if (put_user(lv->lv_read_ahead, (long *)arg)) + return -EFAULT; break; I changed + if (put_user(lv->lv_read_ahead, (long *)arg)) to + if (put_user(lv_ptr->lv_read_ahead, (long *)arg)) And now i've booted linux-2.3.99-pre3-3 + patch-2.3.99-pre1-LVM-0.8final + lv/lv_ptr fix, and seems to work properly (almost anything on LV's) :) ------------------------------------------------------------------------------ Jorg de Jong detected a bug when using lvchange on a VG with more than one LV which could result in corruption of the LVM structure on disk (such that you are no longer able to access your data). A bug has been detected in lvm.h. Please change the macro LVM_LV_DISK_OFFSET as below: #define LVM_LV_DISK_OFFSET(a, b) ( (a)->lv_on_disk.base + \ sizeof ( lv_disk_t) * b) ------------------------------------------------------------------------------ Torsten Neumann wrote: SuSE 6.4: Bug in lvmcreate_initrd in LVM 0.8e (4/1/2000) (shipped with SuSE 6.4) there is a bug in lvmcreate_intrd. The new vgscan needs(?) /proc, but mount and umount are not copied to the initrd. Fix: Add /bin/mount and /bin/umount to INTRDFILES, and rerun lvmcreate_intrd. ------------------------------------------------------------------------------ Harald Milz (hm@linux-magazin.de) discovered a bug with pvdisplay: > merlin:~ # pvdisplay -c /dev/hda4 > pvdisplay -- option v not allowed with option c Line 150 in pvdisplay.c is wrong: if ( opt_c > 0 + opt_v > 0) { It should be: if ( opt_c > 0 && opt_v > 0) { ------------------------------------------------------------------------------