diff options
author | Bill Nottingham <notting@redhat.com> | 2012-01-06 17:38:26 -0500 |
---|---|---|
committer | Bill Nottingham <notting@redhat.com> | 2012-01-06 17:38:26 -0500 |
commit | 6f6830b700f33172e33db32f12e9bfef3a7f7989 (patch) | |
tree | ab1c142ba6c6bc201c10846b7d8ed54ef9aff3bf /sysconfig/network-scripts/ifup-plip | |
parent | b5a510d2558d333624dac456790d667e3e7f0570 (diff) | |
download | initscripts-6f6830b700f33172e33db32f12e9bfef3a7f7989.tar initscripts-6f6830b700f33172e33db32f12e9bfef3a7f7989.tar.gz initscripts-6f6830b700f33172e33db32f12e9bfef3a7f7989.tar.bz2 initscripts-6f6830b700f33172e33db32f12e9bfef3a7f7989.tar.xz initscripts-6f6830b700f33172e33db32f12e9bfef3a7f7989.zip |
Remove ifconfig usage from assorted ancient device types.
Diffstat (limited to 'sysconfig/network-scripts/ifup-plip')
-rwxr-xr-x | sysconfig/network-scripts/ifup-plip | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sysconfig/network-scripts/ifup-plip b/sysconfig/network-scripts/ifup-plip index 48bcc2ca..7f4f521e 100755 --- a/sysconfig/network-scripts/ifup-plip +++ b/sysconfig/network-scripts/ifup-plip @@ -11,14 +11,10 @@ then exit fi -ifconfig ${DEVICE} ${IPADDR} pointopoint ${REMIP} -route add -net ${NETWORK} netmask ${NETMASK} ${DEVICE} - -# this is broken! it's only here to keep compatibility with old RH systems -if [ "${GATEWAY}" != "" -a "${GATEWAY}" != "none" ] -then - route add default gw ${GATEWAY} metric ${METRIC:-1} ${DEVICE} -fi +[ -z "$PREFIX" ] && eval $(/bin/ipcalc --prefix ${IPADDR} ${NETMASK}) +ip addr add ${IPADDR} peer ${REMIP}/${PREFIX} dev ${DEVICE} +ip link set up dev ${DEVICE} +ip route add ${NETWORK} dev ${DEVICE} . /etc/sysconfig/network |