To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here

WinDrivers Computer Tech Support Forums  

Go Back   WinDrivers Computer Tech Support Forums > Operating Systems > Windows NT/2000

Windows NT/2000 Get support help for all versions of Windows NT/2000.

Reply
 
Thread Tools Search this Thread Display Modes
Old January 20th, 2004, 11:16 AM   #1
opiate
Registered User
 
Join Date: Oct 2000
Location: Kansas City, MO
Posts: 1,156
Probs w/ NTBackup command line script

Here is the script I would like to run for daily incremental backups. When I open up the NTBackup log here is the error I get when the script runs.
"The operation was not performed because an invalid Removable storage GUID was specified."

Here is the script:

REM - Finding tape name for SEW80201 Incremental
rem ECHO OFF
:checkmedia
set media=
for /f "Tokens=*" %%a in ('rsm view /cg4187295E74AB40C2A36EA0A1DA1CCCCD /TPhysical_media /guiddisplay') do (
if not "%%a"=="The command completed successfully." set media="%%a"
)
if /i %media% EQU "Unable to open session with the RSM server." goto checkmedia
if /i %media% EQU "PHYSICAL_MEDIA" goto notape
if not defined media goto notape

rsm.exe refresh /LF"Hewlett Packard LTO Ultrium tape drive"

sleep 30
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%
c:\winnt\system32\ntbackup.exe backup "@C:\ntbackupjobs\SEW80201-backup.bks" /j "%computername% %dtt%" /G "%media%" /d "%computername% %dtt%" /a /v:no /r:no /rs:no /hcn /m incremental



This script finds the current media guid, formats the current date and lables the incremental tape. You must reference the media guid. I have found that when the variable %media% is returned it looks like ""DAEFBAFF5FBB402B9995F98257C8D2D9"" for some reason it automatically adds "". I've removed mine so the line reads /G %media% but this dosent work. I also tried the tape name and the variable will return "SEW80201 - Incrementa 01-20-200 - 1" as the tape name. But I get the same error as above except insted of saying guid it says tape name. For some reason it adds the "- 1" to the end of the tape. Does anyone know what could be the problem? How could I trim off the "- 1" from the end of the tape name.
opiate is offline   Reply With Quote
Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 10:39 PM.



Acceptable Use Policy

internet.comMediabistrojusttechjobs.comGraphics.com

WebMediaBrands Corporate Info


Advertise | Newsletters | Feedback | Submit News

Legal Notices | Licensing | Permissions | Privacy Policy

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.