can not create port after some port update operations

Bug #1201692 reported by Jiajun Liu
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Critical
Jiajun Liu
Grizzly
Fix Released
Critical
Gary Kotton

Bug Description

I did some test on port-update operation. I found that once a port is updated with a ip address not in any allocation pool then you can not change the port's ip address any more because the old ip address can not be recycled. Even worse, you can create new port because create port operation will trigge ip recycle operation. take the following step to reproduce.

1. create a new network
# neutron net-create test1
2. create a new subnet for that network
# neutron subnet-create 6d7a4316-4649-495f-bcd7-16fcd4c4df1d 192.168.1.0/24 --allocation-pool start=192.168.1.10,end=192.168.1.50
3. create a new port
# neutron port-create 6d7a4316-4649-495f-bcd7-16fcd4c4df1d
4. update ip address
# neutron port-update 7f0a65fb-060e-4c3e-a1ac-7d1535f5e42a --fixed-ips list=true type=dict ip_address=192.168.1.100
# neutron port-update 7f0a65fb-060e-4c3e-a1ac-7d1535f5e42a --fixed-ips list=true type=dict ip_address=192.168.1.200
5. wait for CONF.dhcp_lease_duration seconds (default value 120)
# neutron port-update 7f0a65fb-060e-4c3e-a1ac-7d1535f5e42a --fixed-ips list=true type=dict ip_address=192.168.1.100
Invalid input for operation: No allocation pool found for ip address:192.168.1.100.
6. create new port
# neutron port-create 6d7a4316-4649-495f-bcd7-16fcd4c4df1d
Invalid input for operation: No allocation pool found for ip address:192.168.1.100.

Tags: l3-ipam-dhcp
Jiajun Liu (ljjjustin)
Changed in neutron:
assignee: nobody → Jiajun Liu (ljjjustin)
Revision history for this message
yong sheng gong (gongysh) wrote :

I have verified this bug. It is critical because in nova we support the customized IP beyond the pool. This bug will cause big problem.

Changed in neutron:
status: New → Confirmed
importance: Undecided → Critical
milestone: none → havana-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

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

Changed in neutron:
status: Confirmed → In Progress
tags: added: l3-ipam-dhcp
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/37384
Committed: http://github.com/openstack/neutron/commit/d6cddd430c237c9496a97978070e6891d4625d00
Submitter: Jenkins
Branch: master

commit d6cddd430c237c9496a97978070e6891d4625d00
Author: Jiajun Liu <email address hidden>
Date: Wed Jul 17 03:00:23 2013 +0000

    do not raise exception on ip address recycle operation

    Currenty a exception will raise on ip address recycle operation if the ip
    address doesn't belong to any allocation pool which will make user unable
    to update port, even worse it will make user unable to create new port.
    So do not raise exception if the ip address to be recycled doesn't belong
    to any allocation, just delete it from the ip allocation table.

    fixes bug 1201692

    Change-Id: Icfbded5158f1f4043f69bb1463fd4c830c9714a9

Changed in neutron:
status: In Progress → Fix Committed
tags: added: grizzly-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/grizzly)

Fix proposed to branch: stable/grizzly
Review: https://review.openstack.org/39168

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/grizzly)

Reviewed: https://review.openstack.org/39168
Committed: http://github.com/openstack/neutron/commit/8e6841554c53265cb587d6a3fa72e16a499db183
Submitter: Jenkins
Branch: stable/grizzly

commit 8e6841554c53265cb587d6a3fa72e16a499db183
Author: Jiajun Liu <email address hidden>
Date: Wed Jul 17 03:00:23 2013 +0000

    do not raise exception on ip address recycle operation

    Currenty a exception will raise on ip address recycle operation if the ip
    address doesn't belong to any allocation pool which will make user unable
    to update port, even worse it will make user unable to create new port.
    So do not raise exception if the ip address to be recycled doesn't belong
    to any allocation, just delete it from the ip allocation table.

    fixes bug 1201692

    Change-Id: Icfbded5158f1f4043f69bb1463fd4c830c9714a9
    (cherry picked from commit d6cddd430c237c9496a97978070e6891d4625d00)

tags: added: in-stable-grizzly
Alan Pevec (apevec)
tags: removed: grizzly-backport-potential in-stable-grizzly
Thierry Carrez (ttx)
Changed in neutron:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in neutron:
milestone: havana-3 → 2013.2
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.