1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

vgimport: invalidate hints

There may be some unconventional methods of sharing disks with vgimport
where hints could cause confusion.  Hints should be disabled when
sharing disks, or pvscan --cache used to regenerate hints as needed,
but invalidating hints from vgimport might help reduce confusion.
This commit is contained in:
David Teigland 2023-02-22 16:19:48 -06:00
parent 0f6da9926d
commit 25cb6a042f

View File

@ -14,6 +14,7 @@
*/
#include "tools.h"
#include "lib/label/hints.h"
static int _vgimport_single(struct cmd_context *cmd,
const char *vg_name,
@ -48,6 +49,13 @@ static int _vgimport_single(struct cmd_context *cmd,
log_print_unless_silent("Volume group \"%s\" successfully imported", vg->name);
/*
* This is not necessary for any normal, known cases, but it could be
* associated with some unconventional method of sharing disks. Hints
* should be disabled when sharing disks, but this might help.
*/
invalidate_hints(cmd);
return ECMD_PROCESSED;
bad: