If neutron spawned dnsmasq dies, neutron-dhcp-agent will be totally unaware
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
Fix Released
|
Low
|
Miguel Angel Ajo |
Bug Description
I recently had some trouble with dnsmasq causing it to segfault in certain situations. No doubt, this was a bug in dnsmasq. However, it was quite troubling that Neutron never noted that dnsmasq had stopped working. This is because dnsmasq is spawned as a daemon, even though it is most definitely "owned" by neutron-dhcp-agent. Also if neutron-dhcp-agent should die, since dnsmasq is a daemon it will continue to run and be "stale", requiring manual intervention to clean up. However if it is in the foreground then it will stay in neutron-
I did some analysis and will not be able to dig into the actual implementation. However my analysis shows that this would work:
* use utils.create_
* spawn a greenthread to wait() on the process or create a SIGCHLD handler
* if it dies, restart it and log the error code
* pass the -k option so dnsmasq stays in foreground
* kill the process using child signals
Note sure how or if SIGCHLD plays a factor.
description: | updated |
Changed in neutron: | |
assignee: | nobody → Jian Wen (wenjianhn) |
status: | New → In Progress |
Changed in neutron: | |
status: | In Progress → Confirmed |
assignee: | Jian Wen (wenjianhn) → nobody |
Changed in neutron: | |
assignee: | nobody → Eugene Nikanorov (enikanorov) |
importance: | Undecided → Low |
tags: | added: l3-ipam-dhcp |
Changed in neutron: | |
status: | Confirmed → In Progress |
related to bug 1244783