<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<style>
<!--
@font-face
        {font-family:Wingdings}
@font-face
        {font-family:SimSun}
@font-face
        {font-family:"Cambria Math"}
@font-face
        {font-family:Calibri}
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif}
a:link, span.MsoHyperlink
        {color:#0563C1;
        text-decoration:underline}
a:visited, span.MsoHyperlinkFollowed
        {color:#954F72;
        text-decoration:underline}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif}
span.EmailStyle17
        {font-family:"Calibri",sans-serif;
        color:windowtext}
.MsoChpDefault
        {font-family:"Calibri",sans-serif}
@page WordSection1
        {margin:1.0in 1.0in 1.0in 1.0in}
ol
        {margin-bottom:0in}
ul
        {margin-bottom:0in}
-->
</style><style type="text/css" id="owaParaStyle">P {margin-top:0;margin-bottom:0;}</style>
</head>
<body fpstyle="1" ocsi="0" vlink="#954F72" link="#0563C1" lang="EN-US">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">
<div>Hi Liang,</div>
<div><br>
</div>
<div>This patch was covering the scenario when we're trying to create multiple volumes from image at the same time.</div>
<div>In this situation, multiple downloads/convertions would be allowed to start since there would still be conversion space left, but eventually the operation would fail because of the disk being full. This is not caught by any of the "ImageTooBig" or "ImageUnacceptable"
 exceptions.</div>
<div><br>
</div>
<div><font face="Courier New">Could you please help to address one doubt: why image is converted in the same location with image itself? This patch is to create a volume from image, right?
</font></div>
<div>Right, but I'm not aware of the reasoning behind this. However, if the used image is qcow2 then it needs to be converted to raw before being saved to the volume.<br>
</div>
<div><br>
</div>
<div>Please let me know if I can help in any other way.<br>
</div>
<div><br>
</div>
<div>Thanks,</div>
<div>Irina</div>
<div><br>
</div>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div id="divRpF77892" style="direction: ltr;"><font size="2" face="Tahoma" color="#000000"><b>From:</b> Fang, Liang A [liang.a.fang@intel.com]<br>
<b>Sent:</b> Sunday, November 25, 2018 11:44 AM<br>
<b>To:</b> Mihai, Irina<br>
<b>Cc:</b> 'starlingx-discuss@lists.starlingx.io'<br>
<b>Subject:</b> [Starlingx-discuss] [cinder] Analysis of patch c45bb0e for StartlingX upstreaming<br>
</font><br>
</div>
<div></div>
<div>
<div class="WordSection1">
<p class="MsoNormal">Hi Irina</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Code review: <a href="https://review.openstack.org/#/c/618976/" target="_blank" rel="noopener noreferrer">
https://review.openstack.org/#/c/618976/</a></p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">I’m working of upstreaming this patch. Could you please help to address one doubt: why image is converted in the same location with image itself? This patch is to create a volume from image, right?
</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">I take a look of related code, the destination location would be the newly created volume and the source location is configured in cinder.conf, something like:</p>
<p class="MsoNormal">image_conversion_dir = /mnt/d100m/image_conversion_dir</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">I did an experiment, in the latest master branch of cinder upstream repo:</p>
<p class="MsoListParagraph" style="text-indent:-.25in"><span style="">-<span style="font:7.0pt "Times New Roman"">         
</span></span>If image_conversion_dir has no space to store the downloading image, the exception ImageTooBig will be caught in the beginning of _create_from_image_cache_or_download().
</p>
<p class="MsoListParagraph" style="text-indent:-.25in"><span style="">-<span style="font:7.0pt "Times New Roman"">         
</span></span>If has space to store the image, but dest volume size is smaller than image’s virtual size, an exception “ImageUnacceptable” will raised by check_virtual_size.
</p>
<p class="MsoNormal">So it seems no chance to go to the situation this patch aimed to solve.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Could you please help to give more background of this patch? Or if you think this patch is invalid now, please just tell me, I will mark this patch as abandoned.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Thanks</p>
<p class="MsoNormal">Liang</p>
</div>
</div>
</div>
</div>
</body>
</html>