[lvm-devel] lvm_vg_list_lvs API

M. Mohan Kumar mohan at in.ibm.com
Mon Jul 23 11:04:29 UTC 2012


Hello,

I am using lvm_vg_list_lvs API to enumerate the list of LVs in a given
VG. When I create a snapshot of LV, I am seeing in addition to snapshot
LV, there is another lv with name "snapshot0" also returned by this
API. Is it expected behaviour?

Is there any way I can differentiate between this snapshot0 and created
LV snapshot?

For example, I have a LV 'l' initially and then created snapshot of that
with name 'cccc'. But now lvm_vg_list_lvs API returns 3 LVs like this:

 l:size 4194304
 cccc:size 4194304
 snapshot0:size 4194304


But lvdisplay displays only 'l' and 'cccc' in the output.

How do I filter this 'snapshot0' from lvm_vg_list_lvs?




More information about the lvm-devel mailing list