In Vlan mode can't create a network when --vlan option is not set
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Alvaro Lopez |
Bug Description
In Vlan mode when I tried to create a network without setting the --vlan mode, I got the DuplicateVlan exception.
$ nova network-create --fixed-range-v4 192.168.3.1/24 net
ERROR: The server has either erred or is incapable of performing the requested operation. (HTTP 500) (Request-ID: req-14c6c520-
The log in the nova-network service is :
2013-04-15 03:10:37 ERROR [nova.openstack
Traceback (most recent call last):
File "/opt/stack/
rval = self.proxy.
File "/opt/stack/
return getattr(proxyobj, method)(ctxt, **kwargs)
File "/opt/stack/
self, context, vpn=True, **kwargs)
File "/opt/stack/
return self._do_
File "/opt/stack/
network = self.db.
File "/opt/stack/
return IMPL.network_
File "/opt/stack/
return f(*args, **kwargs)
File "/opt/stack/
raise exception.
DuplicateVlan: Detected existing vlan with id 100
2013-04-15 03:10:37 DEBUG [nova.openstack
2013-04-15 03:10:37 INFO [nova.openstack
2013-04-15 03:10:37 ERROR [nova.openstack
2013-04-15 03:10:37 ERROR [nova.openstack
This is because "vlan" is set to the default value 100, if the --vlan option isn't set.
So I think we should make "vlan" an essential option to fix to bug.
Changed in nova: | |
assignee: | nobody → Haiwei Xu (xu-haiwei) |
tags: | added: network |
Changed in nova: | |
assignee: | Haiwei Xu (xu-haiwei) → Alvaro Lopez (aloga) |
status: | New → In Progress |
Changed in nova: | |
importance: | Undecided → Medium |
tags: | added: grizzly-backport-potential |
Changed in nova: | |
milestone: | none → havana-3 |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | havana-3 → 2013.2 |
tags: | removed: grizzly-backport-potential |
Reviewed: https:/ /review. openstack. org/34529 github. com/openstack/ nova/commit/ ec4a9490047106b 36c8a6bdf91fc75 79b84868dd
Committed: http://
Submitter: Jenkins
Branch: master
commit ec4a9490047106b 36c8a6bdf91fc75 79b84868dd
Author: Alvaro Lopez Garcia <email address hidden>
Date: Wed Jul 17 13:20:33 2013 +0200
Fix network creation in Vlan mode
- If "vlan" is specified when creating a network, we honour the option. networks + index_of_ requested_ network
- If it is not specified, the Vlan number is calculated as follows:
CONF.vlan_start + num_existing_
- If the above vlan is in use, try to get the next free vlan.
Fixes bug 1194835
Fixes bug 1169026
Change-Id: Id4476c14f9dadc f498a4995343374 77b3f64f604