<div dir="ltr">Hi, thanks for reply first!<div><br></div><div>After I tried shelve instance, yes it really release GPU resources.</div><div>But as Dinesh said, can't unshelve this instance if all GPUs occupied.</div><div><br></div><div>Before known about shelve instance, I have do few approach.</div><div><br></div><div>One is using "resize" the instance's flavor to non-GPU flavor, but can't do this if all GPUs occupied.</div><div><br></div><div>Another one is like Jay's recommend is that create instance as volume, and delete instance but keep volume if this VM not going to use GPU.</div><div>Then re-create instance with previous volume and non-GPU flavor.</div><div>And yes, this approach have IP address problem that may cause application atypical.</div><div><br></div><div>I'll try how to make my application not to rely on a persistent IP.</div><div><br></div><div>Thanks,</div><div>Eddie.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-07-05 19:36 GMT+08:00 Jay Pipes <span dir="ltr"><<a href="mailto:jaypipes@gmail.com" target="_blank">jaypipes@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 07/05/2017 04:18 AM, Eddie Yen wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi everyone,<br>
<br>
I'm using OpenStack Mitaka (which deployed from Fuel 9.2) and doing GPU things.<br>
<br>
I got a problem is I need to delete current instance which contains GPU to release device if I want assign GPU to another new instance temperately.<br>
<br>
I'll got "No valid host was found" if I creating new instance contains GPU flavor without delete present instance, even the instance is shutdown.<br>
<br>
Is there any way that I just shutdown the instance rather than delete it to release GPU device?<br>
</blockquote>
<br></span>
As Dinesh mentioned you *can* use shelve for this, but frankly, I think the shelve API leads to more problems than it solves (see his response about needing to delete the new instance before unshelving).<br>
<br>
I'd recommend redesigning your application to be more cloud-native. In other words, separate operating system state from application state, use volumes for all persistent application state, and do not rely on a persistent IP address. [1]<br>
<br>
Once you've done that, you can just treat your VMs like cattle and terminate them.<br>
<br>
Best,<br>
-jay<br>
<br>
[1] Please note I did not use the word "container" in this description of cloud-native application.<br>
<br>
______________________________<wbr>_________________<br>
Mailing list: <a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi<wbr>-bin/mailman/listinfo/openstac<wbr>k</a><br>
Post to     : <a href="mailto:openstack@lists.openstack.org" target="_blank">openstack@lists.openstack.org</a><br>
Unsubscribe : <a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi<wbr>-bin/mailman/listinfo/openstac<wbr>k</a><br>
</blockquote></div><br></div>