Post by Pegasus1. Create the backup process.
2. Run it.
3. Perform a full restoration to an empty spare disk.
4. Repeat Step 3 once every 12 months.
5. Check the backup reports every week.
Many system administrators go no further than Step 2.
I check backup reports every day. My script parses and summarizes the
NTBackup log so the report is much more readable than the original log.
This code also removes detailed file lists but leaves "skipped file" errors.
[00] rem identify new log file name, by selecting last name in date-sorted
listing
[01] for /F "delims=" %%f in ('dir /B /A-D /OD "%_logfolder%\*.log"') do set
_logname=%%~nf
[02]
[03] rem add selected contents of log file to email body, by first
filtering log and saving output in temp file
[04] rem Not all possible NTBackup error messages are known, so this
selects what is not wanted and removes it.
[05] rem The filters remove non-essential stats, but leave error messages
and essential stats in their original order.
[06] rem Serial piping through find with /V switch performs the NOR
function [remove line if any string is found].
[07] rem The type command outputs ansi so findstr can be used [findstr
doesn't do unicode].
[08] type "%_logfolder%\%_logname%.log"|findstr /V "^$"|findstr /V
"^Folder"|find /V "/"|find /V "\Exchange\"|find /V "Backup Status"|find /V
"Operation: Backup"|find /V "Active backup destination:"|find /V "Media
name:"|find /V "Backup set #"|find /V "Backup description:"|find /V
"Directories:"|find /V "Skipped:"|find /V
"----------------------">D:\NTBackup\temp\ntbackuplog.txt
[09]
[10] rem read temp file and insert blank lines while writing it to the
email file
[11] rem put a blank line between one backed-up volume and the next, where
blank lines should be, instead of where ntbackup puts them
[12] rem last line for each volume begins with "Time:"
[13] for /F "tokens=1,2*" %%t in (D:\NTBackup\temp\ntbackuplog.txt) do (
[14] rem insert something BEFORE lines beginning with these words
[15] if [%%t]==[Verify] if [%%u]==[Status]
echo - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>D:\N
TBackup\temp\emailbody.txt
[16]
[17] rem insert the line of text from the log
[18] echo %%t %%u %%v>>D:\NTBackup\temp\emailbody.txt
[19]
[20] rem insert something AFTER lines beginning with these words
[21] if [%%t]==[Volume] echo/>>D:\NTBackup\temp\emailbody.txt
[22] if [%%t]==[Operation:] echo/>>D:\NTBackup\temp\emailbody.txt
[23] if [%%t]==[Time:] echo/>>D:\NTBackup\temp\emailbody.txt
[24] if [%%t]==[Reverting] echo/>>D:\NTBackup\temp\emailbody.txt
[25] )
--
Reply in group, but if emailing add another
zero, and remove the last word.