diff options
author | Jan Macku <jamacku@redhat.com> | 2020-12-17 08:31:46 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-17 08:31:46 +0100 |
commit | 9babd3713c55790ddeb81c1ca8c27cbd594e5508 (patch) | |
tree | ded0e11d78c28d3025b0222094fbc5020e7e8715 | |
parent | 24d21b0baaf914ff65837ab45dcc7063b7808f6f (diff) | |
download | initscripts-9babd3713c55790ddeb81c1ca8c27cbd594e5508.tar initscripts-9babd3713c55790ddeb81c1ca8c27cbd594e5508.tar.gz initscripts-9babd3713c55790ddeb81c1ca8c27cbd594e5508.tar.bz2 initscripts-9babd3713c55790ddeb81c1ca8c27cbd594e5508.tar.xz initscripts-9babd3713c55790ddeb81c1ca8c27cbd594e5508.zip |
network: fix set_link_up()
This patch fixes issue, when interface wasn't
bring up.
Related: #1555001
(cherry picked from commit 17f1519e0dac05bf6b259ef9b7f8dcd6b94013ce)
-rw-r--r-- | network-scripts/network-functions | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/network-scripts/network-functions b/network-scripts/network-functions index 5f6c72d4..bc046f54 100644 --- a/network-scripts/network-functions +++ b/network-scripts/network-functions @@ -455,10 +455,8 @@ check_device_down () set_link_up () { - if [ "$LINKSTATUS" = down ]; then + if [ "$LINKSTATUS" != up ]; then ip link set dev $1 up >/dev/null 2>&1 - else - grep -qsx 1 /sys/class/net/$1/carrier fi } |