Veritas NetBackup™ DataStore SDK Programmer's Guide for XBSA 1.1.0
- Introduction to NetBackup XBSA
- How to set up the SDK
- Using the NetBackup XBSA interface
- NetBackup XBSA data structures
- NetBackup XBSA environment
- XBSA sessions and transactions
- Creating a NetBackup XBSA application
- Initiating a session
- Backup - creating an object
- Query - finding an object descriptor
- Restore - retrieving an object's data
- Delete - deleting an object or image
- Media IDs - obtaining media IDs
- How to build an XBSA application
- How to run a NetBackup XBSA application
- About How to run a NetBackup XBSA application
- API reference
- Function calls
- Function specifications
- Type definitions
- Process flow and troubleshooting
- How to use the sample files
- Support and updates
- Appendix A. Register authorized locations
Logging and NetBackup
NetBackup has a log directory that contains the debug logs for the various processes that make up the NetBackup server and/or client. There is a configurable verbose level that controls how much information is logged to these debug logs. This verbose level is a value from 0 to 5, with 0 indicating minimal logging and 5 being debug. These logs are used by NetBackup support to help solve customer problems. The log directory is located at /usr/openv/netbackup/logs on UNIX systems and install directory/Veritas/NetBackup/logs on Windows. Within this directory are directories for the different processes such as bprd, bpbrm, and so on. One log file gets created for each day, and NetBackup automatically cleans up old files from this directory. The NetBackup XBSA interface by default logs to the directory exten_client.
With NetBackup 8.1.2, some of the NetBackup services use Unified Logging (VxUL). Those include scheduler components: nbjm, nbpem and nbrb. For more details on VxUL, please see the NetBackup Troubleshooting Guide and the NetBackup Logging Reference Guide. The NetBackup XBSA interface does not currently use VxUL.
The NetBackup XBSA interface allows the XBSA application to log in a manner consistent with other NetBackup processes. By using the NBBSALogMsg() function, the XBSA application logs messages to the same file as the NetBackup XBSA interface. This can cause some confusion for the developer at first, especially at high debug levels, but lets the application see what causes the errors and it could help NetBackup support see what the XBSA application is doing. The log messages contain a timestamp along with the process ID, which is useful when there are multiple processes going at once.
The log message also contains a debug level. The different error levels used by NetBackup are defined in nbbsa.h. One of these values should be used in the msgType parameter of NBBSALogMsg(). While there are no hard definitions of when to use each of these values, using these values may help if NetBackup support or engineering is ever involved in looking at a debug log.
#define MSINFO 4 #define MSWARNING 8 #define MSERROR 16 #define MSCRITICAL 32
The XBSA application is not required to log information to the NetBackup logs. If the XBSA application is the backup portion of another application or database, it may make more sense to log information to a place consistent with the rest of the application.