From 230e46830f5d6915c8203c6e75497973ac48bc8c Mon Sep 17 00:00:00 2001 From: Jakub Jankowski Date: Tue, 21 Nov 2017 02:29:57 +0100 Subject: rc.inet1: Test for loopback being "state UNKNOWN" too. On my system "ip link set dev lo up" does not put it into UP state, but rather UNKNOWN. So test for either when trying to decide whether we need to set it up. Signed-off-by: Robby Workman --- rc.inet1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rc.inet1 b/rc.inet1 index 3c9d5c2..6b88d2a 100644 --- a/rc.inet1 +++ b/rc.inet1 @@ -51,7 +51,7 @@ fi # already up, do nothing. lo_up() { if grep lo: /proc/net/dev 1> /dev/null ; then - if ! /sbin/ip link show dev lo | grep -wq "state UP" ; then + if ! /sbin/ip link show dev lo | grep -wq -e "state UP" -e "state UNKNOWN" ; then echo "/etc/rc.d/rc.inet1: /sbin/ip address add 127.0.0.1/8 dev lo" | $LOGGER /sbin/ip address add 127.0.0.1/8 dev lo /sbin/ip link set dev lo up -- cgit v1.2.3