Video Screencast Help
Search Video Help Close Back
to help
Not able to make it to Vision this year? Get a sampling in the Best of Vision on Demand group.

Change default directory for bpstart_notify.bat in NB6.5

Updated: 21 May 2010 | 6 comments
Philip Drew's picture
0 0 Votes
Login to vote

Hi All,

 

I'm about to deploy a new Veritas Netbackup 6.5 environment using SAN snaps / scripts for 150 servers.

 

I would like to change the default directory from C:\program files\veritas\netbackup bin to another folder i.e. C:\Netbackup_scripts\

 

Does anyone know if there is a registry key that I can change to change this.


Thanks in advance.

Comments

Manoj Siricilla's picture
17
Oct
2008
0 Votes 0
Login to vote

you should fina all your netbackup keys in the following location

 

HKEY_LOCAL_MACHINE\SOFTWARE\VERITAS\NetBackup\CurrentVersion

  

you probably should be looking at the keys

 

INSTALLDIR, INI Directory, Log Directory

 

bp.conf on windows is under the folder CurrentVersion of above path as the folder Config

 

Message Edited by Manoj Siricilla on 10-17-2008 10:53 AM

Cheers!
Manoj
------------------
Time isn't running out, but life is...

sdw303's picture
18
Oct
2008
0 Votes 0
Login to vote

Here's what to do - at your own risk - I'm not responsible for any mistakes that you may make whilst using regedit.

 

 

1) CD to your goodies folder, e.g.

$ cd "C:\Program Files\VERITAS\NetBackup\bin\goodies"

 

2) listpaths > "%temp%\pre.txt"

 

3) regedit

...and browse to:

HKLM\SOFTWARE\Veritas\NetBackup\CurrentVersion\Paths

 

4) Create a new REG_SZ key named:

BPEND_NOTIFY

...and give it a value to the full path of your new bpend_notify script, e.g.:

C:\\NetBackup_Script\\bpend_notify.cmd

 

N.B. remember to use double back slashes... "\\" 

 

 

5) listpaths > "%temp%\post.txt"

 

6) fc "%temp%\pre.txt" "%temp%\post.txt"

To prove that the new path will be used.

 

 

And do similar for BPSTART_NOTIFY registry key if you wish.

 

 

HTH.

Message Edited by sdw303 on 10-18-2008 01:34 PM
sdw303's picture
18
Oct
2008
0 Votes 0
Login to vote

Further points:

 

Maintenance patch kits overwrite any modification you make to any of the notify scripts, i.e. any site specific mods are replaced with default scripts - BUT you shouldn't be affected because your scripts will actually reside in a different folder - BUT I can't confirm whether the patch installer will process/use your new registry keys and thus overwrite your scripts.  So take a backup (see below).

 

Also, I don't know whether a maintence pack will remove your site specific registry key tweaks for script paths.  So, always make a note of any mods that you make in your recovery/rebuild documentation.

 

Personally, I would create a new backup policy to backup your scripts folder - as you would with any other live production data/code.  Don't be tempted to backup the entire volume - as you may end up taking your catalog too - and don't (as I have seen in the past) then be tempted to then exclude the catalog directory in the client (i.e. master) folder/path/file exclusions list - as this will in turn mean that your hot catalog backup skips your catalog path - thus rendering your catalog backup useless.   So, just backup the scripts folder (plus any other non standard NetBackup folders that you might be using).  Keep it simple.

Philip Drew's picture
21
Oct
2008
0 Votes 0
Login to vote

Thanks SDW303 for your advice.


I have tried it step by step and several reboots of the server and it doesn't work now I have moved the scripts into the new (and specified) directory.  I have even tried changing the bpstart_notify.cmd setting in the registry to bpstart_notify.bat.

 

Even though the listpaths script gave the correct details of the path it still didn't use it. 

 

Any further advice greatfully received :D

Message Edited by Philip Drew on 10-21-2008 09:48 AM
sdw303's picture
21
Oct
2008
0 Votes 0
Login to vote

Did "listpaths" definitely show the new path and file name?

 

Did you use double backslashes "\\" in the path-name file specification?

 

Is the drive, all folders in the tree, and the script files all readable by "everyone"?  If the script contains code that writes to disk (e.g. a temporary file of some sort) does the NetBackup process (which usually runs as NT_System_Authority) has access rights?

sdw303's picture
21
Oct
2008
0 Votes 0
Login to vote

Just tested it too.  Didn't work for me either.  That's pretty disappointing.  Apologies if I've led you up the garden path - so to speak.  Looks like you'll either have to modify the normal bpend_notify to call yours - or IMHO, just modify the one in the "/bin" folder.

 

 

Further points to note:

 

- The BPRES file must be honoured, NetBackup uses this to determine whether your client specific post backup commands work or not.  i.e. your script must write a final status value to the file named in parameter %%6.   With a zero being success.

 

- Absolutely no output must be written to stdout by your script, otherwise the controlling job treats this as data and gets confused and will probably fail - i.e. your scripts must run, work and fail (if needed) silently and gracefully.