added files and tasks

This commit is contained in:
rene
2022-02-21 15:49:29 +01:00
parent 5cfa94d384
commit 4a380cd902
22 changed files with 1305 additions and 20 deletions

View File

@@ -0,0 +1,29 @@
#!/bin/bash -
#===============================================================================
#
# FILE: jitsi-statistics.sh
#
# USAGE: ./jitsi-statistics.sh
#
# DESCRIPTION:
#
# OPTIONS: ---
# REQUIREMENTS: ---
# BUGS: ---
# NOTES: ---
# AUTHOR: YOUR NAME (),
# ORGANIZATION:
# CREATED: 02/15/2021 13:14
# REVISION: ---
#===============================================================================
set -o nounset # Treat unset variables as an error
# cpu
awk '{u=$2+$4; t=$2+$4+$5; if (NR==1){uuu1=u; ttt1=t;} else print ($2+$4-u1) * 100 / (t-t1) ""; }' <(grep 'cpu ' /proc/stat) <(sleep 1;grep 'cpu ' /proc/stat) > /usr/share/jitsi-meet/cpu.txt
#memory
free -m | awk 'NR==2{printf "%s", $3 }' > /usr/share/jitsi-meet/memory.txt
# statistic
rm /usr/share/jitsi-meet/stats.json
curl -s http://127.0.0.1:8080/colibri/stats >> /usr/share/jitsi-meet/stats.json