NetWorker 6.2 for Windows RAP improvement

Beginning with NetWorker 6.2, Legato introduced a reorganisation of NetWorker's configuration database. It will be used for all NetWorker versions in the future.

Prior to 6.2, NetWorker stores all configuration information in three files:

Configuration fileDescription
..\nsr\res\nsrla.res The NetWorker client configuration file
..\nsr\res\nsrjb.res The NetWorker storage node configuration file
..\nsr\res\nsr.res The NetWorker server configuration file

In a larger NetWorker environment, the last RAP databases can become very large and potentially impact NetWorker server performance, as the time needed to update the RAP files increases linearly with the number and size of the resources.

In NetWorker 6.2, each resource of the \nsr\res\nsr.res and \nsr\res\nsrjb.res entries are saved as individual files instead of within a single, expanding file. However, \nsr\res\nsrla.res will not change. There are good reasons for these changes:

  • It enables multiple database reads,
  • It eliminates access delays during modification of resource information,
  • It ensures that database queries are fast, regardless of how large the database grows as client resources are added,
  • The reading of a resource is faster because the exact resource can be addressed. There is no need to read through a very large *.res file any longer.

Here is an example to explain the speed improvement of a NetWorker data zone with 1130 resources:

  • Shutdown using NetWorker 6.1.1 44.86 s
  • Shutdown using NetWorker 6.2.0 6.93 s

Please not that the startup may take a bit longer as more files need to be read. Here are the values for the same configuration:

  • Startup using NetWorker 6.1.1 0.40 s
  • Startup using NetWorker 6.2.0 1.13 s

The new directory structure looks like this:

..\nsr\res\nsr.dir
..\nsr\res\nsrla.res
..\nsr\res\nsrdb
..\nsr\res\nsrdb\00
   ...
..\nsr\res\nsrdb\09

Here is how it looks under windows explorer

nw-rap-1

The structure of the resources themselves did not change at all, each file represents a single resource and it is nothing else but a text file. Their contents is visible using a text editor that can deal with UNIX type text files (for example write.exe). However, as before, you usually configure the resource using the NetWorker Administrator GUI (nwadmin.exe).

As new resources are added (for example, clients, groups, pools, etc.) a new file is created in one of these directories. There are some notes with respect to this new database:

  • The filenames seem to be random. As a consequence, the filename will not tell you which resource it defines.
  • You cannot follow a structure any more that lets you predict, in which directory a new resource will be saved.
  • Limited tests did not show new directories created.

Reviewing resource configuration

There are several options available to reviewing the contents of the RAP configuration

  1. Use the NetWorker Administrator GUI as before
  2. nsradmin has been modified to work with the new nsrdb structure
  3. nsrsup.bat has been modified to use nsradmin to automatically include the resource configuration in the nsr_support output file. nsrsup.bat has been modified to use nsradmin -s localhost when the NetWorker server is up, and it will use nsradmin -d <path> when the NetWorker server is down.
  4. Use the windows copy command to append all of the files together into one file that could be search:
    copy .\00\*.* + .\01\*.* + .\02\*.* + .\03\*.* + .\04\*.* + \\
    .\05\*.* + .\06\*.* + .\07\*.* + .\08\*.* + .\09\*.* res.txt
    NOTE: With all of the above methods, the listing of resources in the output file is always in the order that these resource files appear in the directories.

Searching the resource files

If you need to determine which resource file relates to a specific resource you will need to use the native tools for the OS to relate a specific file to a resource.

Under Windows, use the Search...Files or Folders utility.

  • Enter what you want to search for in the Containing text field
  • Modify the Look in field to specify to only search the ..\nsr\res\nsrdb directory tree.

Here is an example

nw-rap-2

You will see the search results like this:

nw-rap-3

Corrupted Resource file

If NetWorker detects (upon startup) that it cannot read one of the resource files (ie: it is corrupt), the following proess flow occurs:

  • A Warning messages are printed in the file ..\nsr\logs\daemon.log
    nsrd: WARNING: NSR configuration database detected invalid resource C:\Program Files\nsr\res\nsrdb\01\00019803aa1...
    nsrd: Invalid resource saved at C:\Program Files\nsr\res\nsrdb\...
  • NetWorker removes any invalid resource files from the ..\nsr\res\nsrdb directory.
  • These resource files are saved in a directory "dbg" under the res directory. (for example ..\nsr\res\nsrdb\dbg) This directory will only be present if a RAP resource error is detected.
  • You should then manually recreate the resource using nwadmin or nsradmin .
  • You should remove the dbg directory and its contents after you have corrected the problem.

Backward Compatibility

There is no procedure or utility provided that would take the converted nsrdb directory and recreate the nsr.res and nsrjb.res files. You must recover the bootstrap if this is required.

Also, please keep in mind, that customized scripts using nsradmin to modify the resource files will not work any longer.