Fix checkzfs debug message

This commit is contained in:
thorsten.spille 2024-02-22 15:37:44 +01:00
parent f6fcd2f218
commit 99405ff827

View File

@ -315,7 +315,7 @@ done
if [ $checkzfs_disabled -eq 0 ]; then if [ $checkzfs_disabled -eq 0 ]; then
log "[INFO] Running checkzfs..." log "[INFO] Running checkzfs..."
echo "<<<local>>>" > /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix} echo "<<<local>>>" > /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix}
if [[ $debug == "-v" ]]; then log "[DEBUG] Command:\n$checkzfs --source $source --output checkmk --threshold $checkzfs_max_age --maxsnapshots $checkzfs_max_snapshot_count --prefix $checkzfs_prefix --filter \"$checkzfs_filter\" >> /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix}"; fi if [[ $debug == "-v" ]]; then log "[DEBUG] Command:\n$checkzfs --source $source:$sshport --output checkmk --threshold $checkzfs_max_age --maxsnapshots $checkzfs_max_snapshot_count --prefix $checkzfs_prefix --filter \"$checkzfs_filter\" >> /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix}"; fi
$checkzfs --source $source:$sshport --output checkmk --threshold $checkzfs_max_age --maxsnapshots $checkzfs_max_snapshot_count --prefix $checkzfs_prefix --filter "$checkzfs_filter" >> /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix} $checkzfs --source $source:$sshport --output checkmk --threshold $checkzfs_max_age --maxsnapshots $checkzfs_max_snapshot_count --prefix $checkzfs_prefix --filter "$checkzfs_filter" >> /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix}
if [ $checkzfs_spool -eq 0 ]; then if [ $checkzfs_spool -eq 0 ]; then
$mv /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix} /var/lib/check_mk_agent/spool/ $mv /tmp/${checkzfs_spool_maxage}_${checkzfs_prefix} /var/lib/check_mk_agent/spool/