LVM2/test t-pvcreate-operation-md.sh
CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: mbroz at sourceware.org 2009-09-13 19:28:00
Modified files:
test : t-pvcreate-operation-md.sh
Log message:
Do not run mdadm tests if MD module is not loaded.
test/t-pvcreate-operation-md.sh +1 -0
@@ -14,6 +14,7 @@ which perl || exit 200 which awk || exit 200 which cut || exit 200 +test -f /proc/mdstat || exit 200 . ./test-utils.sh
Quoted 17 lines · mbroz at sourceware.org
CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: mbroz at sourceware.org 2009-09-13 19:28:00Modified files:
test :t-pvcreate-operation-md.shLog message:
Do not run mdadm tests if MD module is not loaded.
test/t-pvcreate-operation-md.sh line 20
Quoted 7 lines
test/t-pvcreate-operation-md.sh +1
-0@@ -14,6 +14,7 @@ which perl || exit 200 which awk || exit 200 which cut || exit 200 +test -f /proc/mdstat || exit 200 . ./test-utils.sh
We might try loading the raid0 module if it isn't loaded (grep for raid0 in /proc/mdstat)? And if that fails skip this test?
Quoted 2 lines · Mike Snitzer
We might try loading the raid0 module if it isn't loaded (grep for raid0 in
/proc/mdstat)? And if that fails skip this test?
I have intentionally all modules unloaded (and do not want sometimes run md tests), raid0 is loaded automatically, if md_mod is loaded (then /proc/mdstat exists).
If md_mod is not there, test fails. For most systems it is loaded in initrd anyway.
That was just quick hack, I think there is problem in mdadm, because it created some device node even if md module is not present - but I have no time to debug it now.
Milan
Quoted 6 lines · Milan Broz
Quoted 2 lines · Mike Snitzer
We might try loading the raid0 module if it isn't loaded (grep for raid0 in
/proc/mdstat)? And if that fails skip this test?I have intentionally all modules unloaded (and do not want sometimes run md tests), raid0 is loaded automatically, if
md_modis loaded (then/proc/mdstatexists).
md-mod doesn't provide the raid0 personality; raid0 does. I've changed the test to attempt loading raid0 if it isn't loaded.
Quoted 4 lines
If
md_modis not there, test fails. For most systems it is loaded in initrd anyway.That was just quick hack, I think there is problem in mdadm, because it created some device node even if md module is not present - but I have no time to debug it now.
I'd be interested to know if you still have problems with the test. If so we should get to the bottom of it (maybe require a minimum mdadm version?).
t-pvcreate-operation-md.sh does provide needed testing of LVM2's MD support so it shouldn't be skipped.
Mike