first commit

This commit is contained in:
Patrick Stadler
2015-02-19 20:15:38 +01:00
commit ae2ec619d3
6 changed files with 170 additions and 0 deletions

2
metrics/cpu.sh Normal file
View File

@@ -0,0 +1,2 @@
#!/bin/sh
echo $(ps aux | awk {'sum+=$3;print sum'} | tail -n 1)

2
metrics/memory.sh Normal file
View File

@@ -0,0 +1,2 @@
#!/bin/sh
echo $(free | awk '/buffers\/cache/{print $4/($3+$4) * 100.0;}')

2
metrics/swap.sh Normal file
View File

@@ -0,0 +1,2 @@
#!/bin/sh
echo $(free | awk '/Swap/{print $3/$2 * 100.0;}')