summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVagrant Cascadian <vagrant@freegeek.org>2010-08-20 12:35:43 -0700
committermaximilian attems <max@stro.at>2010-08-25 21:37:22 +0200
commit85fbb23edd4eb450f3180e3bfb51245e4da4d56d (patch)
treece3284c61a03f8dd7f786c948ed0945f7f11b8fd
parent71de264f4777f16e1329a59df70d59972a88f854 (diff)
downloadinitramfs-tools-85fbb23edd4eb450f3180e3bfb51245e4da4d56d.tar.gz
initramfs-tools-85fbb23edd4eb450f3180e3bfb51245e4da4d56d.zip
configure_networking(): Look for presence of /tmp/net-*.conf files
when $DEVICE is not set (which is now default), otherwise ipconfig may receive a valid DHCP response, but fails to break out of the loop and is called repeatedly. thanks to Petter Reinholdtsen, i think i've figured out the initramfs-tools portion of this problem (there may still be outstanding issues with ipconfig). tested the attached patch, which seems to address the issue for me at least. Closes: #584583 Signed-off-by: maximilian attems <max@stro.at>
-rw-r--r--scripts/functions6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/functions b/scripts/functions
index 1e2aeee..419203a 100644
--- a/scripts/functions
+++ b/scripts/functions
@@ -372,9 +372,9 @@ configure_networking()
# The NIC is to be configured if this file does not exist.
# Ip-Config tries to create this file and when it succeds
# creating the file, ipconfig is not run again.
- if [ -e /tmp/net-"${DEVICE}".conf ]; then
- break;
- fi
+ for x in /tmp/net-"${DEVICE}".conf /tmp/net-*.conf ; do
+ [ -e "$x" ] && break 2
+ done
case ${IP} in
none|off)