<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
        {mso-style-priority:99;
        mso-style-link:"Текст Знак";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
span.a
        {mso-style-name:"Текст Знак";
        mso-style-priority:99;
        mso-style-link:Текст;
        font-family:"Calibri","sans-serif";}
span.shorttext
        {mso-style-name:short_text;}
span.hps
        {mso-style-name:hps;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:2.0cm 42.5pt 2.0cm 3.0cm;}
div.WordSection1
        {page:WordSection1;}
/* List Definitions */
@list l0
        {mso-list-id:160044449;
        mso-list-type:hybrid;
        mso-list-template-ids:-671084170 68747279 68747289 68747291 68747279 68747289 68747291 68747279 68747289 68747291;}
@list l0:level1
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:71.4pt;
        text-indent:-18.0pt;}
@list l0:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:107.4pt;
        text-indent:-18.0pt;}
@list l0:level3
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:143.4pt;
        text-indent:-9.0pt;}
@list l0:level4
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:179.4pt;
        text-indent:-18.0pt;}
@list l0:level5
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:215.4pt;
        text-indent:-18.0pt;}
@list l0:level6
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:251.4pt;
        text-indent:-9.0pt;}
@list l0:level7
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:287.4pt;
        text-indent:-18.0pt;}
@list l0:level8
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:323.4pt;
        text-indent:-18.0pt;}
@list l0:level9
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:359.4pt;
        text-indent:-9.0pt;}
@list l1
        {mso-list-id:468862693;
        mso-list-type:hybrid;
        mso-list-template-ids:87209172 68747279 68747289 68747291 68747279 68747289 68747291 68747279 68747289 68747291;}
@list l1:level1
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:71.4pt;
        text-indent:-18.0pt;}
@list l1:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:107.4pt;
        text-indent:-18.0pt;}
@list l1:level3
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:143.4pt;
        text-indent:-9.0pt;}
@list l1:level4
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:179.4pt;
        text-indent:-18.0pt;}
@list l1:level5
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:215.4pt;
        text-indent:-18.0pt;}
@list l1:level6
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:251.4pt;
        text-indent:-9.0pt;}
@list l1:level7
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:287.4pt;
        text-indent:-18.0pt;}
@list l1:level8
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:323.4pt;
        text-indent:-18.0pt;}
@list l1:level9
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:359.4pt;
        text-indent:-9.0pt;}
@list l2
        {mso-list-id:1086684354;
        mso-list-type:hybrid;
        mso-list-template-ids:-552293766 68747279 68747289 68747291 68747279 68747289 68747291 68747279 68747289 68747291;}
@list l2:level1
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;}
@list l2:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;}
@list l2:level3
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l2:level4
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;}
@list l2:level5
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;}
@list l2:level6
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l2:level7
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;}
@list l2:level8
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;}
@list l2:level9
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l3
        {mso-list-id:1446078946;
        mso-list-type:hybrid;
        mso-list-template-ids:-1759495836 68747279 68747289 68747291 68747279 68747289 68747291 68747279 68747289 68747291;}
@list l3:level1
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:71.4pt;
        text-indent:-18.0pt;}
@list l3:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:107.4pt;
        text-indent:-18.0pt;}
@list l3:level3
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:143.4pt;
        text-indent:-9.0pt;}
@list l3:level4
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:179.4pt;
        text-indent:-18.0pt;}
@list l3:level5
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:215.4pt;
        text-indent:-18.0pt;}
@list l3:level6
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:251.4pt;
        text-indent:-9.0pt;}
@list l3:level7
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:287.4pt;
        text-indent:-18.0pt;}
@list l3:level8
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:323.4pt;
        text-indent:-18.0pt;}
@list l3:level9
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        margin-left:359.4pt;
        text-indent:-9.0pt;}
ol
        {margin-bottom:0cm;}
