[Openstack] Error in ml2 with cisco_nexus driver

Henry Gessau gessau at cisco.com
Thu Apr 3 12:31:56 UTC 2014


On Wed, Apr 02, at 5:15 pm, Qin, Xiaohong  wrote:

> Thanks. Also, I just deployed VLAN with Ml2 but still didn't see any
> configurations been delivered to the Nexus switch. Is there any sample
> localrc files that I can leverage?

>From my own localrc:

    ENABLE_TENANT_VLANS=True
    PHYSICAL_NETWORK=physnet1
    OVS_PHYSICAL_BRIDGE=br-eth1

    Q_PLUGIN=ml2
    Q_ML2_PLUGIN_MECHANISM_DRIVERS=openvswitch,cisco_nexus
    Q_PLUGIN_EXTRA_CONF_PATH=(home/stack)
    Q_PLUGIN_EXTRA_CONF_FILES=(ml2_conf_cisco.ini)
    ML2_VLAN_RANGES=physnet1:120:129

You need to pick VLAN ranges suitable for your environment.

The contents of /home/stack/ml2_conf_cisco.ini should look something like this:

    [ml2_mech_cisco_nexus:10.9.8.7]
    devstack-host=1/12
    username=admin
    password=<nexus-login-password>
    ssh_port=22

Replace 10.9.8.7 with the IP of your nexus. Before firing up devstack,
manually ssh to that IP and make sure you can log in successfully.

1/12 is the physical port on my nexus that is connected to my devstack host.
Make sure to specify the correct port for your setup.


