Work around leak in dhcp-all-interfaces udev rule

This patch removes /etc/udev/rules.d/99-dhcp-all-interfaces.rules
once os-net-config has executed at least once successfully. This
will ensure no more DHCP bootstrapping occurs until we get more
information on why dhcp-all-interfaces.sh is leaking DHCP processes.

Change-Id: I5b456419df6c6606a4bda1202ea49378e6feb6b2
Related-bug: #1538259
This commit is contained in:
Dan Prince 2016-01-26 13:59:49 -05:00
parent 4383c42602
commit 858e13af45
1 changed files with 9 additions and 0 deletions

View File

@ -104,6 +104,15 @@ if [ -n "$NET_CONFIG" ]; then
RETVAL=$?
if [[ $RETVAL == 2 ]]; then
ping_metadata_ip
#NOTE: dprince this udev rule can apparently leak DHCP processes?
# https://bugs.launchpad.net/tripleo/+bug/1538259
# until we discover the root cause we can simply disable the
# rule because networking has already been configured at this point
if [ -f /etc/udev/rules.d/99-dhcp-all-interfaces.rules ]; then
rm /etc/udev/rules.d/99-dhcp-all-interfaces.rules
fi
elif [[ $RETVAL != 0 ]]; then
echo "ERROR: os-net-config configuration failed." >&2
exit 1