[ovirt-users] oVirt Python SDK on Ubuntu

Nathanaël Blanchet blanchet at abes.fr
Mon Jan 23 15:02:32 UTC 2017



Le 23/01/2017 à 15:11, Juan Hernández a écrit :
> On 01/23/2017 03:05 PM, Ondra Machacek wrote:
>> On Mon, Jan 23, 2017 at 2:53 PM, Nicolas Ecarnot <nicolas at ecarnot.net> wrote:
>>> Le 23/01/2017 à 13:38, Ondra Machacek a écrit :
>>>> On Mon, Jan 23, 2017 at 1:23 PM, Nicolas Ecarnot <nicolas at ecarnot.net>
>>>> wrote:
>>>>> Hello,
>>>>>
>>>>> I'm trying to follow
>>>>>
>>>>> http://www.ovirt.org/develop/release-management/features/infra/python-sdk/
>>>>> and I'm successfully discovering Python + oVirt SDK on CentOS.
>>>>>
>>>>> I'd like to do the same on Ubuntu, but the instructions seem incomplete :
>>>>>
>>>>> "
>>>>> easy_install ovirt-engine-sdk-python
>>>>> "
>>>>>
>>>>> is working, but "import ovirtsdk" doen't give anything.
>>>>
>>>> Note that the wiki page is about SDK version 3, which will be deprecated
>>>> in 4.2.
>>>> When you run 'easy_install ovirt-engine-sdk-python' it will install
>>>> Python SDK version
>>>> 4, which is different from SDK version 3.
>>>
>>> You're right, and I haven't noticed : import ovirtsdk4 is working.
>>>
>>>> You may find few examples of Python SDK version 4 here:
>>>>
>>>>   https://github.com/oVirt/ovirt-engine-sdk/tree/master/sdk/examples
>>>
>>> Yes, this list of examples is a treasure, and I'm grateful to the
>>> maintainers.
>>>
>>> Alas, though we already have one DC in V4, most of our production DCs are
>>> still in V3 for one year, and I have to maintain them.
>>> So far, I have no clue how to add ovirtsdk v3 to my Ubuntu.
>> You just need to specify which version you would like to install, in your case:
>>
>>   easy_install ovirt-engine-sdk-python==3.6.9.2
eactly the same with pip

  pip install ovirt-engine-sdk-python==3.6.9.2

>>
>>> Another point : is the compatibility between ovirtsdk and oVirt completely
>>> obvious (ie 3 -> 3 and 4 -> 4), or is there any kind of backward
>>> compatibility?
>> Unfortunatelly no, there is no backward compatibility between SDK v3 and v4.
>>
> Just to clarify this:
>
> 1. Version 3 of the SDK only works with version 3 of the API.
>
> 2. Version 4 of the SDK only works with version 4 of the API.
>
> 3. Version 3 of the engine only supports version 3 of the API.
>
> 4. Versions 4.0 and 4.1 of the engine support both version 3 and 4 of
> the API. This means that with version 4 of the engine you can use both
> versions of the SDK. This will change with version 4.2 of the engine.
> There we will remove support for version 3 of the API, so you will need
> to use version 4 of the SDK.
>
> _______________________________________________
> Users mailing list
> Users at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/users

-- 
Nathanaël Blanchet

Supervision réseau
Pôle Infrastrutures Informatiques
227 avenue Professeur-Jean-Louis-Viala
34193 MONTPELLIER CEDEX 5 	
Tél. 33 (0)4 67 54 84 55
Fax  33 (0)4 67 54 84 14
blanchet at abes.fr



More information about the Users mailing list