磁盘扩容问题

磁盘扩容问题(Device for PV xxxx-xxxxx-xxxx-xxxxx not found or rejected by a filter)

查看新加磁盘:lsblk

计算机生成了可选文字:
[ root@localhost 、 ] # Isblk 
11 : 0 
252 : 0 
252 : 1 
252 : 2 
253 : 0 
253 : 1 
252 : 16 
MAJ :MIN RM 
SIZE 
4 . 2G 
60G 
IG 
49G 
44G 
5G 
50G 
RO 
TYPE MOUNTPOINT 
0 
rom 
0 disk 
0 part /boot 
0 
part 
0 Ivm / 
0 Ivm SWAP) 
0 dzsk 
NAME 
s 
vda 
vdal 
vda2 
centos 
- root 
centos—swa 
vdb 
1 
0 
0 
0 
0 
0 
0

 

新建分区:fdisk /dev/vdb

计算机生成了可选文字:
[ root@localhost 、 ] # fdisk dev vdb 
Welcome to fdlsk (utll-llnux 2 . 23 . 2 ). 
Changes w111 remain In memory only , until you dec Ide to write them. 
Be careful before using the wrzte command. 
default 104857599 ) : 
Command 《 m for help) n 
Part It 10n type : 
p prunary 《 0 prunary, 0 extended , 
e extended 
Select ( default p ): 
UsIng default response p 
Part It 10n number 《 1 . 4 , default 1 ): 
4 f ree ) 
First sector 《 2048 . 104857599 , default 2048 ) : 
UsIng default value 2048 
Last sector, +sectors or +size(K,M,GY 《 2048 . 104857599 , 
UsIng default value 104857599 
Part It 10n 1 Of type Lznux and Of S IZ e 50 G 1B is set 
Command ( m for help) t 
Selected part It 10n 1 
Hex code ( type L to Ilst a11 codes ) : 8e 
Changed type Of part It 10n 'Linux' to 'Linux LVM 
Command 《 m for help) p 
Disk /dev/vdb : 53 . 7 GB, 53687091200 bytes , 104857600 sectors 
sectors of 1 * 512 = 512 bytes 
Unzts 
Sector s e (logical/physical) : 512 bytes / 512 bytes 
I/O s e (mInunum/optunal) : 512 bytes / 512 bytes 
D IS k label type : dos 
Dzsk Ident If zer : 0xd3930f55 
System 
Lznux LVM 
Id 
8e 
Bloc ks 
52427776 
DevIce Boot 
dev/vdbl 
Start 
2048 
End 
104857599 
Command 《 m for help) : w 
The part It 10n table has been altered ! 
Call Ing ioctl 《 ) to re- read part It 10n table. 
SyncIng disks.

 

vgs查看出现未知卷组

计算机生成了可选文字:
troot@localhost 、 ] # vgs 
WARNING: DevIce for PV WakRUL-11Up-HUz5-FkIo-OxhI-FfzY 
WARNING: DevIce for PV Ø4zQP8-mØ10-yBPn 
WARNING: DevIce for PV H13hz9-32SC-qyNB-trhY-GdKC-HAoS 
WARNING: DevIce for PV nsaGgn-R7Xz-11gT-8bxe-HQBf-QFcb-fdF7DN 
#PV #LV #SN Attr VS zz e VFree 
-DFHK- 
. gcveQ9 
w2yk-en4D-qrxzu6 
-qVAwJh 
not 
not 
not 
not 
found 
found 
found 
found 
or 
or 
or 
or 
ected 
ected 
ected 
ected 
by 
by 
by 
by 
a filter. 
a filter. 
a filter. 
a filter. 
centos 
rhel 
1 2 0 wz . . n . < 49 . 00 
5 2 0 wz-pn- 159 . 49g 
0 
0

 

查看物理卷组:pvdisplay

计算机生成了可选文字:
troot@localhost 、 ] # pvdisplay 
Physical volume 
not 
not 
not 
not 
found 
found 
found 
found 
or 
or 
or 
or 
ected 
by a filter. 
ected 
by a filter. 
ected 
by a filter. 
ected 
by a filter. 
/dev/vda2 
centos 
< 49 . 00 G 1B / not usable 3 . 00 MIB 
yes (but full ) 
4 . 00 MIB 
12543 
0 
12543 
kth80g-yw4n-53ZL-UmsP-FTvu-aOBd-51qzwh 
PV WakRUL-11Up-HUz5-FkIo-OxhI-FfzY 
. gcveQ9 
PV Ø4zQP8-mØIO-yBPn-DFHK-w2yk-en4D-qrx1u6 
PV H13hz9-32SC-qyNB-trhY-GdKC-HAoS 
-qVAwJh 
PV nsaGgn-R7Xz-11gT-8bxe-HQBf-QFcb-fdF7DN 
Lunknown) 
rhel 
49 . 51 G 1B / not usable 
yes (but full ) 
4 . 00 MIB 
12674 
0 
12674 
PV Name 
VG Name 
PV S Iz e 
Allocatable 
PE S Iz e 
Total PE 
Free PE 
Allocated PE 
PV UUID 
WARNING: DevIce for 
WARNING: DevIce for 
WARNING: DevIce for 
WARNING: DevIce for 
3 . 00 
MIB 
Physical 
PV Name 
VG Name 
PV S zz e 
Allocatable 
PE S zz e 
Total PE 
Free PE 
Allocated PE 
PV UUID 
Physical 
PV Name 
VG Name 
PV S Iz e 
Allocatable 
Volume 
Volume 
WakRUL-11Up-HUz5-FkIo-OxhI-FfzY-gcveQ9 
Lunknown) 
rhel 
< 20 . 00 G 1B / not usable 3 . 00 MIB 
yes (but full ) 
4 . 00 MIB 
5119 
0 
5119 
E)4zQP8-m€)10-yBPn-DFHK-w2yk-en4D-qrx1u6 
PE S Iz e 
Total PE 
Free PE 
Allocated 
PV UUID 
PE

 

