原因:无法初始化物理量,之前创建的cinder-volumes没有卸载
方法一:
[[email protected] cinder]# lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 20G 0 disk ├─sda1 8:1 0 1G 0 part /boot └─sda2 8:2 0 19G 0 part ├─cl-root 253:0 0 17G 0 lvm / └─cl-swap 253:1 0 2G 0 lvm [SWAP] sdb 8:16 0 20G 0 disk sr0 11:0 1 4.1G 0 rom [[email protected] cinder]# pvcreate -ff -y /dev/sda1 执行命令后重新创建即可 Device /dev/sda1 excluded by a filter. [[email protected] cinder]# pvcreate -ff -y /dev/sdb ‘ Physical volume "/dev/sdb" successfully created. [[email protected] cinder]# vgcreate cinder-volumes /dev/sdb Volume group "cinder-volumes" successfully created
方法二:
按顺序先后卸载逻辑卷、卷组(必要时还要卸载物理卷):
lvremove /dev/cinder-volumes/LogVol00
vgremove cinder-volumes
成功卸载后再重新执行sudo pvcreate /dev/cciss/c0d1p1,不再有错误发生。
接着执行后续动作来创建LVM。
Can't initialize physical volume "/dev/sdb" of volume group "cinder-volumes" without -ff /dev/sdb: physical volume not initialized.
原文地址:https://www.cnblogs.com/daisyyang/p/11005313.html
时间: 2024-10-09 00:16:35