diff --git a/WHATS_NEW b/WHATS_NEW index 409288b14..8dc1ea6e1 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,5 +1,6 @@ Version 2.02.63 - ================================ + Fix pvcreate device md filter check. Suppress repeated errors about the same missing PV uuids. Bypass full device scans when using internally-cached VG metadata. Only do one full device scan during each read of text format metadata. diff --git a/lib/metadata/metadata.c b/lib/metadata/metadata.c index dcf1aa919..4060ca223 100644 --- a/lib/metadata/metadata.c +++ b/lib/metadata/metadata.c @@ -1290,18 +1290,10 @@ static int pvcreate_check(struct cmd_context *cmd, const char *name, dev = dev_cache_get(name, cmd->filter); /* Is there an md superblock here? */ + /* FIXME: still possible issues here - rescan cache? */ if (!dev && md_filtering()) { - unlock_vg(cmd, VG_ORPHANS); - - persistent_filter_wipe(cmd->filter); - lvmcache_destroy(cmd, 1); - + refresh_filters(cmd); init_md_filtering(0); - if (!lock_vol(cmd, VG_ORPHANS, LCK_VG_WRITE)) { - log_error("Can't get lock for orphan PVs"); - init_md_filtering(1); - return 0; - } dev = dev_cache_get(name, cmd->filter); init_md_filtering(1); } diff --git a/test/t-vgsplit-stacked.sh b/test/t-vgsplit-stacked.sh index 46cb1053c..fb4e659ed 100644 --- a/test/t-vgsplit-stacked.sh +++ b/test/t-vgsplit-stacked.sh @@ -1,6 +1,6 @@ . ./test-utils.sh -prepare_lvmconf '[ "a/dev\/mirror/", "a/dev\/mapper\/.*$/", "r/.*/" ]' +prepare_lvmconf '[ "a/dev\/mirror/", "a/dev\/mapper\/.*$/", "a/dev\/LVMTEST/", "r/.*/" ]' aux prepare_devs 3 pvcreate $devs