From 08adb9935d28b9e9d2e91e6beeeb6cdbd0fc6e5e Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Tue, 16 Feb 2010 15:17:03 -0500 Subject: Use NM if it's running and we have a configuration for the device. --- sysconfig/network-scripts/ifdown | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'sysconfig/network-scripts/ifdown') diff --git a/sysconfig/network-scripts/ifdown b/sysconfig/network-scripts/ifdown index a0cc0c9e..9c9112cb 100755 --- a/sysconfig/network-scripts/ifdown +++ b/sysconfig/network-scripts/ifdown @@ -41,6 +41,15 @@ then exit 0 fi +if [ "$USE_NM" = "true" -a -n "$NAME" -o -n "$UUID" ]; then + if [ -n "$UUID" ]; then + nmcli con down uuid "$UUID" + elif [ -n "$NAME" ]; then + nmcli con down id "$NAME" + fi + exit $? +fi + if [ -x /sbin/ifdown-pre-local ]; then /sbin/ifdown-pre-local ${DEVICE} fi -- cgit v1.2.1