1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-08-03 08:22:00 +03:00

lvmetad: Check for reappeared PVs.

This commit is contained in:
Petr Rockai
2013-04-03 12:48:28 +02:00
parent 00ed6759c8
commit 382fc878d7
3 changed files with 7 additions and 2 deletions

2
lib/cache/lvmetad.c vendored
View File

@ -389,6 +389,8 @@ struct volume_group *lvmetad_vg_lookup(struct cmd_context *cmd, const char *vgna
pvl->pv->dev = lvmcache_device(info);
if (!pvl->pv->dev)
pvl->pv->status |= MISSING_PV;
else
check_reappeared_pv(vg, pvl->pv);
if (!lvmcache_fid_add_mdas_pv(info, fid)) {
vg = NULL;
goto_out; /* FIXME error path */

View File

@ -2836,8 +2836,8 @@ int vg_missing_pv_count(const struct volume_group *vg)
return ret;
}
static void check_reappeared_pv(struct volume_group *correct_vg,
struct physical_volume *pv)
void check_reappeared_pv(struct volume_group *correct_vg,
struct physical_volume *pv)
{
struct pv_list *pvl;

View File

@ -491,4 +491,7 @@ int is_mirror_image_removable(struct logical_volume *mimage_lv, void *baton);
uint64_t find_min_mda_size(struct dm_list *mdas);
char *tags_format_and_copy(struct dm_pool *mem, const struct dm_list *tags);
void check_reappeared_pv(struct volume_group *correct_vg,
struct physical_volume *pv);
#endif