Problem with LVM over iSCSI

lyoleek

New Member
Mar 20, 2024
3
0
1
Hi.
I have a Proxmox VE cluster of 3 nodes. It worked perfectly well for quite a while. But the other day I accidentally removed an LVM that had been created on iSCSI. And now I cannot get it back. I still have an iSCSI storage, so can see my iSCSI target. But when I try to add an LVM via GUI and choose my Base storage, I do not see any Base volume in the corresponding drop list.
I have already looked through a number of topics like "proxmox iscsi cannot see lun" but unfortunately with no luck. So how can I get my LVM back?
Code:
# pveversion
pve-manager/8.4.1/2a5fa54a8503f96d (running kernel: 6.8.12-10-pve)
Code:
# iscsiadm -m session
tcp: [1] 10.3.16.90:3260,1 iqn.2000-01.com.synology:Syn814RP.Target-1.5db9ac4dc96 (non-flash)
Code:
#lsscsi
[0:0:0:0]    cd/dvd  Optiarc  DVD RW AD-7760H  1.41  /dev/sr0
[2:2:0:0]    disk    LSI      RAID SAS 6G 0/1  2.12  /dev/sda
[3:0:0:1]    disk    SYNOLOGY Storage          4.0   /dev/sdb
[4:0:0:1]    disk    SYNOLOGY iSCSI Storage    4.0   /dev/sdc
Code:
# lsscsi
[0:0:0:0]    cd/dvd  Optiarc  DVD RW AD-7760H  1.41  /dev/sr0
[2:2:0:0]    disk    LSI      RAID SAS 6G 0/1  2.12  /dev/sda
[3:0:0:1]    disk    SYNOLOGY Storage          4.0   /dev/sdb
[4:0:0:1]    disk    SYNOLOGY iSCSI Storage    4.0   /dev/sdc
root@pve0:/etc/pve# lsblk
NAME                      MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTS
sda                         8:0    0 278.9G  0 disk
├─sda1                      8:1    0  1007K  0 part
├─sda2                      8:2    0     1G  0 part
└─sda3                      8:3    0 277.9G  0 part
  ├─pve-swap              252:0    0     8G  0 lvm  [SWAP]
  ├─pve-root              252:1    0  79.5G  0 lvm  /
  ├─pve-data_tmeta        252:2    0   1.7G  0 lvm 
  │ └─pve-data            252:4    0 170.9G  0 lvm 
  └─pve-data_tdata        252:3    0 170.9G  0 lvm 
    └─pve-data            252:4    0 170.9G  0 lvm 
sdb                         8:16   0   5.9T  0 disk
├─group1-vm--108--disk--0 252:5    0     4M  0 lvm 
├─group1-vm--108--disk--1 252:6    0   320G  0 lvm 
├─group1-vm--108--disk--2 252:7    0     4M  0 lvm 
├─group1-vm--109--disk--0 252:8    0   500G  0 lvm 
├─group1-vm--112--disk--0 252:9    0     1T  0 lvm 
├─group1-vm--113--disk--0 252:10   0    40G  0 lvm 
├─group1-vm--114--disk--0 252:11   0    16G  0 lvm 
├─group1-vm--100--disk--0 252:12   0   256G  0 lvm 
├─group1-vm--103--disk--0 252:13   0    64G  0 lvm 
├─group1-vm--106--disk--0 252:14   0   240G  0 lvm 
├─group1-vm--104--disk--0 252:15   0   160G  0 lvm 
├─group1-vm--107--disk--0 252:16   0   160G  0 lvm 
├─group1-vm--101--disk--0 252:17   0    64G  0 lvm 
├─group1-vm--115--disk--0 252:18   0     4M  0 lvm 
├─group1-vm--115--disk--1 252:19   0   320G  0 lvm 
└─group1-vm--115--disk--2 252:20   0     4M  0 lvm 
sdc                         8:32   0   5.9T  0 disk
sr0                        11:0    1  1024M  0 rom
As I can see, /dev/sdb contains all my VM-disks. But I cannot put my finger on what I should do to see all of them in the GUI. Any help will be appreciated.
 
Adding LVM via GUI means actually creating an LVM structure. You can't do it as you don't have available empty disks - there is already an LVM there.
You need to create an entry in your /etc/pve/storage.cfg that points to your existing VG group.

First, examine your LVM structure:
pvs
vgs
lvs

Next, create the storage pool:
pvesm add lvm [lvm_pool_name] --base [iscsi_pool] --vgname [group1]

Examine the configuration of one of your VM to learn what the LVM pool should be called: qm config [vmid]

Good luck



Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
 
Last edited:
Adding LVM via GUI means actually creating an LVM structure. You can't do it as you don't have available empty disks - there is already an LVM there.
You need to create an entry in your /etc/pve/storage.cfg that points to your existing VG group.

First, examine your LVM structure:
pvs
vgs
lvs

Next, create the storage pool:
pvesm add lvm [lvm_pool_name] --base [iscsi_pool] --vgname [group1]

Examine the configuration of one of your VM to learn what the LVM pool should be called: qm config [vmid]

Good luck



Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
Thanks for your response. Yes, it does make sense. I will try to follow your advice. Thanks again and have a good day.