Quantcast
Channel: Symantec Connect - Backup and Recovery - Discussions
Viewing all articles
Browse latest Browse all 6307

Configuring or getting dbclient log name

$
0
0
I need a solution

Hi, 

I'm trying to automate  SqlServer Backups by executing from control-m, which is a 3rd party schedule software. 

To do this, I have created a .bat file that call the Netbackup exec file (dbbackex.exe).  

I use this code to do this: 

echo "Starting SqlServer Backup on  %COMPUTERNAME% "> C:\backuplog.log
"C:\Program Files\Veritas\NetBackup\bin\dbbackex" -f C:\bcktest.bch -p nopr_bdd_msql_all -s back -np >> C:\backuplog.log

echo %date% %time% >> C:\backuplog.log
echo "Backup Finished ">> C:\backuplog.log

IF %ERRORLEVEL% GTR 0 echo "Backup Finished with ERROR [%ERRORLEVEL%]">> C:\backuplog.log
IF %ERRORLEVEL% EQU 0 echo "Backup Finished SUCCESSFULLY">> C:\backuplog.log

echo "Review log file:  C:\Program Files\Veritas\NetBackup\logs\user_ops\MsSql\Logs">> C:\backuplog.log

I would like to get the ERROR message, not only the code, using this script and if not possible, get dbclient log name to complete the last line and show something like:

Review log file:  C:\Program Files\Veritas\NetBackup\logs\user_ops\MsSql\Logs\0714115143814-55584-20776-000-000-prg

Does anyone know if this is possible and how could I do this? Or is it possible to configure de path and logfile name?

Other posibility I'm thinking of is manage error codes on my own, but I would need Error code list and cannot find it. Does anyone know if this exist?

I would accept any other suggestion to get error information. I cannot use any other code but cmd/bat. 

Thanks in Advance, 

Elena 


Viewing all articles
Browse latest Browse all 6307

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>