From ec7c088ad300e79a4bed6310c3a19e6c9bc03c4e Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Wed, 17 Feb 2010 15:32:22 -0500 Subject: When bringing devices down, disconnect the device, don't down the connection. --- sysconfig/network-scripts/network-functions | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sysconfig/network-scripts/network-functions') diff --git a/sysconfig/network-scripts/network-functions b/sysconfig/network-scripts/network-functions index 8ae752ba..a29c9764 100644 --- a/sysconfig/network-scripts/network-functions +++ b/sysconfig/network-scripts/network-functions @@ -200,6 +200,11 @@ is_nm_running () LANG=C nmcli nm status | grep -Eq "NM running:[[:space:]]+running" } +is_nm_active () +{ + LANG=C nmcli -t dev status | grep -Eq "^${1}[[:space:]]*.*[[:space:]]*connected$" +} + # Sets $alias to the device module if $? != 0 is_available () { -- cgit v1.2.1