← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1497834] [NEW] nova interface-attach doesn't honour allow_duplicate_networks flag

 

Public bug reported:

when this flag is disbaled in nova.conf "allow_duplicate_networks=false"

allocating the port from the same network is failing with the following
error.

$ nova boot --image cirros --flavor 1 --nic net-id=`neutron net-list | grep internal | awk {'print $2'}` --nic net-id=`neutron net-list | grep internal | awk {'print $2'}` VM
ERROR (BadRequest): Network 3ddbef1a-2f8d-4dc2-9a68-f6ea842ceb2d is duplicated. (HTTP 400) (Request-ID: req-6a2e3539-2fed-4b24-8df1-39e18c1285fa)

Now the problem is:

1.boot a VM  with a network.
$nova boot --image cirros --flavor 1 --nic net-id=`neutron net-list | grep internal | awk {'print $2'}` testVM
+--------------------------------------+---------+--------+------------+-------------+---------------------------------------+
| 9c10d628-ea3b-4323-9e44-8b75107e8f71 | testVM | ACTIVE | -          | Running     | internal=10.0.0.4|
+--------------------------------------+---------+--------+------------+-------------+---------------------------------------+

2.Create the port from the same network using which the instance is booted.
$neutron port-create internal

3.Attach the port created in step 2 to VM created in step1.

4.nova interface-attach testVM --port-id 5d7d1cf6-200c-493f-9268-9e366524685f
This command is successful and able to duplicate the network for the VM even though the flag is disabled in nova.conf

| 9c10d628-ea3b-4323-9e44-8b75107e8f71 | testVM | ACTIVE | -          |
Running     | internal=10.0.0.4, 10.0.0.10          |

This command should also result in the same error as network duplicated
or similar.

** Affects: nova
     Importance: Undecided
     Assignee: Vijaya Erukala (vijaya-erukala)
         Status: New

** Changed in: nova
     Assignee: (unassigned) => Vijaya Erukala (vijaya-erukala)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1497834

Title:
  nova interface-attach doesn't honour allow_duplicate_networks flag

Status in OpenStack Compute (nova):
  New

Bug description:
  when this flag is disbaled in nova.conf
  "allow_duplicate_networks=false"

  allocating the port from the same network is failing with the
  following error.

  $ nova boot --image cirros --flavor 1 --nic net-id=`neutron net-list | grep internal | awk {'print $2'}` --nic net-id=`neutron net-list | grep internal | awk {'print $2'}` VM
  ERROR (BadRequest): Network 3ddbef1a-2f8d-4dc2-9a68-f6ea842ceb2d is duplicated. (HTTP 400) (Request-ID: req-6a2e3539-2fed-4b24-8df1-39e18c1285fa)

  Now the problem is:

  1.boot a VM  with a network.
  $nova boot --image cirros --flavor 1 --nic net-id=`neutron net-list | grep internal | awk {'print $2'}` testVM
  +--------------------------------------+---------+--------+------------+-------------+---------------------------------------+
  | 9c10d628-ea3b-4323-9e44-8b75107e8f71 | testVM | ACTIVE | -          | Running     | internal=10.0.0.4|
  +--------------------------------------+---------+--------+------------+-------------+---------------------------------------+

  2.Create the port from the same network using which the instance is booted.
  $neutron port-create internal

  3.Attach the port created in step 2 to VM created in step1.

  4.nova interface-attach testVM --port-id 5d7d1cf6-200c-493f-9268-9e366524685f
  This command is successful and able to duplicate the network for the VM even though the flag is disabled in nova.conf

  | 9c10d628-ea3b-4323-9e44-8b75107e8f71 | testVM | ACTIVE | -
  | Running     | internal=10.0.0.4, 10.0.0.10          |

  This command should also result in the same error as network
  duplicated or similar.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1497834/+subscriptions


Follow ups