Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Only setup dhcp interface if dhcp is not active on network
When enabling (DhcpLocalProcess.enable()) dhcp for a network the agent first sets dhcp interface, then checks if dhcp is curently active and if it's true then the agent restarts dhcp. Restart (DhcpBase.restart()) first disables dhcp and then enables it again by calling DhcpLocalProcess.enable() recursively which in turn sets dhcp interface again (it doesn't see the port created earlier as network is not re-fetched from db). This leads to duplicate dhcp interface for the network. The fix is to only setup dhcp interface if dhcp is not active. Closes-Bug: #1339968 Change-Id: I3a6d2fd5b18a97138ac5b699ecd4d4b30dbdbacb
- Loading branch information