Merci pour cette commande apparemment très précieuse et qui m'a
révélé laprès quelues essais le problème... Plusieurs fautes de
syntaxe. (espaces manquants, accolades mal placées,etc )
le script qui marche est le suivant:
#Checking the capacity of backup disk- If too low, exiting
capacityLimit=50
backupVolumeUsage=`df /Volumes/Mon_Volume | grep -v Filesystem | awk
'{print int($5)}'`
echo -n "[*]:Checking Backup disk capacity" | logger
if [ ${backupVolumeUsage} -gt ${capacityLimit} ]; then
echo "Backup volume has insufficient capacity! - Backup aborted !">>
$TEMP
cat $TEMP>>$rapport
echo -n "[*]: BackupVolume insufficient! - Exiting" | logger
exit 0
fi
_______________________________________________
archives :
http://listes.patpro.net/list/sshfr.fr.html
http://listes.patpro.net/mailman/listinfo/script_shell_fr