From fbd7bcea2a3e15730599b7ab19571388dec8bc55 Mon Sep 17 00:00:00 2001 From: midoks Date: Fri, 29 Jan 2021 18:42:39 +0800 Subject: [PATCH] up --- plugins/swap/index.html | 1 - plugins/swap/index.py | 6 ++---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/plugins/swap/index.html b/plugins/swap/index.html index 8711087f3..5b1b1f8f2 100755 --- a/plugins/swap/index.html +++ b/plugins/swap/index.html @@ -4,7 +4,6 @@

服务

自启动

配置修改

-

日志

diff --git a/plugins/swap/index.py b/plugins/swap/index.py index addedd5f0..50f4decfa 100755 --- a/plugins/swap/index.py +++ b/plugins/swap/index.py @@ -59,10 +59,8 @@ def getArgs(): def status(): - data = mw.execShell( - "ps -ef|grep swap |grep -v grep | grep -v python | grep -v mdserver-web | awk '{print $2}'") - - if data[0] == '': + data = mw.execShell("free -m|grep Swap|awk '{print $2}'") + if data[0] == '0': return 'stop' return 'start'