Ask Your Question
0

[Packstack] [Neutron][Liberty] crash openvswitch due to segment ID set to None

asked 2015-11-27 11:26:16 -0500

Nicolas Menant gravatar image

Hi,

I've wanted to test Liberty and used Packstack to deploy: 1x Controller, 1xNetwork Node, 2x Compute node

I use Neutron and ML2 plugin for my environment. Everything is setup properly and neutron agent-list / neutron agent-show <id> show my expected configuration and everything is up and running. On my network/compute nodes, my openvswitch agent is active (Running)

The issue happen has soon as i try to setup some networks:

  • Creation of a router: no issue

    neutron router-create admin_router

  • create a network/subnet: no issue

    neutron net-create public -- --router:external=True --provider:network_type local neutron subnet-create --allocation-pool start=10.1.10.100,end=10.1.10.200 --gateway=10.1.10.1 --name public_subnet public 10.1.10.0/24

however if i restart my neutron-openvswitch-agent, it will die

    [root@NetworkNode ml2]# service neutron-openvswitch-agent status
Redirecting to /bin/systemctl status  neutron-openvswitch-agent.service
neutron-openvswitch-agent.service - OpenStack Neutron Open vSwitch Agent
   Loaded: loaded (/usr/lib/systemd/system/neutron-openvswitch-agent.service; enabled)
   Active: failed (Result: exit-code) since Fri 2015-11-27 12:14:51 EST; 679ms ago
  Process: 24386 ExecStart=/usr/bin/neutron-openvswitch-agent --config-file /usr/share/neutron/neutron-dist.conf --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/plugin.ini --config-dir /etc/neutron/conf.d/common --config-dir /etc/neutron/conf.d/neutron-openvswitch-agent --log-file /var/log/neutron/openvswitch-agent.log (code=exited, status=1/FAILURE)
 Main PID: 24386 (code=exited, status=1/FAILURE)

this is what i get in my log file:

[root@NetworkNode ml2]# tail -2 /var/log/neutron/openvswitch-agent.log
2015-11-27 12:14:51.136 24386 ERROR neutron.plugins.ml2.drivers.openvswitch.agent.ovs_neutron_agent [req-def72090-0c7d-4142-aad6-d40ecd086107 - - - - -] invalid literal for int() with base 10: 'None' Agent terminated!
2015-11-27 12:14:51.142 24386 INFO oslo_rootwrap.client [req-def72090-0c7d-4142-aad6-d40ecd086107 - - - - -] Stopping rootwrap daemon process with pid=24415
[root@NetworkNode ml2]#

if i delete my network, then the ovs agent will start again

i did some research on this

invalid literal for int() with base 10: 'None' Agent terminated!

and i found this known bug: https://review.openstack.org/#/c/237586/

The segmentation_id of a OVS VLAN can be None, but a recent change
assumed that it was always an integer. It highlighted the fact that we
try to store None in the OVS database, which got stored as a string.
This fixes the storage, and handles loading the value while keeping
compatibility.

I'm using flat vlan and i believe this is the issue i face...

Where i'm not comfortable is :

  • Is the liberty version retrieve through RDO contain the patch ? Is there anyway to know this ?
  • If not, any idea when it may be ? Any idea as a workaround ??

Not being able to use Flat vlan is slightly disruptive ^^'

Thanks for your feedback/help

Nicolas

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
0

answered 2015-12-01 02:40:39 -0500

dbaxps gravatar image

updated 2015-12-01 07:37:43 -0500

UPDATE 12/01/2015 MSK 16:35
Following https://github.com/beekhof/osp-ha-dep...
I ran :-

neutron-db-manage --config-file /etc/neutron/neutron.conf \
--config-file /etc/neutron/plugin.ini upgrade head

head is the latest trunk . On working system I have :-

