[SOLVED] Help correcting a misnamed LVM

Tomagoes

Member
May 28, 2020
5
0
6
44
I was hoping someone could help me correct an error I made. I am new to proxmox and just added some additional hard drives into my test server. After I added the discs they showed up in proxmox as /dev/sdb/ /dev/sdc/ and so on.

When I went to create a new LVM to utilize the new /dev/sdb disc, I named the LVM sdb which was a mistake since now the sdb is attached to that LVM which didn't create due to it having the same name. Any ideas on how I can detach the sdb disc from the ghost sdb LVM so I can then reassign it to a new LVM (that this time I won't name the same as the disc)?
 

Attachments

  • Screen Shot 2020-06-06 at 3.40.27 PM.png
    Screen Shot 2020-06-06 at 3.40.27 PM.png
    22.8 KB · Views: 8
  • Screen Shot 2020-06-06 at 3.40.40 PM.png
    Screen Shot 2020-06-06 at 3.40.40 PM.png
    16.2 KB · Views: 7
  • Screen Shot 2020-06-06 at 3.40.47 PM.png
    Screen Shot 2020-06-06 at 3.40.47 PM.png
    39.2 KB · Views: 8
  • Screen Shot 2020-06-06 at 3.41.47 PM.png
    Screen Shot 2020-06-06 at 3.41.47 PM.png
    10.8 KB · Views: 9
Last edited:
After doing:
pvcreate --metadatasize 250k -y -ff /dev/sdb
vgcreate vmdata /dev/sdb


I now have vmdata as a LVM group with sdb showing underneath it in the GUI, however I cannot move any my VM volumes over to "vmdata"

EDIT: Going to Datacenter -> Storage-> Add in the UI did the trick. This is solved.
 
Last edited:
i'm having similar issue in that,

sda is where it is installed.

sdb , sdc were not touched yet but may have old partition info.


doing pvcreate --metadatasize 250k -y -ff /dev/sdb
gives = Device /dev/sdb excluded by a filter.

i have no idea why.

Code:
root@stor02 ~ # grep filter /etc/lvm/lvm.conf
        # is used to drive LVM filtering like MD component detection, multipath
        # Configuration option devices/filter.
        # Run vgscan after changing the filter to regenerate the cache.
        global_filter = [ "r|/dev/zd.*|", "r|/dev/mapper/pve-.*|" "r|/dev/mapper/.*-(vm|base)--[0-9]+--disk--[0-9]+|"]
        # filter = [ "a|.*/|" ]
        # filter = [ "r|/dev/cdrom|" ]
        # filter = [ "a|loop|", "r|.*|" ]
        # filter = [ "a|loop|", "r|/dev/hdc|", "a|/dev/ide|", "r|.*|" ]
        # filter = [ "a|^/dev/hda8$|", "r|.*/|" ]
        # filter = [ "a|.*/|" ]
        # Configuration option devices/global_filter.
        # Because devices/filter may be overridden from the command line, it is
        # not suitable for system-wide device filtering, e.g. udev.
        # Use global_filter to hide devices from these LVM system components.
        # The syntax is the same as devices/filter. Devices rejected by
        # global_filter are not opened by LVM.
        # global_filter = [ "a|.*/|" ]
        # This is a quick way of filtering out block devices that are not
        # Configuration option activation/mlock_filter.
        # mlock_filter = [ "locale/locale-archive", "gconv/gconv-modules.cache" ]


pulling hair out trying to fix this ,any ideas?




root@stor02 ~ # pvs
PV VG Fmt Attr PSize PFree
/dev/sda2 vg0 lvm2 a-- <40.00g <9.00g
root@stor02 ~ # vgs
VG #PV #LV #SN Attr VSize VFree
vg0 1 2 0 wz--n- <40.00g <9.00g
root@stor02 ~ # lvs
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
root vg0 -wi-ao---- 25.00g
swap vg0 -wi-ao---- 6.00g
root@stor02 ~ # wipefs -a /dev/sdc1
wipefs: error: /dev/sdc1: probing initialization failed: Device or resource busy
root@stor02 ~ # wipefs -a /dev/sdc
wipefs: error: /dev/sdc: probing initialization failed: Device or resource busy