Using below script I successfully use to check .zip file created for each Application on a specific date and at a specific Destination to get confirmed whether my Backup is successful or not.
Till now I use to check Backup Time only for _2230 but now I also want to include _2250 in this check.
So what I did is just changed: BACKUPTIME="_2230 _2250", but It doesn't seem to be working as I'm neither getting SUCCESSFUL nor FAILED status in Log.
- Can you please direct me where is the problem in my script ?
Could it have any impact on the speed of script I mean adding more TIME (_2230 and now _2250) to test for Backup ?
#!/bin/sh DATE=`date +%Y%m%d -d "1 days ago"` DESTINATION="/Network/Storage/Backup" LOG="/Network/Storage/Backup" BACKUPTIME="_2230" APPLICATION="DATADEV TESTREV PRETEST" for C in $APPLICATION do cd $DESTINATION/$C/ test -f $C$DATE$BACKUPTIME.zip if [ $? -eq 0 ] then echo "Backup SUCCESSFUL" >>$LOG/output.txt else echo "Backup FAILED" >>$LOG/output.txt fi done