mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
b21a8412c4
All the LVM commands are run in mode without lvmetad use (since lvmetad can't handle duplicates). When we're finished with vgimportclone, we need to notify lvmetad about changes. Before this patch (/dev/sda and /dev/sdb contains a copy VG called "vg"): $ vgimportclone --basevgname vg_snap /dev/sdb WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! WARNING: Activation disabled. No device-mapper interaction will be attempted. WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! Physical volume "/tmp/snap.zcJ8LCmj/vgimport0" changed 1 physical volume changed / 0 physical volumes not changed WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! WARNING: Activation disabled. No device-mapper interaction will be attempted. WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! Volume group "vg" successfully changed WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! Volume group "vg" successfully renamed to "vg_snap" Reading all physical volumes. This may take a while... Found volume group "vg" using metadata type lvm2 Found volume group "fedora" using metadata type lvm2 $ vgs VG #PV #LV #SN Attr VSize VFree fedora 1 2 0 wz--n- 9.50g 0 vg 1 1 0 wz--n- 124.00m 120.00m (...lvmetad doesn't see the new "vg_snap"!) With this patch applied: $ vgimportclone --basevgname vg_snap /dev/sdb ... WARNING: lvmetad is running but disabled. Restart lvmetad before enabling it! Volume group "vg" successfully renamed to "vg_snap" Notifying lvmetad about changes since it was disabled temporarily. Reading all physical volumes. This may take a while... Found volume group "vg_snap" using metadata type lvm2 Found volume group "fedora" using metadata type lvm2 Found volume group "vg" using metadata type lvm2 $ vgs VG #PV #LV #SN Attr VSize VFree fedora 1 2 0 wz--n- 9.50g 0 vg 1 1 0 wz--n- 124.00m 120.00m vg_snap 1 1 0 wz--n- 124.00m 120.00m The "restart lvmetad before enabling it" message is a bit misleading here - we should probably suppress this one, but we can't suppress warning messages selectively at the moment and we don't want to lose other warning/error messages printed... |
||
---|---|---|
.. | ||
lvm2create_initrd | ||
.gitignore | ||
blk_availability_init_red_hat.in | ||
blk_availability_systemd_red_hat.service.in | ||
blkdeactivate.sh.in | ||
clvmd_fix_conf.sh | ||
clvmd_init_red_hat.in | ||
cmirrord_init_red_hat.in | ||
dm_event_systemd_red_hat.service.in | ||
dm_event_systemd_red_hat.socket.in | ||
fsadm.sh | ||
gdbinit | ||
lvm2_activation_generator_systemd_red_hat.c | ||
lvm2_cluster_activation_red_hat.sh.in | ||
lvm2_cluster_activation_systemd_red_hat.service.in | ||
lvm2_clvmd_systemd_red_hat.service.in | ||
lvm2_cmirrord_systemd_red_hat.service.in | ||
lvm2_lvmetad_init_red_hat.in | ||
lvm2_lvmetad_systemd_red_hat.service.in | ||
lvm2_lvmetad_systemd_red_hat.socket.in | ||
lvm2_monitoring_init_red_hat.in | ||
lvm2_monitoring_init_rhel4 | ||
lvm2_monitoring_systemd_red_hat.service.in | ||
lvm2_pvscan_systemd_red_hat@.service.in | ||
lvm2_tmpfiles_red_hat.conf.in | ||
lvmconf_lockingtype2.sh | ||
lvmconf.sh | ||
lvmdump.sh | ||
Makefile.in | ||
relpath.awk | ||
vg_convert | ||
vgimportclone.sh | ||
VolumeGroup.ocf |