Ask Your Question
3

I can't create a network When the network is set to vlan

asked 2013-04-10 02:05:50 -0500

xu-haiwei gravatar image

updated 2013-04-10 02:46:02 -0500

I set nova-network to work in vlan mode. I think there is nothing wrong with the network configuration. Because I check the network with this command and it works.

$ brctl show
bridge name     bridge id               STP enabled     interfaces
br100           8000.fa163ebec7c9       no              vlan100
                                                        vnet0
virbr0          8000.000000000000       yes

And the information about my network:

$nova network-list
+--------------------------------------+---------+-------------+
| ID                                   | Label   | Cidr        |
+--------------------------------------+---------+-------------+
| 0b69934f-80ff-4fa0-951f-580fd35a6b2f | private | 10.0.0.0/24 |
+--------------------------------------+---------+-------------+
$ nova network-show private
+---------------------+--------------------------------------+
| Property            | Value                                |
+---------------------+--------------------------------------+
| bridge              | br100                                |
| vpn_public_port     | 1000                                 |
| dhcp_start          | 10.0.0.3                             |
| bridge_interface    | eth0                                 |
| updated_at          | 2013-04-10T06:33:07.000000           |
| id                  | 0b69934f-80ff-4fa0-951f-580fd35a6b2f |
| cidr_v6             | None                                 |
| deleted_at          | None                                 |
| gateway             | 10.0.0.1                             |
| rxtx_base           | None                                 |
| label               | private                              |
| priority            | None                                 |
| project_id          | 2c9c0fe6414e4724849c193fc874c7b0     |
| vpn_private_address | 10.0.0.2                             |
| deleted             | 0                                    |
| vlan                | 100                                  |
| broadcast           | 10.0.0.255                           |
| netmask             | 255.255.255.0                        |
| injected            | False                                |
| cidr                | 10.0.0.0/24                          |
| vpn_public_address  | 192.168.1.100                        |
| multi_host          | True                                 |
| dns2                | None                                 |
| created_at          | 2013-04-10T05:15:29.000000           |
| host                | None                                 |
| gateway_v6          | None                                 |
| netmask_v6          | None                                 |
| dns1                | 8.8.4.4                              |
+---------------------+--------------------------------------+

My problem is when I want to creat a network with network-create, I got this error:

$ nova network-create --fixed-range-v4 11.0.0.0/24 --vlan 123 net1
ERROR: The server has either erred or is incapable of performing the requested operation.   (HTTP 500) (Request-ID: req-418aed88-57dd-495e-bc1f-5ede146137ca)

and the error message in the network log is:

2013-04-10 06:59:57    ERROR [nova.openstack.common.rpc.amqp] Exception during message handling
Traceback (most recent call last):
 File "/opt/stack/nova/nova/openstack/common/rpc/amqp.py", line 430, in _process_data
   rval = self.proxy.dispatch(ctxt, version, method, **args)
 File "/opt/stack/nova/nova/openstack/common/rpc/dispatcher.py", line 133, in dispatch
   return getattr(proxyobj, method)(ctxt, **kwargs)
 File "/opt/stack/nova/nova/network/manager.py", line 1811, in create_networks
   self, context, vpn=True, **kwargs)
 File "/opt/stack/nova/nova/network/manager.py", line 1058, in create_networks
   return self._do_create_networks(context, **kwargs)
 File "/opt/stack/nova/nova/network/manager.py", line 1187, in _do_create_networks
   network = self.db.network_create_safe(context, net)
 File "/opt/stack/nova/nova/db/api.py", line 797, in network_create_safe
   return IMPL.network_create_safe(context, values)
 File "/opt/stack/nova/nova/db/sqlalchemy/api.py", line 96, in wrapper
   return f(*args, **kwargs)
 File "/opt/stack/nova/nova/db/sqlalchemy/api.py", line 2165, in network_create_safe
   raise exception.DuplicateVlan(vlan=values['vlan'])
 DuplicateVlan: Detected existing vlan with id 100
 2013-04-10 06:59:57    ERROR [nova.openstack.common.rpc.common] Returning exception  Detected   existing vlan with id 100 to caller
 2013-04-10 06:59:57    ERROR [nova.openstack.common.rpc.common] ['Traceback (most recent call last):\n', '  File "/opt/stack/nova/nova/openstack/common/rpc/amqp.py", line 430, in _process_data\n    rval = self.proxy.dispatch(ctxt, version, method, **args)\n', '  File "/opt/stack/nova/nova/openstack/common/rpc/dispatcher.py", line 133, in dispatch\n    return getattr(proxyobj, method)(ctxt, **kwargs)\n', '  File "/opt/stack/nova/nova/network/manager.py", line 1811, in create_networks\n    self, context, vpn=True, **kwargs)\n', '  File "/opt/stack/nova/nova/network/manager.py", line 1058, in create_networks\n    return ...
(more)
edit retag flag offensive close merge delete

Comments

What release are you running--Essex, Folsom, or Grizzly?

briancline gravatar imagebriancline ( 2013-04-10 10:34:27 -0500 )edit

I am running Grizzly. I also found there is no problem in "nova-manage network create" in vlan. I run "nova network-create --fixed-range-v4 11.0.0.0/24 --vlan 123 net1" and succeeded in creating a network with vlanid 123

xu-haiwei gravatar imagexu-haiwei ( 2013-04-10 18:33:39 -0500 )edit

1 answer

Sort by » oldest newest most voted
2

answered 2013-04-11 18:45:48 -0500

xu-haiwei gravatar image

I have solved this problem by myself, and it's a bug indeed. I have proposed the fix method to the community.

https://bugs.launchpad.net/python-novaclient/+bug/1167779

edit flag offensive delete link more

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

Stats

Asked: 2013-04-10 02:05:50 -0500

Seen: 1,411 times

Last updated: Apr 11 '13