Home
Categories
WIKI
Topic
User
LANGUAGE:
中文
English
NetworkManager的Event不起作用
Experiences and Insight
234
views ·
0
replies ·
To
floor
Go
tony19821016
deepin
2018-12-18 19:52
Author
我希望监听up事件,在启动时自动拨通我司自有格式的802.1x,这是我的脚本例子,该脚本在Ubuntu上正常,但是在Deepin中没有触发,用journalctl看日志看不到输出
#!/bin/bash
IF
=
$1
STATUS
=
$2
if
[
"
$IF
"
==
"ppp0"
]
then
case
"$2"
in
up
)
logger
-s
"NM Script up triggered"
command1
;;
down
)
logger
-s
"NM Script down triggered"
command2
;;
pre-up
)
logger
-s
"NM Script pre-up triggered"
command3
;;
post-down
)
logger
-s
"NM Script post-down triggered"
command4
;;
*
)
;;
esac
fi
Reply
Like 0
Favorite
View the author
All Replies
No replies yet
Please
sign
in first
Featured Collection
Change
[Tutorial] deepin25 WSL Offline Installation Guide
UOS AI 2.8 Released! Three New Intelligent Agents & Major Evolution
Solid Q&A | deepin 25 Common Questions – The Immutable System Edition
New Thread
Popular Ranking
Change
Copying folder - Not enough disk space?
Popular Events
More
#!/bin/bash
IF=$1
STATUS=$2
if["$IF"== "ppp0"]
then
case"$2"in
up)
logger -s"NM Script up triggered"
command1
;;
down)
logger -s"NM Script down triggered"
command2
;;
pre-up)
logger -s"NM Script pre-up triggered"
command3
;;
post-down)
logger -s"NM Script post-down triggered"
command4
;;
*)
;;
esac
fi