o redirect the grep to /dev/null
o use ifn rather than interface in rc.network o merge into rc.d/network1 Approved by: (re blanket)
This commit is contained in:
parent
7faa4ab461
commit
c9e1bbfb91
@ -146,6 +146,11 @@ network_start()
|
||||
|
||||
dhcp_interfaces=""
|
||||
for ifn in ${network_interfaces}; do
|
||||
if ifconfig ${ifn} | grep -s UP, > /dev/null 2>&1; then
|
||||
# Interface is already up, so ignore it.
|
||||
continue;
|
||||
fi
|
||||
|
||||
if [ -r /etc/start_if.${ifn} ]; then
|
||||
. /etc/start_if.${ifn}
|
||||
eval showstat_$ifn=1
|
||||
|
@ -65,7 +65,7 @@ esac
|
||||
|
||||
case ${startstop} in
|
||||
[Ss][Tt][Aa][Rr][Tt] | '')
|
||||
if ifconfig ${interface} | grep -s UP,; then
|
||||
if ifconfig ${interface} | grep -s UP, > /dev/null 2>&1; then
|
||||
# Interface is already up, so ignore it.
|
||||
exit 0
|
||||
fi
|
||||
|
@ -146,6 +146,11 @@ network_start()
|
||||
|
||||
dhcp_interfaces=""
|
||||
for ifn in ${network_interfaces}; do
|
||||
if ifconfig ${ifn} | grep -s UP, > /dev/null 2>&1; then
|
||||
# Interface is already up, so ignore it.
|
||||
continue;
|
||||
fi
|
||||
|
||||
if [ -r /etc/start_if.${ifn} ]; then
|
||||
. /etc/start_if.${ifn}
|
||||
eval showstat_$ifn=1
|
||||
|
@ -209,7 +209,7 @@ network_pass1() {
|
||||
|
||||
dhcp_interfaces=""
|
||||
for ifn in ${network_interfaces}; do
|
||||
if ifconfig ${interface} | grep -s UP,; then
|
||||
if ifconfig ${ifn} | grep -s UP, > /dev/null 2>&1; then
|
||||
# Interface is already up, so ignore it.
|
||||
continue;
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user