First, I am running Veeam 9.0.0.1491 on Windows server 2008 R2.
We have some application/database server pairs that that are backed up. When the snapshot commits after the backup, sometimes the application listeners that communicate with the DB servers hiccup. They still run, but the connection is broken long enough, that the application no longer works. The usual fix is to restart any application listeners.
I thought this would be a great opportunity to try a post processing script. I created a backup job for 2 Windows servers, one an application server, one a database server. At the end of the job, I want Windows services on each server to restart.
Since I can only run one post processing script per job, I have all the commands in the same .bat file. The commands are:
Code: Select all
@echo off
REM This will stop the windows services
sc stop developmentSQL_APP_LISTENER
sc stop developmentSQL_DB_LISTENER
REM This will pause this script for 30 seconds
timeout /t 30
REM This will start the windows services
sc start developmentSQL_DB_LISTENER
timeout /t 10
sc start developmentSQL_APP_LISTENER
First, the script is hosted on the Veeam B&R server, but the command are run on the servers that are being backed up, correct?
Second, the call to stop and start a service that does not run on one server, will fail, but the call to stop and stop a service that does run on the server should succeed, correct?
Unfortunately, there are no Windows event log entries on either server indicating that the service stopped or started.
Furthermore, from the Veeam backup job log, there is the following warning:
11/21/2016 5:37:38 PM :: Post-job script terminated with exit code 1060
From what I am describing, am I doing this correctly? I realize I can configure backup jobs that only process one server. However, since jobs do queue, I don't want one server's listener to restart, then have the other backup job break the app server/DB server connection again.
Any feedback and advice will be greatly appreciated.
Thanks,
Ken