ul
        {margin-bottom:0cm;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="RU" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoPlainText"><span lang="EN-US" style="mso-fareast-language:RU">-----Original Message-----<br>
From: Richard W.M. Jones [mailto:rjones@redhat.com] <br>
Sent: Friday, January 17, 2014 4:40 PM<br>
To: </span><span style="mso-fareast-language:RU">Исаев</span><span style="mso-fareast-language:RU">
</span><span style="mso-fareast-language:RU">Виталий</span><span style="mso-fareast-language:RU">
</span><span style="mso-fareast-language:RU">Анатольевич</span><span lang="EN-US" style="mso-fareast-language:RU"><br>
Cc: libguestfs@redhat.com<br>
Subject: Re: [Libguestfs] LVM mounting issue</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText">On Fri, Jan 17, 2014 at 09:45:34AM +0000, Исаев Виталий Анатольевич wrote:<o:p></o:p></p>
<p class="MsoPlainText">> Be sure, that “unknown device” was not written by me :)<o:p></o:p></p>
<p class="MsoPlainText">> <o:p></o:p></p>
<p class="MsoPlainText">> I use libguestfs 1.16.34:<o:p></o:p></p>
<p class="MsoPlainText">> [root@rhevh1 ~]# rpm -qa | grep guest<o:p></o:p></p>
<p class="MsoPlainText">> libguestfs-1.16.34-2.el6.x86_64<o:p></o:p></p>
<p class="MsoPlainText">> libguestfs-winsupport-1.0-7.el6.x86_64<o:p></o:p></p>
<p class="MsoPlainText">> python-libguestfs-1.16.34-2.el6.x86_64<o:p></o:p></p>
<p class="MsoPlainText">> libguestfs-tools-c-1.16.34-2.el6.x86_64<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">This is a bug.  I have filed a bug about this issue:<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText"><a href="https://bugzilla.redhat.com/show_bug.cgi?id=1054761"><span style="color:windowtext;text-decoration:none">https://bugzilla.redhat.com/show_bug.cgi?id=1054761</span></a><o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">However it does indicate that you are not presenting all physical volumes to libguestfs, which means you're probably not adding every device that belongs to the guest.  That's going to cause other problems for you.<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">> Full trace of the guestfish session is attached to this message.<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">> ><fs> add-ro /dev/dm-40<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">Based on your reply in bug 1053684 I still don't know which is the correct device name to open, but it's obviously not /dev/dm-40.  I spent quite a long time yesterday trying to get someone from the oVirt team to help out, but without
 success so far.  I will keep you informed on bug 1053684.<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">Rich.<o:p></o:p></p>
<p class="MsoPlainText"><o:p> </o:p></p>
<p class="MsoPlainText">--<o:p></o:p></p>
<p class="MsoPlainText">Richard Jones, Virtualization Group, Red Hat <a href="http://people.redhat.com/~rjones">
<span style="color:windowtext;text-decoration:none">http://people.redhat.com/~rjones</span></a> Read my programming blog:
<a href="http://rwmj.wordpress.com"><span style="color:windowtext;text-decoration:none">http://rwmj.wordpress.com</span></a> Fedora now supports 80 OCaml packages (the OPEN alternative to F#)<o:p></o:p></p>
<p class="MsoPlainText"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoPlainText" style="margin-left:35.4pt;line-height:115%"><span lang="EN-US" style="color:black">Rich, thank you for your patience and advices. It seems for me that we mixed two different problems:<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l1 level1 lfo1">
<![if !supportLists]><span lang="EN-US" style="color:black"><span style="mso-list:Ignore">1.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US" style="color:black">Problems while accessing ANY of thin provisioned (qcow2) disk with libguestfs 1.16.34 on the hypervisor (it’s discussed in
</span><span lang="EN-US">bug 1053684);<span style="color:black"><o:p></o:p></span></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l1 level1 lfo1">
<![if !supportLists]><span lang="EN-US" style="color:black"><span style="mso-list:Ignore">2.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US">Problems while mounting SOME of disk images
<span style="color:black">with libguestfs 1.16.34 (strictly speaking there are only 2 VMs with such problem of 17 ones I have on my cluster);<o:p></o:p></span></span></p>
<p class="MsoPlainText" style="line-height:115%"><span lang="EN-US" style="color:black"><o:p> </o:p></span></p>
<p class="MsoPlainText" style="margin-left:35.4pt;line-height:115%"><span lang="EN-US" style="color:black">However, both of the mentioned issues require the correct disk images paths to be provided. But as you say that /dev/dm-XX devices are obviously not suitable
 for usage with libguestfs, I would ask you for a last thing – to check all my steps on the way to define and access the disk image. May be there is an error in my logic.<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l3 level1 lfo4">
