Custom Search

Thursday, April 23, 2015

How to OpenStack DevStack OpenContrail enable Extensions

1)
First install OpenStack + OpenContrail setup using devstack
http://fosshelp.blogspot.in/2015/04/openstack-devstack-opencontrail-localrc.html

2)
Goto "/opt/stack/neutron", then clone or download "contrail-neutron-plugin"

#cd /opt/stack/neutron

#git clone https://github.com/Juniper/contrail-neutron-plugin.git
OR
#wget https://github.com/Juniper/contrail-neutron-plugin/archive/v2.01.tar.gz

3)
Configure contrail api_extensions_path  and core_plugin in /etc/neutron/neutron.conf

#vim /etc/neutron/neutron.conf

[DEFAULT]
api_extensions_path = extensions:/opt/stack/neutron/neutron_plugin_contrail/extensions

core_plugin = neutron_plugin_contrail.plugins.opencontrail.contrail_plugin.NeutronPluginContrailCoreV2

4)
Enable contrail_extensions (Example ipam) in /etc/neutron/plugins/opencontrail/ContrailPlugin.ini

#vim /etc/neutron/plugins/opencontrail/ContrailPlugin.ini

[APISERVER]
contrail_extensions=ipam:neutron_plugin_contrail.plugins.opencontrail.contrail_plugin_ipam.NeutronPluginContrailIpam

5)
Goto screen and restart neutron server "q-svc"

6)
Check ipam extension using curl
#curl -s -H "X-Auth-Token: $(keystone token-get | awk '/ id / {print $4}')" 192.168.56.102:9696/v2.0/ipams | python -mjson.tool

7)
List all extensions and check for the "ipam" extension

#curl -s -H "X-Auth-Token: $(keystone token-get | awk '/ id / {print $4}')" 192.168.56.102:9696/v2.0/extensions | python -mjson.tool

OR

#neutron ext-list

8)
Enable contrail_extensions ipam, policy and route-table in /etc/neutron/plugins/opencontrail/ContrailPlugin.ini

#contrail_extensions=ipam:neutron_plugin_contrail.plugins.opencontrail.contrail_plugin_ipam.NeutronPluginContrailIpam,policy:neutron_plugin_contrail.plugins.opencontrail.contrail_plugin_policy.NeutronPluginContrailPolicy,route-table:neutron_plugin_contrail.plugins.opencontrail.contrail_plugin_vpc.NeutronPluginContrailVpc






No comments:

Post a Comment