Fixed spelling mistake in log output

pull/195/head
Christhonie Geldenhuys 5 years ago
parent ab1e72a5bc
commit 0d83e9f4e5

@ -41,19 +41,19 @@ def start_worker(serv):
port = sql.get_setting('haproxy_sock_port') port = sql.get_setting('haproxy_sock_port')
cmd = "tools/checker_worker.py %s --port %s &" % (serv, port) cmd = "tools/checker_worker.py %s --port %s &" % (serv, port)
os.system(cmd) os.system(cmd)
funct.logging("localhost", " Masrer started new worker for: "+serv, alerting=1) funct.logging("localhost", " Master started new worker for: "+serv, alerting=1)
def kill_worker(serv): def kill_worker(serv):
cmd = "ps ax |grep 'tools/checker_worker.py %s'|grep -v grep |awk '{print $1}' |xargs kill" % serv cmd = "ps ax |grep 'tools/checker_worker.py %s'|grep -v grep |awk '{print $1}' |xargs kill" % serv
output, stderr = funct.subprocess_execute(cmd) output, stderr = funct.subprocess_execute(cmd)
funct.logging("localhost", " Masrer killed worker for: "+serv, alerting=1) funct.logging("localhost", " Master killed worker for: "+serv, alerting=1)
if stderr: if stderr:
funct.logging("localhost", stderr, alerting=1) funct.logging("localhost", stderr, alerting=1)
def kill_all_workers(): def kill_all_workers():
cmd = "ps ax |grep 'tools/checker_worker.py' |grep -v grep |awk '{print $1}' |xargs kill" cmd = "ps ax |grep 'tools/checker_worker.py' |grep -v grep |awk '{print $1}' |xargs kill"
output, stderr = funct.subprocess_execute(cmd) output, stderr = funct.subprocess_execute(cmd)
funct.logging("localhost", " Masrer killing all workers", alerting=1) funct.logging("localhost", " Master killing all workers", alerting=1)
if stderr: if stderr:
funct.logging("localhost", stderr, alerting=1) funct.logging("localhost", stderr, alerting=1)

@ -65,12 +65,12 @@ def start_worker(serv):
port = sql.get_setting('haproxy_sock_port') port = sql.get_setting('haproxy_sock_port')
cmd = "tools/metrics_worker.py %s --port %s &" % (serv, port) cmd = "tools/metrics_worker.py %s --port %s &" % (serv, port)
os.system(cmd) os.system(cmd)
funct.logging("localhost", " Masrer started new metrics worker for: "+serv, metrics=1) funct.logging("localhost", " Master started new metrics worker for: "+serv, metrics=1)
def kill_worker(serv): def kill_worker(serv):
cmd = "ps ax |grep 'tools/metrics_worker.py %s'|grep -v grep |awk '{print $1}' |xargs kill" % serv cmd = "ps ax |grep 'tools/metrics_worker.py %s'|grep -v grep |awk '{print $1}' |xargs kill" % serv
output, stderr = funct.subprocess_execute(cmd) output, stderr = funct.subprocess_execute(cmd)
funct.logging("localhost", " Masrer killed metrics worker for: "+serv, metrics=1) funct.logging("localhost", " Master killed metrics worker for: "+serv, metrics=1)
if stderr: if stderr:
funct.logging("localhost", stderr, metrics=1) funct.logging("localhost", stderr, metrics=1)
@ -78,19 +78,19 @@ def start_waf_worker(serv):
port = sql.get_setting('haproxy_sock_port') port = sql.get_setting('haproxy_sock_port')
cmd = "tools/metrics_waf_worker.py %s --port %s &" % (serv, port) cmd = "tools/metrics_waf_worker.py %s --port %s &" % (serv, port)
os.system(cmd) os.system(cmd)
funct.logging("localhost", " Masrer started new WAF metrics worker for: "+serv, metrics=1) funct.logging("localhost", " Master started new WAF metrics worker for: "+serv, metrics=1)
def kill_waf_worker(serv): def kill_waf_worker(serv):
cmd = "ps ax |grep 'tools/metrics_waf_worker.py %s'|grep -v grep |awk '{print $1}' |xargs kill" % serv cmd = "ps ax |grep 'tools/metrics_waf_worker.py %s'|grep -v grep |awk '{print $1}' |xargs kill" % serv
output, stderr = funct.subprocess_execute(cmd) output, stderr = funct.subprocess_execute(cmd)
funct.logging("localhost", " Masrer killed WAF metrics worker for: "+serv, metrics=1) funct.logging("localhost", " Master killed WAF metrics worker for: "+serv, metrics=1)
if stderr: if stderr:
funct.logging("localhost", stderr, metrics=1) funct.logging("localhost", stderr, metrics=1)
def kill_all_workers(): def kill_all_workers():
cmd = "ps ax |grep -e 'tools/metrics_worker.py\|tools/metrics_waf_worker.py' |grep -v grep |awk '{print $1}' |xargs kill" cmd = "ps ax |grep -e 'tools/metrics_worker.py\|tools/metrics_waf_worker.py' |grep -v grep |awk '{print $1}' |xargs kill"
output, stderr = funct.subprocess_execute(cmd) output, stderr = funct.subprocess_execute(cmd)
funct.logging("localhost", " Masrer killing all metrics workers", metrics=1) funct.logging("localhost", " Master killing all metrics workers", metrics=1)
if stderr: if stderr:
funct.logging("localhost", stderr, metrics=1) funct.logging("localhost", stderr, metrics=1)

Loading…
Cancel
Save