> 
> Thanks.
> 
> Dennis Qin
> 
> -----Original Message-----
> From: Henry Gessau [mailto:gessau at cisco.com] 
> Sent: Wednesday, April 02, 2014 2:13 PM
> To: Qin, Xiaohong; openstack at lists.openstack.org
> Subject: Re: [Openstack] Error in ml2 with cisco_nexus driver
> 
> It's on the list of things to do but I can't make any promises.
> 
> On Wed, Apr 02, at 4:21 pm, Qin, Xiaohong  wrote:
> 
>> Hi Henry,
>> 
>> Thanks for the info. Do you have any idea that this will be addressed in future releases? 
>> 
>> Thanks.
>> 
>> Dennis Qin
>> 
>> -----Original Message-----
>> From: Henry Gessau [mailto:gessau at cisco.com]
>> Sent: Wednesday, April 02, 2014 11:56 AM
>> To: openstack at lists.openstack.org
>> Subject: Re: [Openstack] Error in ml2 with cisco_nexus driver
>> 
>> Hi Dennis,
>> 
>> On Wed, Apr 02, at 1:28 pm Qin, Xiaohong (Xiaohong.Qin at emc.com) wrote:
>> 
>>> Hi Kyle,
>>> 
>>> I was also trying to use this Nexus driver with Ml2/VXLAN deployment 
>>> in devstack. But for some reason, it didn't invoke the nexus driver 
>>> code and
>> 
>> The Nexus driver in ML2 does not support VXLAN. It supports only VLAN.
>> 
>>> didn't do anything on my Nexus switch. I have followed the 
>>> instructions posted in this link,
>>> 
>>> https://wiki.openstack.org/wiki/Neutron/ML2/MechCiscoNexus
>>> 
>>> Did I miss anything here? I have pulled the latest OpenStack code from the main branch. 
>>> 
>>> Thanks.
>>> 
>>> Dennis Qin (aka Xiaohong Qin)
>>> 
>>> -----Original Message-----
>>> From: Kyle Mestery (kmestery) [mailto:kmestery at cisco.com]
>>> Sent: Friday, November 29, 2013 7:57 PM
>>> To: Sayaji Patil
>>> Cc: <openstack at lists.openstack.org>
>>> Subject: Re: [Openstack] Error in ml2 with cisco_nexus driver
>>> 
>>> On Nov 29, 2013, at 1:11 PM, Sayaji Patil <sayaji15 at gmail.com> wrote:
>>>> 
>>>> Hi,
>>>>      I have set up an all-in-one installation using devstack. When I 
>>>> try to create an instance, I get this error when the plugin tries to 
>>>> create a vlan on the nexus switch
>>>> 
>>>> 2013-11-27 16:38:29.752 ^[[00;32mDEBUG ncclient.transport.ssh 
>>>> [^[[00;36m-^[[00;32m] ^[[01;35m^[[00;32mstarting thread (client mode):
>>>> 0x4509ed0L^[[00m ^[[00;33mfrom (pid=13833) _log 
>>>> /usr/lib/python2.6/site-packages/paramiko/transport.py:1406^[[00m
>>>> 2013-11-27 16:38:29.753 ^[[01;31mERROR ncclient.transport.ssh 
>>>> [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31mException: Error reading SSH 
>>>> protocol banner^[[00m
>>>> 2013-11-27 16:38:29.753 ^[[01;31mERROR ncclient.transport.ssh 
>>>> [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31mTraceback (most recent call 
>>>> last):^[[00m
>>>> 2013-11-27 16:38:29.753 ^[[01;31mERROR ncclient.transport.ssh [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31m  File "/usr/lib/python2.6/site-packages/paramiko/transport.py", line 1557, in run^[[00m
>>>> 2013-11-27 16:38:29.753 ^[[01;31mERROR ncclient.transport.ssh [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31m    self._check_banner()^[[00m
>>>> 2013-11-27 16:38:29.754 ^[[01;31mERROR ncclient.transport.ssh [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31m  File "/usr/lib/python2.6/site-packages/paramiko/transport.py", line 1683, in _check_banner^[[00m
>>>> 2013-11-27 16:38:29.754 ^[[01;31mERROR ncclient.transport.ssh [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31m    raise SSHException('Error reading SSH protocol banner' + str(x))^[[00m
>>>> 2013-11-27 16:38:29.754 ^[[01;31mERROR ncclient.transport.ssh 
>>>> [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31mSSHException: Error reading 
>>>> SSH protocol banner^[[00m
>>>> 2013-11-27 16:38:29.754 ^[[01;31mERROR ncclient.transport.ssh 
>>>> [^[[00;36m-^[[01;31m] ^[[01;35m^[[01;31m^[[00m
>>>> 2013-11-27 16:38:29.754 ^[[01;31mERROR neutron.plugins.ml2.managers
>>>> [^[[01;36mreq-b51e27b6-2808-47ad-95db-e9d0113fcfe1 ^[[00;36mNone 
>>>> None^[[01;31m] ^[[01;35m^[[01;31mMechanism driver 'cisco_nexus'
>>>> failed in update_port_postcommit^[[00m
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00mTraceback (most recent call last):
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/managers.py", line 156, in _call_on_drivers
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    getattr(driver.obj, method_name)(context)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/mech_cisco_nexus.py", line 159, in update_port_postcommit
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    self._invoke_nexus_on_port_event(context)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/mech_cisco_nexus.py", line 149, in _invoke_nexus_on_port_event
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    self._manage_port(vlan_name, vlan_id, host_id, instance_id)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/mech_cisco_nexus.py", line 114, in _manage_port
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    vlan_name, port_id)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/nexus_network_driver.py", line 194, in create_and_trunk_vlan
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    self.create_vlan(nexus_host, vlan_id, vlan_name)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/nexus_network_driver.py", line 131, in create_vlan
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    self._edit_config(nexus_host, target='running', config=confstr)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/nexus_network_driver.py", line 68, in _edit_config
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    mgr = self.nxos_connect(nexus_host)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/drivers/cisco/nexus_network_driver.py", line 114, in nxos_connect
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00m    raise cexc.NexusConnectFailed(nexus_host=nexus_host, exc=e)
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers ^[[01;35m^[[00mNexusConnectFailed: Unable to connect to Nexus 172.25.31.82. Reason: Negotiation failed.
>>>> ^[[01;31m2013-11-27 16:38:29.754 TRACE neutron.plugins.ml2.managers 
>>>> ^[[01;35m^[[00m
>>>> 2013-11-27 16:38:29.755 ^[[01;31mERROR 
>>>> neutron.openstack.common.rpc.amqp
>>>> [^[[01;36mreq-b51e27b6-2808-47ad-95db-e9d0113fcfe1 ^[[00;36mNone 
>>>> None^[[01;31m] ^[[01;35m^[[01;31mException during message 
>>>> handling^[[00m
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00mTraceback (most recent call last):
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/openstack/common/rpc/amqp.py", line 438, in _process_data
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    **args)
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/common/rpc.py", line 44, in dispatch
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    neutron_ctxt, version, method, namespace, **kwargs)
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/openstack/common/rpc/dispatcher.py", line 172, in dispatch
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    result = getattr(proxyobj, method)(ctxt, **kwargs)
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/rpc.py", line 192, in update_device_up
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    q_const.PORT_STATUS_ACTIVE)
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/plugin.py", line 690, in update_port_status
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    self.mechanism_manager.update_port_postcommit(mech_context)
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/managers.py", line 395, in update_port_postcommit
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    self._call_on_drivers("update_port_postcommit", context)
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m  File "/opt/stack/neutron/neutron/plugins/ml2/managers.py", line 167, in _call_on_drivers
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00m    method=method_name
>>>> ^[[01;31m2013-11-27 16:38:29.755 TRACE neutron.openstack.common.rpc.amqp ^[[01;35m^[[00mMechanismDriverError: update_port_postcommit failed.
>>>> 
>>>> Also now when I try to manually ssh to the switch, I get this error
>>>> 
>>>> [root at openstackcoi logs]# ssh 172.25.31.82 -l admin
>>>> ssh_exchange_identification: Connection closed by remote host
>>>> 
>>>> This is my ml2_conf_cisco.ini
>>>> 
>>>> [ml2_mech_cisco_nexus:172.25.31.82]
>>>> openstackcoi=1/1
>>>> ssh_port=22
>>>> username=admin
>>>> password=*******
>>>> 
>>>> Regards,
>>>> Sayaji
>>>> 
>>> Sayali:
>>> 
>>> Can you try ensuring you've done an ssh to the switch using the same username you are running devstack as? I believe you have to do this for the ssh to work, and only need to do this once. Let me know if this solves your problem.
>>> 
>>> Thanks,
>>> Kyle
>>> 
>>>> 
>>>> 
>>>> _______________________________________________
>>>> Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>>>> Post to     : openstack at lists.openstack.org
>>>> Unsubscribe : 
>>>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>>> 
>>> 
>>> 
>>> _______________________________________________
>>> Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>>> Post to     : openstack at lists.openstack.org
>>> Unsubscribe : 
>>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>>> 
>>> 
>>> _______________________________________________
>>> Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>>> Post to     : openstack at lists.openstack.org
>>> Unsubscribe : 
>>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>>> 
>> 
>> 
>> _______________________________________________
>> Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>> Post to     : openstack at lists.openstack.org
>> Unsubscribe : 
>> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>> 
>> 
> 
> 
> 





More information about the Openstack mailing list