The purpose of this document is to archive the process I followed in order to get USB swapping working without user intervention in Backup Exec 11d. This document is NOT intended as a HOW-TO, only a rough guide.
This outlines the ability to swap back and forth between 2 or more USB drives and have the backup job run without the need for any user to manually bring different Backup-to-Disk Folders back online.
You will need some “Special Sauce” for this to work. It is a third party application called USBDLM. USBDLM, among many other options, allows you to hard set a windows assigned drive letter to the unique Device ID of a USB drive. This is crucial to the success of many USB swapping scenarios.
Format and Assign Drive letters:
Format your USB drives and name them accordingly. I name them BackupUSB1 and BackupUSB2 or something similar.
Download and Configure USBDLM
Copy USBDLM to C:\Tools\
Find USB Dev ID’s for Drives:
Run C:\Tools\USBDLM\List_USB_Drives_to_Notepad.cmd
Look for this string under each drive leter:
Ctrl DevID = USB\VID_xxxxxxxxxx
You need this string for each drive you need to assign drive letters to.
Create the USBDLM.ini file:
[Settings]
NoMediaNoLetter=0
WriteLogFile=0
LogFile=
LogLevel=3
[BalloonTips]
Enabled=1
Timeout=6000
[DriveLetters]
Letter1=
Letter2=
Letter3=
[DriveLetters10]
DeviceID1=USB\VID_13FD&PID_1340\4A503639333048443230524C
Letter1=M
[DriveLetters20]
DeviceID1=USB\VID_13FD&PID_1340\4A5032393430485133544744
Letter1=N
[NetworkLetters]
Letter1=
Letter2=
Letter3=
Run _install.cmd to register USBDLM service.
Your USB Drives will now be assigned the drive letters M and N. Everytime you plug in the drive it will be assigned this letter.
Setup and Configure Backup Exec for the USB Drives.
Create the Storage Devices.
In Backup Exec, choose Devices.
Right-Click on Backup-to-Disk Folders. (Removable Backup-to-Disk Folders is only for use with Zip and Jazz and CDRW type devices.)
Name the first one “USB_BACKUP1” or similar.
Make sure you choose “Allocate the maximum size for backup-to-disk files” and on the Advanced tab, be sure that “Disk space reserve” is unchecked.
Choose the Path to the USB drive M:
Click OK.
Do the same for the second USB drive changing the name to “USB_BACKUP2” and the Path to N:
Create a Storage pool for the USB Drives.
In Backup Exec, choose Devices.
Right-Click on “Device Pools”, Choose “New Device Pool”.
Name the Pool “USBDRIVES”
Check the boxes next the USB Drives.
Click OK.
Create the Pause/Unpause script for the USB Drives.
Create a batch file in C:\Tools\ResetDrives.bat with the following:
# Batch file to Pause and unpause B2D Folders
#Get into the backup exec folder. The command won’t run if you’re not in there.
CD C:\"Program Files"\Symantec\"Backup Exec"\
# Pause USB1
bemcmd -o60 -d:"USB_BACKUP1"
# Pause USB2
bemcmd -o60 -d:"USB_BACKUP2"
#Using Ping to Wait 10Sec
Ping –n 11 127.0.0.1
# Unpause USB1
bemcmd -o61 -d:"USB_BACKUP1"
# Unpause USB2
bemcmd -o61 -d:"USB_BACKUP2"
#Using Ping to Wait 10Sec
Ping –n 11 127.0.0.1
# Pause USB1
bemcmd -o60 -d:"USB_BACKUP1"
# Pause USB2
bemcmd -o60 -d:"USB_BACKUP2"
#Using Ping to Wait 10Sec
Ping –n 11 127.0.0.1
# Unpause USB1
bemcmd -o61 -d:"USB_BACKUP1"
# Unpause USB2
bemcmd -o61 -d:"USB_BACKUP2"
Create a Backup Job.
In Backup Exec, choose Media.
Create a new Media Set for a Daily Job.
Choose Job Setup. Create new Backup.
During the Creation of the Backup Job, under “Destination – Devices and Media”, be sure you choose the Device “USBDRIVES” and The correct Media Set.
Under Settings – “Pre/Post Commands” in the Pre-command, Type:
C:\Tools\ResetDrives.bat
Leave the box checked “Run job only if pre-command is successful”
Be sure to uncheck “Allow pre- and post-commands to be successful only is completed with a return code of zero.” If you check this box the Backup will fail as the Return code is “1” or “-1”
Create a Scheduled Task for the ResetDrives.Bat (optional)
Create a Scheduled Task to run in Windows every 1 Hour form 1am to 11pm.
Add the ResetDrives batch to the AutoRun of the USBDLM.
Add this line to the end of the USBDLM.ini file in C:\Tools\USBDLM
[OnArrival10]
Workdir=”C:\Program Files\Symantec\Backup Exec\”
Open=C:\Tools\ResetDrives.bat
Run the cmd:
>net stop USBDLM
>net start USBDLM
May I ask why you would set ResetDrives Task to run every hour at 1 am? Are you assuming the backup would be complete before 1AM?
ReplyDelete@HurricaneHernadez - I am running that to reset the drives before the next backup drive swap. To ensure that the drives pools will be swapped in Backup Exec at the next time the Backup runs. Running the Reset drives command while the backup is already running will simply pause the backup and resume if it is already in progress so there is no risk to stopping the Job and all the benefits of making sure the drives are available.
ReplyDelete