diff options
author | Kali Kaneko (leap communications) <kali@leap.se> | 2016-04-08 14:54:06 -0400 |
---|---|---|
committer | Kali Kaneko (leap communications) <kali@leap.se> | 2016-04-08 14:54:06 -0400 |
commit | 9f5d4c8c3d40f0f9b8959afdb8bd2c80e3935829 (patch) | |
tree | 38143ccdb3bd72cb618c9c37f6cbe5e4ae14b6b9 /get-client-cpu-mem.py | |
parent | 02c6b0ed8843e7863de13489d53f39c032f49e5f (diff) |
fixed graphing
Diffstat (limited to 'get-client-cpu-mem.py')
-rw-r--r-- | get-client-cpu-mem.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/get-client-cpu-mem.py b/get-client-cpu-mem.py index 0dd1aac..7dc9f26 100644 --- a/get-client-cpu-mem.py +++ b/get-client-cpu-mem.py @@ -1,6 +1,6 @@ import commands -pid = commands.getoutput('ps x | grep "[s]erver-solsync" | cut -d " " -f 2') +pid = commands.getoutput('ps x | grep "server-solsync" | head -n 1 | cut -d " " -f 2') res = commands.getoutput("ps -p " + pid + " -o \%cpu,\%mem") splitted = res.split() cpu = splitted[2] |