From 46ecca37f92a725cc37971691829feb35596463a Mon Sep 17 00:00:00 2001 From: David Teigland Date: Fri, 26 Mar 2021 14:47:05 -0500 Subject: pvscan: check for exported vg earlier when creating online files so that it's ignored for --cache --listvg --- tools/pvscan.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tools/pvscan.c b/tools/pvscan.c index 4652e7de4..806df812c 100644 --- a/tools/pvscan.c +++ b/tools/pvscan.c @@ -1362,6 +1362,12 @@ static int _online_devs(struct cmd_context *cmd, int do_all, struct dm_list *pvs continue; } + if (vg_is_exported(vg)) { + log_print_pvscan(cmd, "PV %s ignore exported VG.", dev_name(dev)); + release_vg(vg); + continue; + } + /* * online file phase * create pvs_online/ -- cgit v1.2.1