diff --git a/scripts/init.d/mw.tpl b/scripts/init.d/mw.tpl index 236c57a63..79a566f59 100755 --- a/scripts/init.d/mw.tpl +++ b/scripts/init.d/mw.tpl @@ -104,7 +104,7 @@ mw_start() # /www/server/mdserver-web/tmp/panelTask.pl && service mw restart_task mw_stop_task() { - if [ -f ${PANEL_DIR}/tmp/panelTask.pl ];then + if [ -f ${PANEL_DIR}/logs/panel_task.lock ];then echo -e "\033[32mthe task is running and cannot be stopped\033[0m" exit 0 fi diff --git a/web/core/mw.py b/web/core/mw.py index 287c9bae7..7f581af31 100644 --- a/web/core/mw.py +++ b/web/core/mw.py @@ -665,7 +665,7 @@ def isRestart(): return True def triggerTask(): - isTask = getPanelDir() + '/tmp/panelTask.pl' + isTask = getPanelDir() + '/logs/panel_task.lock' writeFile(isTask, 'True') def restartTask():