diff --git a/metrology/collectd_exec_xmpp.sh b/metrology/collectd_exec_xmpp.sh index 37c8153..2e6f549 100755 --- a/metrology/collectd_exec_xmpp.sh +++ b/metrology/collectd_exec_xmpp.sh @@ -32,7 +32,7 @@ ejabberdctl_stats() { http_upload_disk_usage() { subfolders_count=$(find ${HTTP_UPLOAD_DATADIR} -mindepth 1 -maxdepth 1 -type d | wc -l) - total_size=$(du -s ${HTTP_UPLOAD_DATADIR} | awk '{print $1}') + total_size=$(du --exclude=lost+found -s ${HTTP_UPLOAD_DATADIR} | awk '{print $1}') avg=$(( ${total_size} / ${subfolders_count} )) echo "PUTVAL \"${HOSTNAME}/xmpp_upload_data_total/count\" interval=$INTERVAL $(date +%s):${total_size}" echo "PUTVAL \"${HOSTNAME}/xmpp_upload_data_avg/count\" interval=$INTERVAL $(date +%s):${avg}"