basic script flow implemented

This commit is contained in:
Patrick Stadler
2015-02-21 18:18:27 +01:00
parent ae2ec619d3
commit 5d3a3fcdb1
8 changed files with 71 additions and 7 deletions

View File

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

View File

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

View File

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