mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-01 15:13:56 +08:00
🌴 Sync 2026-03-05 23:51:42
This commit is contained in:
1 parent
97c049ed0a
commit
0acff03804
14253 files changed
+3893239
No files matched your search
+22
@@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
|
||||
PATH="/usr/sbin:/usr/bin:/sbin:/bin"
|
||||
echo "1" > /var/run/onsetnlbw
|
||||
interval=$(uci get nlbwmon.@nlbwmon[0].refresh_interval)
|
||||
uci set nlbwmon.@nlbwmon[0].refresh_interval="2s"
|
||||
/etc/init.d/nlbwmon reload
|
||||
|
||||
while true
|
||||
do
|
||||
sleep 12
|
||||
watchdog=$(cat /var/run/onsetnlbw)
|
||||
if [ "$watchdog"x == "0"x ]; then
|
||||
uci set nlbwmon.@nlbwmon[0].refresh_interval=$interval
|
||||
uci commit nlbwmon
|
||||
/etc/init.d/nlbwmon reload
|
||||
rm -f /var/run/onsetnlbw
|
||||
exit 0
|
||||
else
|
||||
echo "0" > /var/run/onsetnlbw
|
||||
fi
|
||||
done
|
||||
Reference in new issue
Block a user