[openstack-dev] develop a Quantum plugin

Filipe Manco filipe.manco at gmail.com
Wed May 29 16:55:29 UTC 2013


Have you considered using devstack?

Filipe Manco
http://about.me/fmanco


2013/5/29 Julio Carlos Barrera Juez <juliocarlos.barrera at i2cat.net>

> Hi all!
>
> We have solved our problem.
>
> We have added the symbolic links and the compiled Python '.pyc' files to a
> Python Path folder
> (/usr/local/lib/python2.7/dist-packages/quantum-2013.1.2.a24.gd177e58-py2.7.egg/).
> Now the plugins loads and works.
>
> Is there a better way to achieve our objective? Adding a folder in Python
> PAth? Creating and installing a Python EGG file?
>
> Thank you!
>
>
> On 29 May 2013 13:01, Filipe Manco <filipe.manco at gmail.com> wrote:
>
>> An error I did before was to name the file "my_plugin" instead of
>> "my_plugin.py".
>> I would test with an empty plugin, a file with just the class definition
>> with an empty __init__ method.
>>
>> Filipe Manco
>> http://about.me/fmanco
>>
>>
>> 2013/5/29 Pedro Navarro Pérez <pednape at gmail.com>
>>
>>> Hi Julio,
>>>
>>> you can find useful guidelines about quantum plugin development here:
>>> https://wiki.openstack.org/wiki/QuantumDevelopment
>>>
>>>
>>> On Wed, May 29, 2013 at 12:29 PM, Julio Carlos Barrera Juez
>>> <juliocarlos.barrera at i2cat.net> wrote:
>>> > Thank you for your quick response Filipe. I have tried to follow your
>>> > guidelines:
>>> >
>>> > - I have made symbolic links in
>>> > /usr/lib/python2.7/dist-packages/quantum/plugins (line openvswitch).
>>> > - I compiled my python source code (like openvswitch wuth '.pyc'
>>> files).
>>> > - I have restarted OpenStack server.
>>> > - Same error...
>>> >
>>> > We are using stable Grizzly release.
>>> >
>>> >
>>> > On 29 May 2013 12:12, Filipe Manco <filipe.manco at gmail.com> wrote:
>>> >>
>>> >> Try to put your plugin on
>>> >> /usr/lib/python2.7/dist-packages/quantum/plugins. Or you can make
>>> symbolic
>>> >> links to your plugin files.
>>> >>
>>> >> Regards
>>> >>
>>> >> Filipe Manco
>>> >> http://about.me/fmanco
>>> >>
>>> >>
>>> >> 2013/5/29 Julio Carlos Barrera Juez <juliocarlos.barrera at i2cat.net>
>>> >>>
>>> >>> Hi OpenStack community!
>>> >>>
>>> >>> Our colleagues an me are trying to develop a Quantum plugin. We have
>>> not
>>> >>> found official guidelines to achieve it, only related stuff like
>>> this:
>>> >>>
>>> http://docs.openstack.org/trunk/openstack-network/admin/content/quantum_server.html
>>> .
>>> >>> We found that we need to implement
>>> >>> 'quantum/quantum_plugin_base_v2.QuantumPluginBaseV2'
>>> >>> (
>>> https://github.com/openstack/quantum/blob/stable/grizzly/quantum/quantum_plugin_base_v2.py
>>> ).
>>> >>> We have an Ubuntu OpenStack instance. After developing a basic
>>> plugin, we
>>> >>> placed it on our OpenStack instance plugins folder
>>> >>> ('/usr/share/pyshared/quantum/plugins' in our case). We created a
>>> folder and
>>> >>> placed inside our plugin with an empty '__init__.py' file. Then we
>>> edited
>>> >>> Quantum config file ('/etc/quantum/quantum.conf' in our case):
>>> >>>
>>> >>> ...
>>> >>> #core_plugin =
>>> >>> quantum.plugins.openvswitch.ovs_quantum_plugin.OVSQuantumPluginV2
>>> >>> core_plugin =
>>> >>> quantum.plugins.our_plugin_folder.our_plugin_file.OurPluginClass
>>> >>> ...
>>> >>>
>>> >>>
>>> >>>
>>> >>> Then we restarted our OpenStack server (with 'sudo service
>>> quantum-server
>>> >>> restart' in our case), but the log showed this error:
>>> >>>
>>> >>> ImportError: No module named our_plugin_folder.our_plugin_file.
>>> >>>
>>> >>>
>>> >>>
>>> >>> We have verified the folder and file names.
>>> >>>
>>> >>> What are our mistake? Where can we find more information about it?
>>> >>>
>>> >>> Thank you in advance!
>>> >>>
>>> >>> _______________________________________________
>>> >>> OpenStack-dev mailing list
>>> >>> OpenStack-dev at lists.openstack.org
>>> >>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>>> >>>
>>> >>
>>> >>
>>> >> _______________________________________________
>>> >> OpenStack-dev mailing list
>>> >> OpenStack-dev at lists.openstack.org
>>> >> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>>> >>
>>> >
>>> >
>>> > _______________________________________________
>>> > OpenStack-dev mailing list
>>> > OpenStack-dev at lists.openstack.org
>>> > http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>>> >
>>>
>>> _______________________________________________
>>> OpenStack-dev mailing list
>>> OpenStack-dev at lists.openstack.org
>>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>>>
>>
>>
>> _______________________________________________
>> OpenStack-dev mailing list
>> OpenStack-dev at lists.openstack.org
>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>>
>>
>
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20130529/2612e34c/attachment.html>


More information about the OpenStack-dev mailing list