<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;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* 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
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
pre
        {mso-style-priority:99;
        mso-style-link:"Préformaté HTML Car";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.PrformatHTMLCar
        {mso-style-name:"Préformaté HTML Car";
        mso-style-priority:99;
        mso-style-link:"Préformaté HTML";
        font-family:"Courier New";}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
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="FR" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Hi,<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>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">You were right .<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">By setting correct URL and correct certificate file location , it’s working.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">If I well understand , as this certificate file has to be on the client side , isn’t a point if failure ?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<pre><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">For example , for a cluster , it’s possible to retrieve hosts belonging to the cluster via this call:<o:p></o:p></span></pre>
<pre><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></pre>
<pre><span lang="EN-US">hostoncluster = api.clusters.get(id=api.hosts.get(</span><a href="http://obj.name" target="_blank" title="http://obj.name"><span lang="EN-US">obj.name</span></a><span lang="EN-US">).get_cluster().get_id()).get_name()<o:p></o:p></span></pre>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<pre><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#215968;mso-style-textfill-fill-color:#215968;mso-style-textfill-fill-alpha:100.0%">How may I know list of available “fields” for </span><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#215968;mso-style-textfill-fill-color:#215968;mso-style-textfill-fill-alpha:100.0%">host, cluster, datacenters and so on .. …<o:p></o:p></span></pre>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#215968;mso-style-textfill-fill-color:#215968;mso-style-textfill-fill-alpha:100.0%"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Thanks for help.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">J.P.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">De :</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Karli Sjöberg [mailto:karli.sjoberg@slu.se]
<br>
<b>Envoyé :</b> mardi 17 novembre 2015 17:52<br>
<b>À :</b> Jean-Pierre Ribeauville<br>
<b>Cc :</b> users@ovirt.org<br>
<b>Objet :</b> Re: [ovirt-users] Error when trying to retrieve cluster, hosts via ovirt API<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p><br>
Den 17 nov. 2015 5:30 em skrev Jean-Pierre Ribeauville <<a href="mailto:jpribeauville@axway.com">jpribeauville@axway.com</a>>:<br>
><br>
> Hi,<br>
><br>
> <br>
><br>
> By running python example got here ( : <a href="http://website-humblec.rhcloud.com/ovirt-find-hosts-clusters-vm-running-status-ids-storage-domain-details-ovirt-dc-pythonovirt-sdk-part-3">
http://website-humblec.rhcloud.com/ovirt-find-hosts-clusters-vm-running-status-ids-storage-domain-details-ovirt-dc-pythonovirt-sdk-part-3</a>)
<br>
> and modified with my connection parameters, I got following error :<br>
><br>
> <br>
><br>
> <br>
><br>
> Unexpected error: [ERROR]::oVirt API connection failure, (77, '')<br>
><br>
> <br>
><br>
> How may I get error codes meanings ?<o:p></o:p></p>
<p>I don't know the meaning but I saw that APIURL was wrong, it should be:<o:p></o:p></p>
<p>APIURL = "<a href="https://$%7bENGINE_ADDRESS%7d/ovirt-engine/api">https://${ENGINE_ADDRESS}/ovirt-engine/api</a>"<o:p></o:p></p>
<p>Could you correct that and try again?<o:p></o:p></p>
<p>/K<o:p></o:p></p>
<p>><br>
> <br>
><br>
> Thanks for help.<br>
><br>
> <br>
><br>
> <br>
><br>
> <br>
><br>
> J.P. Ribeauville<br>
><br>
> <br>
><br>
> P: +33.(0).1.47.17.20.49<br>
><br>
> .<br>
><br>
> Puteaux 3 Etage 5 Bureau 4<br>
><br>
> <br>
><br>
> <a href="mailto:jpribeauville@axway.com">jpribeauville@axway.com</a><br>
> <a href="http://www.axway.com">http://www.axway.com</a><br>
><br>
> <br>
><br>
> <br>
><br>
> P Pensez à l’environnement avant d’imprimer.<br>
><br>
> <br>
><br>
> <o:p></o:p></p>
</div>
</body>
</html>