MariaDB [neutron]> select * from ml2_network_segments;
+--------------------------------------+--------------------------------------+--------------+------------------+-----------------+------------+---------------+
| id                                   | network_id                           | network_type | physical_network | segmentation_id | is_dynamic | segment_index |
+--------------------------------------+--------------------------------------+--------------+------------------+-----------------+------------+---------------+
| 8bec3d9c-649c-48b8-ba92-92d58d14d20d | 847e5c9c-ce9f-4b2c-86fb-d7597017e8e3 | vxlan        | NULL             |              81 |          0 |             0 |
| ac80c6bc-e119-48b7-a23d-a8aaa19e500c | ab421dc7-27fa-4984-ae21-ba9518887293 | vxlan        | NULL             |              86 |          0 |             0 |
| c84c7d4c-0a9c-4e10-8a1f-09bf733a37c6 | b4580386-bc02-4aa7-8792-ea4c40c41573 | flat         | physnet1         |            NULL |          0 |             0 |
+--------------------------------------+--------------------------------------+--------------+------------------+-----------------+------------+---------------+
3 rows in set (0.00 sec)

MariaDB [neutron]> desc ml2_network_segments;
+------------------+-------------+------+-----+---------+-------+
| Field            | Type        | Null | Key | Default | Extra |
+------------------+-------------+------+-----+---------+-------+
| id               | varchar(36) | NO   | PRI | NULL    |       |
| network_id       | varchar(36) | NO   | MUL | NULL    |       |
| network_type     | varchar(32) | NO   |     | NULL    |       |
| physical_network | varchar(64) | YES  |     | NULL    |       |
| segmentation_id  | int(11)     | YES  |     | NULL    |       |
| is_dynamic       | tinyint(1)  | NO   |     | 0       |       |
| segment_index    | int(11)     | NO   |     | 0       |       |
+------------------+-------------+------+-----+---------+-------+
7 rows in set (0.00 sec)

But , neutron/plugins/ml2/drivers/openvswitch/agent/ovs_neutron_agent.py IS NOT patched
Even build http://cbs.centos.org/koji/buildinfo?... doesn't have patch required per my opinion
I would be happy to be wrong about this. The only option seems to be acceptable for you is follow :-
https://github.com/beekhof/osp-ha-dep...
Just for Single RDO Liberty Controller ( obviously ignore HAProxy && Keepalived , HA for Rabbitmq-server setup )
Another option download http://cbs.centos.org/koji/buildinfo?...
and rebuild with patch :-
https://git.openstack.org/cgit/openst...
Then attempt to re-install neutron RPMs
There is also abandoned patch :- https://review.openstack.org/#/c/225001/

 Actually, it is a hack. However, I used to apply it to already installed RDO Liberty on CentOS 7.1 and it allows to start neutron-openvswitch-agent. For now hack might be the best option of all mentioned above.

END UPDATE

Via my experience VLAN external port is required in HAProxy/Keepalived 3 Node Controller setup (RDO Liberty) :-
1. http://lxer.com/module/newswire/view/...

Your question "Is the liberty version retrieve through RDO contain the patch ? Is there anyway to know this ? "
Working on (1) I didn't have problems with external flat network provider. Looks like commit bellow is packaged  already in RDO Liberty.

See https://bugs.launchpad.net/neutron/+b...
Comment #35
Reviewed: https://review.openstack.org/238485
Committed: https://git.openstack.org/cgit/openst...

edit flag offensive delete link more

Comments

Thanks dbaxps, i'll look into this tonight … maybe the issue is something else that i mentioned … would not be the first time. I'll keep you posted as soon as i've reviewed this.

Nicolas Menant gravatar imageNicolas Menant ( 2015-12-01 04:26:22 -0500 )edit

@NicolasMenant , See final feedback from RDO package maintainer :-
https://www.redhat.com/archives/rdo-l...
Would you prefer Delorean Repos for setup just contact me via Linkedin.com

dbaxps gravatar imagedbaxps ( 2015-12-01 09:43:29 -0500 )edit

I used the hack mentioned here and it works https://review.openstack.org/#/c/237586/2/neutron/plugins/ml2/drivers/openvswitch/agent/ovs_neutron_agent.py . My agent started properly and i've setup gre tunnels and deployed VM successfully. thanks !

Nicolas Menant gravatar imageNicolas Menant ( 2015-12-02 10:01:41 -0500 )edit
dbaxps gravatar imagedbaxps ( 2015-12-02 12:41:58 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2015-11-27 11:24:42 -0500

Seen: 548 times

Last updated: Dec 01 '15