<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<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;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Webdings;
        panose-1:5 3 1 2 1 5 9 6 7 3;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
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.emailquote, li.emailquote, div.emailquote
        {mso-style-name:emailquote;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:1.0pt;
        border:none;
        padding:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></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="EN-GB" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Try using vm.shutdown()<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<div style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt">
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> users-bounces@ovirt.org [mailto:users-bounces@ovirt.org]
<b>On Behalf Of </b>Jean-Pierre Ribeauville<br>
<b>Sent:</b> 19 January 2016 10:30<br>
<b>To:</b> users@ovirt.org<br>
<b>Subject:</b> [ovirt-users] Gracefully GUEST shutown via ovirt Python-SDK<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">Hi,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">When using shutdown from ovirt manager GUI , then on a Linux Guest , I get this massage :<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">System Administrator has initiated shutdown of this Virtual Machine. Virtual Machine is shutting down."</span></i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">The system is going down for power-off at Tue 2016-01-19 10:32:19 CET!</span></i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">When , via ovirt Python SDK , I use this :<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">api = API(url=URL, username=USERNAME, password=PASSWORD, ca_file=CA_FILE)</span></i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> vm = api.vms.get(name=VM_NAME)</span></i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> print 'Stopping this VM'</span></i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> vm.stop()<br>
<br>
</span></i><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">Then the Guest is stopped in a ‘non –gracefully » way.<br>
Is it a way to achieve same behavior as via GUI shutdown ?<br>
<br>
Thx for help.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">Regards,<o:p></o:p></span></p>
</div>
<table class="MsoNormalTable" border="0" cellpadding="0" width="152" style="width:113.7pt;margin-left:5.4pt">
<tbody>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><span style="color:#888888"> <o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="color:#888888"> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="color:#888888"> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:#888888">J.P. Ribeauville</span></b><span style="color:#888888"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="color:#737373"> </span><span style="color:#888888"><o:p></o:p></span></p>
</div>
</td>
</tr>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red">P:
</span><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:#737373">+33.(0).1.47.17.20.49</span><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red">
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:#737373">.</span><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:#737373">Puteaux 3 Etage 5 Bureau 4</span><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:#737373"> </span><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red"><a href="mailto:jpribeauville@axway.com"><span style="font-size:9.0pt;font-family:"Calibri","sans-serif"">jpribeauville@axway.com</span></a><br>
<a href="http://www.axway.com/"><span style="font-size:9.0pt;font-family:"Calibri","sans-serif"">http://www.axway.com</span></a><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:#737373"> </span><span style="font-size:8.5pt;font-family:"Arial","sans-serif";color:red"><o:p></o:p></span></p>
</div>
</td>
</tr>
</tbody>
</table>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<table class="MsoNormalTable" border="0" cellpadding="0" width="241" style="width:180.4pt;margin-left:5.4pt">
<tbody>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><span style="font-size:18.0pt;font-family:Webdings;color:#888888">P</span><span style="font-size:8.0pt;font-family:"Calibri","sans-serif";color:#888888"> </span><span style="font-size:8.0pt;font-family:"Arial","sans-serif";color:#888888">Pensez
à l’environnement avant d’imprimer.</span><o:p></o:p></p>
</td>
</tr>
</tbody>
</table>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> <o:p></o:p></span></p>
</div>
</div>
</div>
<PRE>
Please visit our new website at www.pml.ac.uk and follow us on Twitter @PlymouthMarine
Winner of the Environment & Conservation category, the Charity Awards 2014.
Plymouth Marine Laboratory (PML) is a company limited by guarantee registered in England & Wales, company number 4178503. Registered Charity No. 1091222. Registered Office: Prospect Place, The Hoe, Plymouth PL1 3DH, UK.
This message is private and confidential. If you have received this message in error, please notify the sender and remove it from your system. You are reminded that e-mail communications are not secure and may contain viruses; PML accepts no liability for any loss or damage which may be caused by viruses.
</PRE></body>
</html>