[ovirt-users] List disk images residing on specific lun

Gadi Ickowicz gickowic at redhat.com
Sun Apr 13 13:13:44 UTC 2014


Hi Amedeo,

Although I have not used this before, I found this answer[1] to a similar question online which may help, it describes the usage of pvdisplay, vgdisplay and lvdisplay. These may provide the information you need regarding where each LV is. 
To match the lv to the actual disk you need to know the image ID that the LV (volume) is part of, visible in the lv_tags field (IU_<image_uuid>) using:
lvs -o+lv_tags


Even with this, I do not know if you can recover the storage domain itself...

[1]http://serverfault.com/questions/461385/how-to-find-the-physical-volumes-that-hold-a-logical-volume-in-lvm



Gadi Ickowicz

----- Original Message -----
From: "Amedeo Salvati" <amedeo at oscert.net>
To: "Gadi Ickowicz" <gickowic at redhat.com>
Cc: "Meital Bourvine" <mbourvin at redhat.com>, users at ovirt.org
Sent: Sunday, April 13, 2014 3:42:35 PM
Subject: Re: [ovirt-users] List disk images residing on specific lun

Il 13/04/2014 14:15, Gadi Ickowicz ha scritto:
> Hi Amedeo,
>
> Was the LUN that was lost a separate storage domain? if it was, you can list all the disks in the system and then filter the list for disks on that storage domain. for example, in python sdk:
> disks = api.disks.list()
> [disk for disk in disks if disk.get_storage_domains().get_storage_domain().get_id() == fc_storage_domain_id]
>
> Thanks,
> Gadi Ickowicz
>
> ----- Original Message -----
> From: "Amedeo Salvati" <amedeo at oscert.net>
> To: "Meital Bourvine" <mbourvin at redhat.com>
> Cc: users at ovirt.org
> Sent: Sunday, April 13, 2014 3:05:37 PM
> Subject: Re: [ovirt-users] List disk images residing on specific lun
>
> Il 13/04/2014 12:37, Meital Bourvine ha scritto:
>> Hi Amedeo,
>>
>> I don't think that it's possible.
>> But if your storage domain contains only 1 FC lun, then listing the disks on this storage domain will provide you the info.
>>
>> ----- Original Message -----
>>> From: "Amedeo Salvati" <amedeo at oscert.net>
>>> To: users at ovirt.org
>>> Sent: Sunday, April 13, 2014 1:23:13 PM
>>> Subject: [ovirt-users] List disk images residing on specific lun
>>>
>>> Hello,
>>>
>>> does anyone know if it's possible, using ovirt-shell or api, to list
>>> every disk image residing on specific FC LUN?
>>>
>>> best regards
>>> Amedeo Salvati
>>> _______________________________________________
>>> Users mailing list
>>> Users at ovirt.org
>>> http://lists.ovirt.org/mailman/listinfo/users
>>>
> Hi Meital and all,
>
> unfortunately we have several luns, but we've lost one of them (and it's
> not possible to recover it from the box), so we're looking to know what
> images are residing on that lun due to remove those images from
> db/engine gui...
>
> using lvm command on hypervisor node it's possible to match lv name
> still alive, with some id present on engine db or by ovirt-shell cmd
> like "list disk --show-all" ?
>
> thanks in advance
> a
> _______________________________________________
> Users mailing list
> Users at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/users
>

Hi Gadi,

no on that DC we have two storagedomains, each one of them has 2 LUNs, 
(total 4 LUNs on two SD), and we have lost only one of them, so we have 
one SD consistent and one SD broken without one lun.

To better understand what was happened, the lost LUN was effectively not 
lost, but was inadvertently overwrite during new hypervisor instalation, 
so it was not lost, and is still visible to hypervisor, but it's content 
was wiped out / overwritten.

do you think that it's possible to match, by lvm command on hypervisor, 
lv name still alive, with some id present on engine db or by ovirt-shell 
cmd?

thanks in advance
a



More information about the Users mailing list