aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2007-04-16 22:07:59 +0000
committerHarald Hoyer <harald@redhat.com>2011-04-19 16:29:41 +0200
commit3e5ad8ebb33c85a658bd3a310e0eb4d61d68d3df (patch)
treeaad04c08a7391bda03c64512fabdf60f415a8fc0
parentbc618f58f7c44a74c41328c35454f3584eab6ff9 (diff)
downloadinitscripts-3e5ad8ebb33c85a658bd3a310e0eb4d61d68d3df.tar
initscripts-3e5ad8ebb33c85a658bd3a310e0eb4d61d68d3df.tar.gz
initscripts-3e5ad8ebb33c85a658bd3a310e0eb4d61d68d3df.tar.bz2
initscripts-3e5ad8ebb33c85a658bd3a310e0eb4d61d68d3df.tar.xz
initscripts-3e5ad8ebb33c85a658bd3a310e0eb4d61d68d3df.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 454c1321..216aa6af 100644
--- a/sysconfig.txt
+++ b/sysconfig.txt
@@ -543,7 +543,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 f58192a5..5532eca9 100755
--- a/sysconfig/network-scripts/ifup-eth
+++ b/sysconfig/network-scripts/ifup-eth
@@ -208,7 +208,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