%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /backups/router/usr/local/share/munin/plugins/
Upload File :
Create Path :
Current File : //backups/router/usr/local/share/munin/plugins/zfs_compress

#!/bin/sh

set -e
set -u

cat <<'EOM'
graph_title ZFS dataset compression ratio 
graph_vlabel ratio 
graph_category ZFS
graph_info This graph shows the ZFS dataset compression ratio
EOM

listing=$(zfs get -t filesystem -H compressratio)

while read -r label _ ratio _; do
	clean_label=$(echo "${label}" | sed -e 's|/|__|g')
	echo "${clean_label}.label ${label}"
	echo "${clean_label}.value ${ratio%x}"
done <<eot
${listing}
eot

exit 0



Zerion Mini Shell 1.0