Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Ntbackup batch file Backup Report

Status
Not open for further replies.

kimble

Technical User
Aug 23, 2001
107
US
I am trying to use NTbackup on a W2K3 Web Edition server to backup the entire system nightly. I have followed the following article:


Which helped me produce the following batch file:

rsm.exe refresh /lf"Dell (tm) PowerVault (tm) 100T DAT72"

C:\WINDOWS\system32\ntbackup.exe backup "@C:\Documents and Settings\Administrator\Local Settings\Application Data\Microsoft\Windows NT\NTBackup\data\FullBackup.bks" /n "Media created 4/9/2006 at 10:28 PM" /d "Set created 4/9/2006 at 10:30 PM" /v:yes /r:no /rs:no /hc:eek:n /m normal /j "Nightly Full Backup" /l:n /p "4mm DDS" /um

I believe the tape runs because the scheduler shows it ran and the physical brand new tape shows it was unwound and rewound about a 1/8 of an inch on the wheel. The problem is the .bks file is no where to be found and the "Tools-->Reports" window in NTbackup doens't show the backup. It will show the media, but i can't check it off to see if there is anything on the tape.

The last post in the following thread may be part of the answer but i don't really understand what its saying.

thread96-737458

Otherwise the tapes are marked as "Free" as the microsoft article stated and i'm using the /um switch.

Please help me solve the final piece of the puzzle.

Thanks
s
 
Probably your backup jobs are running under different account, not yours. In this case you will find backup logs in this location:
"C:\Documents and Settings\Username under which account the job was run\Local Settings\Application Data\Microsoft\Windows NT\NTBackup\data"

===
Karlis
ECDL; MCSA
 
I am running it under the administrator account. When I try to check the log I also am under the administrator account. I believe part of my problem was the \l:n switch (no summary), I've since changed it to \l:f (full summary). This though has not solved the problem. I also checked the batch file in the scheduler and the check box for "Run only if logged in" is not checked off. The scheduler also notes the job ran last night. Yet in NTbackup i don't see the job.

I now also understand the batch file from the thread thread96-737458

The section of code i didn't understand is where it creates a date variable so you're not hard coding in a sepcific date in the log summary.

Any other ideas on why I can't see the job in NTBackup? Do i have to somehow load it?

Here is my current batch file that runs successfully if i manually start it:

REM this to prevet problems with the media datapool you
REM need to copy sleep.exe to \winnt\system32
net stop ntmssvc
sleep 60
net start ntmssvc
sleep 60
REM Set the backup device
rsm.exe refresh /lf"Dell (tm) PowerVault (tm) 100T DAT72"
sleep 60
REM Set the date variable
for /f "Tokens=1-4 Delims=/ " %%i in ('date /t') do set dt=%%i-%%j-%%k-%%l
for /f "Tokens=1" %%i in ('time /t') do set tm=-%%i
set tm=%tm::=-%
set dtt=%dt%%tm%
sleep 60
C:\WINDOWS\system32\ntbackup.exe backup "@C:\Documents and Settings\Administrator\Local Settings\Application Data\Microsoft\Windows NT\NTBackup\data\Phosaic Full Backup.bks" /n "Media created %dtt%" /d "Media created %dtt%" /v:yes /r:no /rs:no /hc:eek:n /m normal /j "Phosaic Full Backup %dtt%" /l:f /p "4mm DDS" /um
sleep 60
rsm.exe eject /PF"Media created %dtt%-1" /astart

 
From what I gather the l:n switch was the trick. The above code for the batch file is working!

s
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top