DHCP port is changed when dhcp-agent restart
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
Fix Released
|
Low
|
dql | ||
Kilo |
New
|
Undecided
|
Unassigned |
Bug Description
When dhcp-agent is restarted dhcp port may change. Obviously it causes problems since VMs don't notice this, old port may be reused, etc.
It is easy to reproduce.
before dhcp-agent restart)
$ neutron port-list --device_owner network:dhcp
+------
| id | name | mac_address | fixed_ips |
+------
| b72f0eb1-
+------
1) stop dhcp-agent
2) create port (ex. $ neutron port-create private)
3) start dhcp-agent
after)
$ neutron port-list --device_owner network:dhcp
+------
| id | name | mac_address | fixed_ips |
+------
| 78653fa6-
+------
It occurs as follows:
1) network cache is initialized from state file with 'subnet empty'(!).
(_populate_
2) pending port-create-end RPC event is handled 'before the first sync_state'(!).
3) reload_allocations called and do 'disable' because subnet is empty.
then release_dhcp_port RPC is issued and previous dhcp port is deleted.
4) new dhcp port is created when the first sync_state is executed.
note that network cache become normal at the first sync_state.
tags: | added: l3-ipam-dhcp |
Changed in neutron: | |
assignee: | nobody → dql (duquanglong) |
Changed in neutron: | |
status: | Confirmed → In Progress |
Changed in neutron: | |
importance: | Undecided → Low |
Changed in neutron: | |
status: | In Progress → Fix Committed |
Changed in neutron: | |
milestone: | none → liberty-1 |
status: | Fix Committed → Fix Released |
tags: | added: kilo-backport-potential |
Changed in neutron: | |
milestone: | liberty-1 → 7.0.0 |
There is no service problem unless there are no ports left.
When an instance has to renew it's lease it sends requests for the old IP, after a few retires it sends a DHCP discovery and gets it from the 'new' DHCP server.