aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2007-04-16 22:07:59 +0000
committerBill Nottingham <notting@redhat.com>2007-04-16 22:07:59 +0000
commitca5bd7279c61f0b7dd5083d9ffab85fc2e0858ba (patch)
tree87535fcf024aafed99b45a6283799a4c22a8b258
parenta107a46776fe13767574cd46c0ba8bd12d7f3bf6 (diff)
downloadinitscripts-ca5bd7279c61f0b7dd5083d9ffab85fc2e0858ba.tar
initscripts-ca5bd7279c61f0b7dd5083d9ffab85fc2e0858ba.tar.gz
initscripts-ca5bd7279c61f0b7dd5083d9ffab85fc2e0858ba.tar.bz2
initscripts-ca5bd7279c61f0b7dd5083d9ffab85fc2e0858ba.tar.xz
initscripts-ca5bd7279c61f0b7dd5083d9ffab85fc2e0858ba.zip
disable link checking when PERSISTENT_DHCLIENT is set (#234075)
-rw-r--r--sysconfig.txt3
-rwxr-xr-xsysconfig/network-scripts/ifup-eth2
2 files changed, 3 insertions, 2 deletions
diff --git a/sysconfig.txt b/sysconfig.txt
index a4d830c1..fbb11535 100644
--- a/sysconfig.txt
+++ b/sysconfig.txt
@@ -546,7 +546,8 @@ Files in /etc/sysconfig/network-scripts/
the '-1' option is given to dhclient.
If PERSISTENT_DHCLIENT=yes, then dhclient will keep on trying
to contact the dhcp server when it does not respond - no '-1'
- option is given to dhclient.
+ option is given to dhclient. Note: this disables the automatic
+ checking for the presence of a link before starting dhclient.
DHCPRELEASE=yes|no|1|0
With this option set to 'yes' (1), when a dhcp configured
interface is brought down with 'ifdown', the lease will be
diff --git a/sysconfig/network-scripts/ifup-eth b/sysconfig/network-scripts/ifup-eth
index b9a00f13..2b829e00 100755
--- a/sysconfig/network-scripts/ifup-eth
+++ b/sysconfig/network-scripts/ifup-eth
@@ -177,7 +177,7 @@ if [ -n "${DYNCONFIG}" -a -x /sbin/dhclient ]; then
DHCLIENTARGS="${DHCLIENTARGS} ${ONESHOT} -q ${DHCLIENTCONF} -lf /var/lib/dhclient/dhclient-${DEVICE}.leases -pf /var/run/dhclient-${DEVICE}.pid"
echo
echo -n $"Determining IP information for ${DEVICE}..."
- if check_link_down ${DEVICE}; then
+ if [[ "${PERSISTENT_DHCLIENT}" != [yY1]* ]] && check_link_down ${DEVICE}; then
echo $" failed; no link present. Check cable?"
ip link set dev ${DEVICE} down >/dev/null 2>&1
exit 1