<![if !supportLists]><span lang="EN-US" style="color:black"><span style="mso-list:Ignore">1.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US" style="color:black">I want to inspect VM’s disk image. There are two disk images belonging to this VM (look at the “vm” xml file attached);<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l3 level1 lfo4">
<![if !supportLists]><span lang="EN-US" style="color:black"><span style="mso-list:Ignore">2.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US" style="color:black">I determine the disk_image_id of the VM’s bootable disk (look at the image_id node in “disks” xml file attached);<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l3 level1 lfo4">
<![if !supportLists]><span lang="EN-US" style="color:black"><span style="mso-list:Ignore">3.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US" style="color:black">Now I go to the RHEV-H to look for the disk image itself:<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;line-height:115%"><span lang="EN-US" style="font-family:"Courier New"">[root@rhevh1 /]# find / -name cc6e4400-7c98-4170-9075-5f5790dfcff3<br>
/dev/1a9aa971-f81f-4ad8-932f-607034c924fc/cc6e4400-7c98-4170-9075-5f5790dfcff3<br>
/var/lib/stateless/writable/rhev/data-center/mnt/blockSD/1a9aa971-f81f-4ad8-932f-607034c924fc/images/8a3e02de-d8ab-4357-ba8c-490f3ba3e85c/cc6e4400-7c98-4170-9075-5f5790dfcff3<br>
/rhev/data-center/mnt/blockSD/1a9aa971-f81f-4ad8-932f-607034c924fc/images/8a3e02de-d8ab-4357-ba8c-490f3ba3e85c/cc6e4400-7c98-4170-9075-5f5790dfcff3</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l3 level1 lfo4">
<![if !supportLists]><span lang="EN-US"><span style="mso-list:Ignore">4.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US">Note that all these files are symbolic links:</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;line-height:115%"><span lang="EN-US" style="font-family:"Courier New"">[root@rhevh1 /]# find / -name cc6e4400-7c98-4170-9075-5f5790dfcff3 -exec readlink -f {} \;<br>
/dev/dm-40<br>
/dev/dm-40<br>
/dev/dm-40</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;line-height:115%;mso-list:l3 level1 lfo4">
<![if !supportLists]><span lang="EN-US"><span style="mso-list:Ignore">5.<span style="font:7.0pt "Times New Roman"">      
</span></span></span><![endif]><span lang="EN-US">One more symbolic link is in /dev/mapper:<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt"><span lang="EN-US" style="font-family:"Courier New"">[root@rhevh1 /]# ls -l /dev/mapper/1a9aa971--f81f--4ad8--932f--607034c924fc-cc6e4400--7c98--4170--9075--5f5790dfcff3
<br>
lrwxrwxrwx. 1 root root 8 2013-11-20 10:59 /dev/mapper/1a9aa971--f81f--4ad8--932f--607034c924fc-cc6e4400--7c98--4170--9075--5f5790dfcff3 -> ../dm-40</span><span lang="EN-US"><o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:71.4pt;text-indent:-18.0pt;mso-list:l3 level1 lfo4">
<![if !supportLists]><span class="hps"><span lang="EN-US"><span style="mso-list:Ignore">6.<span style="font:7.0pt "Times New Roman"">      
</span></span></span></span><![endif]><span lang="EN-US">So I have no choice and I try to open /dev/dm-40 with libguestfs or guestfish.
</span><span class="hps"><span lang="EN">What's next,</span></span><span class="shorttext"><span lang="EN">
</span></span><span class="hps"><span lang="EN">you already know. </span></span><span class="hps"><span lang="EN-US"><o:p></o:p></span></span></p>
<p class="MsoPlainText"><span class="hps"><span lang="EN"><o:p> </o:p></span></span></p>
<p class="MsoPlainText" style="margin-left:35.4pt"><span class="hps"><span lang="EN">I apologize for spending your time again, but please</span></span><span class="hps"><span lang="EN">
</span></span><span class="hps"><span lang="EN-US">evaluate </span></span><span class="hps"><span lang="EN">the proposed method of disk image definition.<o:p></o:p></span></span></p>
<p class="MsoPlainText" style="margin-left:35.4pt"><span class="hps"><span lang="EN">Sincerely,<o:p></o:p></span></span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span class="hps"><span lang="EN"></span></span><span lang="EN-US" style="font-size:10.0pt;mso-fareast-language:RU">Vitaly Isaev<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-US" style="font-size:10.0pt;color:gray;mso-fareast-language:RU">Software engineer<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-US" style="font-size:10.0pt;color:gray;mso-fareast-language:RU">Information security department<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:35.4pt"><span lang="EN-US" style="font-size:10.0pt;color:gray;mso-fareast-language:RU">Fintech JSC, Moscow, Russia<o:p></o:p></span></p>
<p class="MsoPlainText" style="margin-left:35.4pt"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US" style="color:black"><o:p> </o:p></span></p>
</div>
</body>
</html>