You are not logged in.

#1 2008-04-16 04:54:30

phperl
Member
Registered: 2007-10-03
Posts: 5

/etc/rc.d/network script work uncorrectly?

After I manually ifconfig eth0 down, run /etc/rc.d/network restart can't make eth0 up,
After debug the script,I find the following line in ifup function has a problem:
    [ "$(/sbin/ifconfig ${1} 2>/dev/null |\
                /bin/grep -v 'inet6 addr: fe80:' |\
                /bin/grep -e 'inet addr:' -e 'inet6 addr:')" ] && return 0
because the [ ... ] statement always eval true, so the function return,nothing is done.
I modify the statement as following:
    [ "$(/sbin/ifconfig ${1} 2>/dev/null |\
                /bin/grep -v 'inet6 addr: fe80:' |\
                /bin/grep -e '^ *UP')" ] && return 0
is it  a bug of the  script, can anyone test it?

Offline

#2 2008-04-16 13:12:32

jarryson
Member
Registered: 2007-02-18
Posts: 298

Re: /etc/rc.d/network script work uncorrectly?

many people have the same problem.

see : http://bugs.archlinux.org/task/9960

Offline

Board footer

Powered by FluxBB