Backup Exec – Schedule a restart of the BE services via command line using bemcmd.exe
I’ve recently ran into a situation using a combination of Backup Exec 10d and 2 USB hard drives with the Backup-to-Disk Folders option. Every time the client switches out the USB drives, the backup drive would show Offline in BE causing the subsequent job to fail. The drive would show Online again if I manually selected the drive Online or restarted BE services. It seems this problem can be resolved by setting up a simple script to restart the BE services as a Scheduled Task before the next scheduled backup job using bemcmd.exe.
Here are the steps to start and stop the BE services using bemcmd.exe from the command prompt.
1. Click Start | Run, type CMD, and click OK
2. For Backup Exec 9.x and 10.x, type cd C:Program FilesVERITASBackup ExecNT
3. For Backup Exec 11.x and 12.x , type cd C:Program FilesSymantecBackup Exec
4. To stop all services for Backup Exec, type bemcmd -o503
a. If all services have stopped successfully, the response will be Return value 1
b. If there is a problem stopping the services, the response will be Return value 0
5. To start all services for Backup Exec, type bemcmd -o502
a. If all services have started successfully, the response will be Return value 1
b. If there is a problem starting the services, the response will be Return value 0
c. A return value of -1 indicates an error running the command.
This is what the script will look like for a typical Backup Exec 10d setup:
CD C:Program FilesVERITASBackup ExecNT
bemcmd -o503
bemcmd -o502
Simply save the file as a .bat file (ex BERestart.bat) in a convenient location and setup a scheduled task.