出现告警:

WARNING: Device for PV WakRUL-liUp-HUz5-FkIo-OxhI-FfzY-gcveQ9 not found or rejected by a filte.

 

解决方法

vgreduce从卷组中强制删除物理卷

vgreduce --removemissing --force rhel

计算机生成了可选文字:
troot@localhost 、 ] # vgreduce 
- removem ISS 
. f 0 r c e rhel 
WARNING: 
WARNING: 
WARNING: 
WARNING: 
WARNING: 
Logical 
WARNING: 
Logical 
DevIce for PV WakRUL-11Up-HUz5-FkIo-OxhI-FfzY-gcVeQ9 
DevIce for PV Ø4zQP8-mØzo-yBPn-DFHK-w2yk-en4D-qrx1u6 
Device for PV H13hz9-32SC-qyNB-trhY-GdKC-HAoS-qVAwJh 
DevIce for PV nsaGgn-R7Xz-11gT-8bxe-HQBf-QFcb-fdF7DN 
Removing part 1a1 LV rhel/swap . 
Volume " swap SUCCeSSfLllly removed 
Removing part 1a1 LV rhel/ root . 
Volume " root " successfully removed 
not 
not 
not 
not 
found 
found 
found 
found 
or 
or 
or 
or 
ected 
ected 
ected 
ected 
by 
by 
by 
by 
a filter. 
a filter. 
a filter. 
a filter. 
Wrote out consistent Volume group rhe1 .

再次查看物理卷组rhel依然存在

计算机生成了可选文字:
[ root@localhost 、 ] # pvdisplay 
Physical 
PV Name 
VG Name 
PV S zz e 
Allocatable 
PE S Iz e 
Total PE 
Free PE 
Allocated PE 
PV UUID 
Physical 
PV Name 
VG Name 
PV S Iz e 
Allocatable 
Volume 
Volume 
/dev/vda2 
centos 
< 49 . 00 G 1B / not usable 3 . 00 MIB 
yes (but full ) 
4 . 00 MIB 
12543 
0 
12543 
kth80g-yw4n-53ZL-UmsP-FTvu-aOBd-51qzwh 
/dev/vdbl 
< 50 . 00 G 1B / not usable 3 . 00 MIB 
yes 
4 . 00 MIB 
12799 
12799 
0 
9HqkCL-JBTH-f 〕 GJ-Vqq3-nKaQ-QfJ0-n1CZ5H 
PE S Iz e 
Total PE 
Free PE 
Allocated 
PV UUID 
PE

 

移除卷组成功

vgremove rhel

计算机生成了可选文字:
[ root@localhost 、 ] # vgremove rhel 
Volume group " rhel ' 
successfully removed

 

再次查看物理卷组恢复正常

计算机生成了可选文字:
[ root@localhost 、 ] # pvdisplay 
Physical volume 
/dev/vda2 
centos 
< 49 . 00 G 1B / not usable 3 . 00 MIB 
yes (but full ) 
4 . 00 MIB 
12543 
0 
12543 
kth80g-yw4n-53ZL-UmsP-FTvu-aOBd-51qzwh 
new physical Volume Of " < 50 . 00 G 1B ' 
Volume 
/dev/vdbl 
< 50 . 00 G 1B 
0 
0 
0 
0 
9HqkCL-JBTH-f 〕 GJ-Vqq3-nKaQ-QfJo-n1CZ5H 
PV Name 
VG Name 
PV S zz e 
Allocatable 
PE S Iz e 
Total PE 
Free PE 
Allocated PE 
PV UUID 
" /dev/vdbl" IS a 
NEW Physical 
PV Name 
VG Name 
PV S zz e 
Allocatable 
PE S Iz e 
Total PE 
Free PE 
Allocated 
PV UUID 
PE

 

posted @ 2023-02-07 15:02  金·天  阅读(253)  评论(0编辑  收藏  举报