aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig/network-scripts/ifup-ppp
diff options
context:
space:
mode:
authorNalin Dahyabhai <nalin@redhat.com>2000-08-07 09:09:04 +0000
committerNalin Dahyabhai <nalin@redhat.com>2000-08-07 09:09:04 +0000
commita2989f6b0eb119c60088dc2c6be720601c8542a1 (patch)
treec7b9ce9d5fd8f23c58ec0aaed0c05edbb8813fe7 /sysconfig/network-scripts/ifup-ppp
parentbffc09ca0f9081340e51a3b8de865f549ae93c2c (diff)
downloadinitscripts-a2989f6b0eb119c60088dc2c6be720601c8542a1.tar
initscripts-a2989f6b0eb119c60088dc2c6be720601c8542a1.tar.gz
initscripts-a2989f6b0eb119c60088dc2c6be720601c8542a1.tar.bz2
initscripts-a2989f6b0eb119c60088dc2c6be720601c8542a1.tar.xz
initscripts-a2989f6b0eb119c60088dc2c6be720601c8542a1.zip
fix demand-dialing for PPP
Diffstat (limited to 'sysconfig/network-scripts/ifup-ppp')
-rwxr-xr-xsysconfig/network-scripts/ifup-ppp12
1 files changed, 7 insertions, 5 deletions
diff --git a/sysconfig/network-scripts/ifup-ppp b/sysconfig/network-scripts/ifup-ppp
index a8a3f7d6..d672f72e 100755
--- a/sysconfig/network-scripts/ifup-ppp
+++ b/sysconfig/network-scripts/ifup-ppp
@@ -6,7 +6,7 @@ cd /etc/sysconfig/network-scripts
# ifup-post for PPP is handled through /etc/ppp/ip-up
-if [ "$1" = daemon ] ; then
+if [ "${1}" = daemon ] ; then
# we've been called from ppp-watch, so don't invoke it for persistence
shift
else
@@ -21,8 +21,8 @@ else
fi
fi
-CONFIG=${1}
-[ -f "${CONFIG}" ] || CONFIG=ifcfg-$1
+CONFIG=$1
+[ -f "${CONFIG}" ] || CONFIG=ifcfg-${1}
source_config
if [ -z "${DISCONNECTTIMEOUT}" ]; then
@@ -92,6 +92,8 @@ if [ ${DEMAND} = yes ] ; then
else
opts="$opts demand idle 600"
fi
+else
+ opts="$opts updetach"
fi
if [ -z "${WVDIALSECT}" ] ; then
@@ -107,13 +109,13 @@ fi
"pppd started for ${DEVICE} on ${MODEMPORT} at ${LINESPEED}" &)&
if [ -n "${WVDIALSECT}" ] ; then
- exec /usr/sbin/pppd -detach $opts ${MODEMPORT} ${LINESPEED} \
+ exec /usr/sbin/pppd $opts ${MODEMPORT} ${LINESPEED} \
ipparam ${DEVICE} linkname ${DEVICE} \
noauth \
${PPPOPTIONS} \
connect "/usr/bin/wvdial --remotename ${DEVICE} --chat ${WVDIALSECT}"
else
- exec /usr/sbin/pppd -detach $opts ${MODEMPORT} ${LINESPEED} \
+ exec /usr/sbin/pppd $opts ${MODEMPORT} ${LINESPEED} \
ipparam ${DEVICE} linkname ${DEVICE} \
noauth \
${PPPOPTIONS} \