Fail to update OS::Neutron::Subnet resource

Bug #1241553 reported by Simon Pasquier
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Heat
Fix Released
High
Steve Baker

Bug Description

Environment:
- Neutron Grizzly
- Heat Havana RC2

Given the following resource:

"demo_first_subnet": {
      "Type": "OS::Quantum::Subnet",
      "Properties": {
        "ip_version": 4,
        "network_id": {
          "Ref": "demo_first_subnet_network"
        },
        "cidr": "10.0.0.0/24",
        "dns_nameservers": [
          "10.197.217.62"
        ],
        "name": "demo_first_subnet"
      }
    }

I run a stack update with this modified template to add a DNS server:
"demo_first_subnet": {
      "Type": "OS::Quantum::Subnet",
      "Properties": {
        "ip_version": 4,
        "network_id": {
          "Ref": "demo_first_subnet_network"
        },
        "cidr": "10.0.0.0/24",
        "dns_nameservers": [
          "10.197.217.62",
          "10.197.217.66"
        ],
        "name": "demo_first_subnet"
      }
    }

The stack update will fail with "NeutronClientException: 400-{u'QuantumError': u'Invalid input for operation: Requested subnet with cidr: 10.0.0.0/24 for network: a283079c-72bf-4d4b-9944-f506e1b6f1ee overlaps with another subnet.'

There are 2 issues in fact:
- OS::Neutron::Subnet resource doesn't support updates for dns_nameservers while it should ('neutron subnet-update 8e578c1d-cd19-4cc4-b9b5-4e563d32addb --dns_nameservers list=true 10.197.217.62 10.197.217.66' works as expected)
- Since OS::Neutron::Subnet resource is not updatable, Heat tries to create the new subnet before deleting the old one but this fails because 2 subnets for the same tenant cannot overlap.

I haven't inspected the code in depth but there are probably other Neutron resources with similar issues.

Revision history for this message
Steve Baker (steve-stevebaker) wrote :

Unfortunately update without replacement has not yet been implemented for any of the neutron resources. I think this would be achievable by icehouse-1

Changed in heat:
milestone: none → icehouse-1
importance: Undecided → High
status: New → Triaged
assignee: nobody → Steve Baker (steve-stevebaker)
Revision history for this message
Steve Baker (steve-stevebaker) wrote :

Partially addressed by the following committed changes:
https://review.openstack.org/#/c/55764/
https://review.openstack.org/#/c/55763/

Changed in heat:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to heat (master)

Fix proposed to branch: master
Review: https://review.openstack.org/55944

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to heat (master)

Reviewed: https://review.openstack.org/55765
Committed: http://github.com/openstack/heat/commit/721e588aebd765e4ff4326cc3a135b8cbfc8738d
Submitter: Jenkins
Branch: master

commit 721e588aebd765e4ff4326cc3a135b8cbfc8738d
Author: Steve Baker <email address hidden>
Date: Fri Nov 1 16:26:01 2013 +1300

    Implement update for neutron router resources

    This change allows any updatable properties to be updated
    on an existing router without replacement. Documentation
    is limited on what properties are updatable, so discovery
    was manual.

    Partial-Bug: #1241553
    Change-Id: Ia3b1885cee2f3440bb73724291d46d5af19962eb

Changed in heat:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/55944
Committed: http://github.com/openstack/heat/commit/8e23e6819d513c5d4e4a965c66497f4b0834df43
Submitter: Jenkins
Branch: master

commit 8e23e6819d513c5d4e4a965c66497f4b0834df43
Author: Steve Baker <email address hidden>
Date: Tue Nov 12 09:47:35 2013 +1300

    Implement update for neutron port resources

    This change allows any updatable properties to be updated
    on an existing port without replacement. Documentation
    is limited on what properties are updatable, so discovery
    was manual. Unlike other neutron resources, port name is not
    updateable without replacement.

    Change-Id: I7845702e14baab595363d57bcf6128e45ffdd789
    Closes-Bug: #1241553

Revision history for this message
Steve Baker (steve-stevebaker) wrote :

I think this is too feature-y to consider for havana backport

Thierry Carrez (ttx)
Changed in heat:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in heat:
milestone: icehouse-1 → 2014.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.