![如何将意外断开的 PV 放回到 LVM VG 中?](https://linux22.com/image/121700/%E5%A6%82%E4%BD%95%E5%B0%86%E6%84%8F%E5%A4%96%E6%96%AD%E5%BC%80%E7%9A%84%20PV%20%E6%94%BE%E5%9B%9E%E5%88%B0%20LVM%20VG%20%E4%B8%AD%EF%BC%9F.png)
我这里有一个VG。由于连接问题,其中一个 PV 意外断开连接。解决问题后,我重新扫描了磁盘,现在我想将其放回 VG,而不需要重新启动。
Apvscan
找到了所有这些,但显示丢失磁盘的错误:
WARNING: Device for PV YlTqFN-OZBT-vdCG-PhqN-B6fn-FzF9-Hw2ZU1 not found or rejected by a filter.
/dev/myvg/mylv: read failed after 0 of 4096 at 0: Input/output error
vgchange -ay
仅显示错误消息:
# vgchange -ay WARNING: Device for PV YlTqFN-OZBT-vdCG-PhqN-B6fn-FzF9-Hw2ZU1 not found or rejected by a filter. Refusing activation of partial LV yuc/mylv. Use '--activationmode partial' to override.
那么,我怎样才能把它放回 VG 呢?
答案1
尝试vgextend --restoremissing $VG