<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">On Saturday 06 June 2015 12:09 AM,
      Patrick Schleizer wrote:<br>
    </div>
    <blockquote cite="mid:5571ECEF.8050405@riseup.net" type="cite">
      <blockquote type="cite" style="font-style: italic; color:
        #000000;">
        <pre wrap=""><span class="moz-txt-citetags">> </span>When you add/remove <b class="moz-txt-star"><span class="moz-txt-tag">*</span>partitions<span class="moz-txt-tag">*</span></b>, yes. That's understood.
</pre>
      </blockquote>
      <pre wrap="">Can you please elaborate on this?

What would be the right course of action, so we don't have to hardcode
"sleep 2"? Is there any command that would wait until kpartx is ready?
Or that would tell us whether it's safe now or not to use kpartx?
</pre>
    </blockquote>
    <br>
    It is a timing problem. And the timing can greatly vary based on the
    amount of task your machine is performing at that time.<br>
    <br>
    Given the current limitations, the wise option I thought was to make
    kpartx try a little longer. For this, I've submitted a patch
    upstream increasing kpartx's retry from 3 seconds to 5 seconds. Why
    5 seconds ? I have no logical reasoning.<br>
    <br>
    If it gets accepted upstream, it will show up in the next release.
    Meanwhile, if you want to test it, you can pick the patch from the
    upstream mailing list and try.
    <a class="moz-txt-link-freetext" href="https://www.redhat.com/archives/dm-devel/2015-May/msg00087.html">https://www.redhat.com/archives/dm-devel/2015-May/msg00087.html</a><br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Ritesh Raj Sarraf | <a class="moz-txt-link-freetext" href="http://people.debian.org/~rrs">http://people.debian.org/~rrs</a>
Debian - The Universal Operating System
</pre>
  </body>
</html>