Veritas Netbackup™ For Sqlite Administrator'S Guide: Windows and Linux

Download as pdf or txt
Download as pdf or txt
You are on page 1of 38

Veritas NetBackup™ for

SQLite Administrator's
Guide

Windows and Linux

Release 9.0
Veritas NetBackup™ for SQLite Administrator's Guide
Last updated: 2020-12-14

Legal Notice
Copyright © 2020 Veritas Technologies LLC. All rights reserved.

Veritas, the Veritas Logo, and NetBackup are trademarks or registered trademarks of Veritas
Technologies LLC or its affiliates in the U.S. and other countries. Other names may be
trademarks of their respective owners.

This product may contain third-party software for which Veritas is required to provide attribution
to the third party (“Third-party Programs”). Some of the Third-party Programs are available
under open source or free software licenses. The License Agreement accompanying the
Software does not alter any rights or obligations you may have under those open source or
free software licenses. Refer to the Third-party Legal Notices document accompanying this
Veritas product or available at:

https://www.veritas.com/about/legal/license-agreements

The product described in this document is distributed under licenses restricting its use, copying,
distribution, and decompilation/reverse engineering. No part of this document may be
reproduced in any form by any means without prior written authorization of Veritas Technologies
LLC and its licensors, if any.

THE DOCUMENTATION IS PROVIDED "AS IS" AND ALL EXPRESS OR IMPLIED


CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING ANY IMPLIED
WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR
NON-INFRINGEMENT, ARE DISCLAIMED, EXCEPT TO THE EXTENT THAT SUCH
DISCLAIMERS ARE HELD TO BE LEGALLY INVALID. Veritas Technologies LLC SHALL
NOT BE LIABLE FOR INCIDENTAL OR CONSEQUENTIAL DAMAGES IN CONNECTION
WITH THE FURNISHING, PERFORMANCE, OR USE OF THIS DOCUMENTATION. THE
INFORMATION CONTAINED IN THIS DOCUMENTATION IS SUBJECT TO CHANGE
WITHOUT NOTICE.

The Licensed Software and Documentation are deemed to be commercial computer software
as defined in FAR 12.212 and subject to restricted rights as defined in FAR Section 52.227-19
"Commercial Computer Software - Restricted Rights" and DFARS 227.7202, et seq.
"Commercial Computer Software and Commercial Computer Software Documentation," as
applicable, and any successor regulations, whether delivered by Veritas as on premises or
hosted services. Any use, modification, reproduction release, performance, display or disclosure
of the Licensed Software and Documentation by the U.S. Government shall be solely in
accordance with the terms of this Agreement.

Veritas Technologies LLC


2625 Augustine Drive
Santa Clara, CA 95054

http://www.veritas.com
Technical Support
Technical Support maintains support centers globally. All support services will be delivered
in accordance with your support agreement and the then-current enterprise technical support
policies. For information about our support offerings and how to contact Technical Support,
visit our website:

https://www.veritas.com/support

You can manage your Veritas account information at the following URL:

https://my.veritas.com

If you have questions regarding an existing support agreement, please email the support
agreement administration team for your region as follows:

Worldwide (except Japan) CustomerCare@veritas.com

Japan CustomerCare_Japan@veritas.com

Documentation
Make sure that you have the current version of the documentation. Each document displays
the date of the last update on page 2. The latest documentation is available on the Veritas
website:

https://sort.veritas.com/documents

Documentation feedback
Your feedback is important to us. Suggest improvements or report errors or omissions to the
documentation. Include the document title, document version, chapter title, and section title
of the text on which you are reporting. Send feedback to:

NB.docs@veritas.com

You can also see documentation information or ask a question on the Veritas community site:

http://www.veritas.com/community/

Veritas Services and Operations Readiness Tools (SORT)


Veritas Services and Operations Readiness Tools (SORT) is a website that provides information
and tools to automate and simplify certain time-consuming administrative tasks. Depending
on the product, SORT helps you prepare for installations and upgrades, identify risks in your
datacenters, and improve operational efficiency. To see what services and tools SORT provides
for your product, see the data sheet:

https://sort.veritas.com/data/support/SORT_Data_Sheet.pdf
Contents

Chapter 1 Introduction to NetBackup for SQLite Agent ............... 6


About NetBackup for SQLite Agent .................................................... 6
Features supported by NetBackup for SQLite Agent .............................. 7
The NetBackup for SQLite Agent package .......................................... 7
About NetBackup for SQLite Agent License ......................................... 8
NetBackup for SQLite Agent Documentation ........................................ 8

Chapter 2 Installing the NetBackup for SQLite Agent .................. 9


Planning the installation of NetBackup for SQLite Agent ......................... 9
Verifying the operating systems and platforms ................................... 10
Installing prerequisites for NetBackup for SQLite Agent ........................ 10
Post-installation requirements for NetBackup for SQLite Agent .............. 11
Describing the NetBackup for SQLite Agent package ........................... 11
Installing the NetBackup for SQLite Agent ......................................... 12
Uninstalling the NetBackup for SQLite Agent ...................................... 13

Chapter 3 Configuring the NetBackup for SQLite ........................ 14


The nbsqlite.conf configuration file ................................................... 14
Configuring SQLite backups with DataStore policies ............................ 16

Chapter 4 NetBackup for SQLite backup and restore ................ 18


About SQLite database backups ...................................................... 18
Performing SQLite backups ............................................................ 20
Validating the backup information .................................................... 21
Querying the backups ................................................................... 21
Deleting backup information from the NetBackup catalog files ............... 22
About restoring SQLite backups ...................................................... 22
Performing restores for SQLite backups ............................................ 24
Redirected restores ...................................................................... 24
Disaster recovery ......................................................................... 25

Chapter 5 Troubleshooting for NetBackup for SQLite ................ 26


Troubleshooting errors when using NetBackup for SQLite Agent ............ 26
Contents 5

Appendix A NetBackup for SQLite commands and


conventions ................................................................... 31
About NetBackup for SQLite Agent commands ................................... 31
About NetBackup for SQLite Agent command conventions ................... 32

Appendix B NetBackup for SQLite commands ................................ 33


nbsqlite -o backup ........................................................................ 34
nbsqlite -o restore ......................................................................... 35
nbsqlite -o query .......................................................................... 36
nbsqlite -o delete .......................................................................... 37

Index .................................................................................................................... 38
Chapter 1
Introduction to NetBackup
for SQLite Agent
This chapter includes the following topics:

■ About NetBackup for SQLite Agent

■ Features supported by NetBackup for SQLite Agent

■ The NetBackup for SQLite Agent package

■ About NetBackup for SQLite Agent License

■ NetBackup for SQLite Agent Documentation

About NetBackup for SQLite Agent


NetBackup for SQLite Agent extends the capabilities of NetBackup to include backup
and restore of SQLite databases. The agent is located on the NetBackup client and
supports the operations on standalone setups. The agent supports the SQLite
version 3.10.0 and later.

Note: Ensure that the SQLite agent and NetBackup are of same version for
successful backup and restore operations.

The agent also supports to:


■ Validate the backup.
■ Query a backup and restore.
■ Delete the backup information from the catalog files.
■ Redirect restores.
Introduction to NetBackup for SQLite Agent 7
Features supported by NetBackup for SQLite Agent

NetBackup for SQLite workflow


The agent reads the parameters from the nbsqlite.conf file and then initiates the
operations. The nbsqlite.conf file contains the parameters that you must set
before you run the respective operations.
See “The nbsqlite.conf configuration file” on page 14.
The agent creates a snapshot of the volume where the single database file exists.
The Volume Shadow Copy Services (VSS) for Windows or Logical Volume Manager
(LVM) for Linux, takes a snapshot of the SQLite database.
The agent mounts the snapshot, copies the file into the XBSA data object and then
sends it to the NetBackup XBSA interface. The NetBackup XBSA interface writes
this data to the mounted media or disk storage managed by the NetBackup media
server.
The Linux operating systems that are not configured with LVM, the agent copies
the database file directly from the file system.

Features supported by NetBackup for SQLite


Agent
Table 1-1 lists the features that are supported by the agent.

Table 1-1 Features supported by the agent

Feature Description

Backup The agent supports single file based backups of the SQLite database.

Restore The agent supports to restore the SQLite backup files.

Redirected The agent supports to restore the SQLite backup files to alternate
Restores NetBackup clients.

The NetBackup for SQLite Agent package


The agent is packaged in NBSQLiteAgent_8.2.zip and is available on
my.veritas.com site.
The package contains the following platform files:
■ (Windows) NBSQLiteAgent_8.2_AMD64/
■ (Linux RHEL) NBSQLiteAgent_8.2_linuxR_x86/
■ (Linux SLES) NBSQLiteAgent_8.2_linuxS_x86/
Introduction to NetBackup for SQLite Agent 8
About NetBackup for SQLite Agent License

About NetBackup for SQLite Agent License


The NetBackup for SQLite Agent is installed on the NetBackup client software and
is not a separately licensed option of NetBackup. The NetBackup for SQLite Agent
is available to customers who are entitled with a valid license of the Application and
Database License Pack. In general, licensing of the NetBackup for SQLite Agent
follows the existing capacity licensing models for supported database agents.

NetBackup for SQLite Agent Documentation


The NetBackup for SQLite Agent documentation is available at the following URL:
www.veritas.com/support/en_US/article.DOC5332
Chapter 2
Installing the NetBackup
for SQLite Agent
This chapter includes the following topics:

■ Planning the installation of NetBackup for SQLite Agent

■ Verifying the operating systems and platforms

■ Installing prerequisites for NetBackup for SQLite Agent

■ Post-installation requirements for NetBackup for SQLite Agent

■ Describing the NetBackup for SQLite Agent package

■ Installing the NetBackup for SQLite Agent

■ Uninstalling the NetBackup for SQLite Agent

Planning the installation of NetBackup for SQLite


Agent
Table 2-1 lists the planning steps that are mandatory for installing the agent.

Table 2-1 General steps for installing the agent

Step Action

Step 1 Verify the operating systems.

For more information, See “Verifying the operating systems and platforms ”
on page 10.
Installing the NetBackup for SQLite Agent 10
Verifying the operating systems and platforms

Table 2-1 General steps for installing the agent (continued)

Step Action

Step 2 Verify the prerequisites before you install the agent.

For more information, See “Installing prerequisites for NetBackup for SQLite
Agent” on page 10.

Step 3 Install the agent on your operating system.

For more information, See “Installing the NetBackup for SQLite Agent”
on page 12.

Verifying the operating systems and platforms


Verify that the NetBackup for SQLite Agent is supported on your operating system
or platforms.
The agent supports the operations on following platforms:
■ Red Hat Enterprise Linux (RHEL) 6.8 and later.
■ Red Hat Enterprise Linux (RHEL) 7.0 and later.
■ SUSE Enterprise Linux Server 11 SP4 and later.
■ SUSE Enterprise Linux Server 12 and later.
■ Microsoft Windows Server 2012 and later.
■ Microsoft Windows 8.1 or later.

Installing prerequisites for NetBackup for SQLite


Agent
Before you install, ensure that you meet the following prerequisites:
■ NetBackup 8.2 or later is installed and operational on the master server, media
server, and the client.
■ Ensure that versions of the SQLite agent and NetBackup are same. If you
upgrade NetBackup to newer version, then you must upgrade the agent version
also.
■ The SQLite database is installed and operational on the client.
Installing the NetBackup for SQLite Agent 11
Post-installation requirements for NetBackup for SQLite Agent

Post-installation requirements for NetBackup for


SQLite Agent
After you install
■ (Windows) Configure the NetBackup for SQLite Agent to run with administrative
privileges.
■ (Windows) Add the NetBackup bin directory to the PATH user environment
variable.
■ (Linux) If the nbsqlite.conf file does not exist, create the default configuration
file. For more information, See “The nbsqlite.conf configuration file” on page 14.
■ (Linux) Ensure that the user of the agent is a superuser or have superuser
privileges.

Note: Users without root-access, must have read, write, and execute permissions
for the NBSQLiteAgent directory.

Describing the NetBackup for SQLite Agent


package
The agent is packaged in the NBSQLiteAgent_8.2.zip file and is available on
my.veritas.com site.
The package file contains the following platform files:
■ (Windows) NBSQLiteAgent_8.2_AMD64/
■ (Linux RHEL) NBSQLiteAgent_8.2_linuxR_x86/
■ (Linux SUSE) NBSQLiteAgent_8.2_linuxS_x86/
(Windows) NBSQLiteAgent_8.2_AMD64/ includes the following files:
■ NBSQLiteAgent_8.2_AMD64/README.txt

■ NBSQLiteAgent_8.2_AMD64/cab1.cab

■ NBSQLiteAgent_8.2_AMD64/Setup.exe

■ NBSQLiteAgent_8.2_AMD64/NBSQLiteAgent.msi

(Linux RHEL) NBSQLiteAgent_8.2_linuxR_x86/ includes the following file:


■ VRTSnbsqliteagent.rpm

(Linux SUSE) NBSQLiteAgent_8.2_linuxS_x86/ includes the following files:


Installing the NetBackup for SQLite Agent 12
Installing the NetBackup for SQLite Agent

■ VRTSnbsqliteagent.rpm

When you install the agent, accept the VERITAS LICENSE AGREEMENT to proceed
with installing the agent successfully.
The agent by default gets installed at the following locations:
■ (Windows) C:\Program Files\VERITAS\NBSQLiteAgent
■ (Linux RHEL & SUSE) /usr/NBSQLiteAgent/

Installing the NetBackup for SQLite Agent


To install the agent
1 Download the NBSQLiteAgent_8.2.zip file.
2 Extract the file that applies to your operating system:
(Windows) NBSQLite_8.2_AMD64/
(Linux RHEL) NBSQLiteAgent_8.2_linuxR_x86/
(Linux SUSE) NBSQLiteAgent_8.2_linuxS_x86/
3 Run the file that applies to your operating system:
(Windows) NBSQLiteAent_8.2_AMD64/Setup.exe
(Linux RHEL) NBSQLiteAgent_8.2_linuxR_x86/VRTSnbsqliteagent.rpm
Use the rpm -ivh VRTSnbsqliteagent.rpm command.
(Linux SUSE) NBSQLiteAgent_8.2_linuxS_x86/VRTSnbsqliteagent.rpm
Use the rpm -ivh VRTSnbsqliteagent.rpm command.
4 Type y to accept the VERITAS LICENSE AGREEMENT. The agent gets
installed at the default location.

Note: To accept the EULA agreement automatically (silent installation), create


a /tmp/AgentInstallAnswer.conf file with following content:
Yes - to accept the EULA agreement
No - to decline EULA agreement
Installing the NetBackup for SQLite Agent 13
Uninstalling the NetBackup for SQLite Agent

Uninstalling the NetBackup for SQLite Agent


To uninstall the agent
1 (Windows) From the Control Panel, right-click the Veritas NetBackup
SQLiteAgent_8.2 file and Uninstall the agent

2 (Linux RHEL or SUSE) To uninstall, run the following command:


rpm -e VRTSnbsqliteagent
Chapter 3
Configuring the NetBackup
for SQLite
This chapter includes the following topics:

■ The nbsqlite.conf configuration file

■ Configuring SQLite backups with DataStore policies

The nbsqlite.conf configuration file


The configuration file (nbsqlite.conf) contains the parameters that you must
specify for the respective operations. It contains predefined settings and is located
on the client. You can configure the parameters in the nbsqlite.conf file or
provide them on the command line. The parameters on the command line take
precedence over the nbsqlite.conf file.
When you do not specify the parameter, the default values take precedence.
The nbsqlite.conf file keeps you from providing the parameters every time you
run operations.
The nbsqlite.conf file is located in the following locations:
■ (Windows)
C:\Program Files\Veritas\NBSQLiteAgent\nbsqlite.conf

■ (Linux RHEL and SUSE) /usr/NBSQLiteAgent/nbsqlite.conf

Creating the nbsqlite configuration file


Starting from NetBackup 8.2, the nbsqlite.conf file is not created by default when
you install the agent on RHEL or SUSE. The existing configuration file is prevented
from getting overwritten as the RPM installer simply overwrites any existing files in
the destination directory /usr/NBSQLiteAgent/.
Configuring the NetBackup for SQLite 15
The nbsqlite.conf configuration file

If the nbsqlite.conf file does not exist, you can create the file by running the
backup utility command without any options. For example, run the ./nbsqlite
command. This command creates the default nbsqlite.conf file.
Table 3-1 lists the parameters for the operations.

Table 3-1 The nbsqlite.conf file

Parameters Description Required Default value


parameter for

SQLITE_DB_PATH Configures the SQLite Backups No default value for this


database path. parameter.

MASTER_SERVER_NAME Specifies the NetBackup Backups, restores, No default value for this
master server to the nbsqlite query, and delete. parameter.
operations.

POLICY_NAME Specifies the DataStore policy Backups No default value for this
name. parameter.

SCHEDULE_NAME Identifies the backup schedule Backups No default value for this
that you configured when parameter.
creating the DataStore policy.

CLIENT_NAME Defines the NetBackupclient Redirected restores When you do not set this
that has the agent. and query parameter, it defaults to the
NetBackup master server.

SNAPSHOT_SIZE (Linux) Specifies the snapshot LVM backups When you do not set this
size for LVM snapshots in parameter, it defaults to MB.
kilobytes, megabytes, or
gigabytes in KB, MB, or GB
respectively.

DB_BACKUP_ID Represents the backup image To delete and restore No default value for this
name. This parameter a backup file by parameter.
configures the backup file that specifying the backup
you specify using the backup image name.
image name.

SQLITE_TARGET_DIRECTORY Specifies the destination Restores No default value for this


directory where you want to parameter.
restore the backups.
Configuring the NetBackup for SQLite 16
Configuring SQLite backups with DataStore policies

Table 3-1 The nbsqlite.conf file (continued)

Parameters Description Required Default value


parameter for

NBSQLITE_LOG_LEVEL The NBSQLITE_LOG_LEVEL The log levels help to When you do not set this
parameter lets you set the control the amount of value, it defaults to log level
logging level for the nbsqlite information that you 1.
logs. For a particular logging want to access for
level, all details at that level or troubleshooting errors.
lower are logged.
The nbsqlite debug logs
includes the following verbose
levels:

■ 1 – ERROR: Conditions
that should be corrected,
such as configuration
errors.
■ 2 – WARN: Conditions that
are not errors, but that
might require special
handling.
■ 3 – INFO: Informational
messages.
■ 4 – DEBUG: Debugging the
messages that are used for
troubleshooting.

NBSQLITE_LOG_SIZE Specifies the nbsqlite log You can specify the When you do not set this
size in MB. When the log value according to the parameter, it defaults to
reaches the specified size, it events that you want 10MB.
overwrites the existing log to write into the logs.
information.

Configuring SQLite backups with DataStore


policies
The agent supports the DataStore policies to define the attributes, schedules,
clients list, and backup selections.
Configuring the NetBackup for SQLite 17
Configuring SQLite backups with DataStore policies

To configure the SQLite database backups with DataStore policies


1 Log on to the master server as an administrator (Windows) or root (Linux).
2 In the NetBackup Administration Console, expand NetBackup Management,
and then click Policies.
3 In the All Policies pane, right-click Summary of All Policies, and then click
New Policy.
4 In Add a New Policy dialog box, enter a unique name for the policy.
5 In the Change Policy dialog box, select DataStore Policy from Policy Type
drop-down list.
6 From the Policy Storage drop-down list, select a disk-based storage unit
for storage.
7 To select the schedule type, under the Schedules tab, click OK to select the
Application Backup schedule type.

Note: The XBSA framework supports the Application Backup schedule type
only.

8 Under the Clients tab, click New and then add the NetBackup client that has
the NetBackup for SQLite Agent.
9 In the Add Client screen, click New, and then in the Client Name field, type
the name of the client.
10 In the NetBackup Administration Console, click NetBackup Management
> Policies to view the policy in the existing policies list.
11 Verify the settings in the nbsqlite.conf file before you run the backup.
12 For more information, See “The nbsqlite.conf configuration file” on page 14.

Note: Ensure that the SQLite agent and NetBackup are of same version for
successful backup and restore operations.
Chapter 4
NetBackup for SQLite
backup and restore
This chapter includes the following topics:

■ About SQLite database backups

■ Performing SQLite backups

■ Validating the backup information

■ Querying the backups

■ Deleting backup information from the NetBackup catalog files

■ About restoring SQLite backups

■ Performing restores for SQLite backups

■ Redirected restores

■ Disaster recovery

About SQLite database backups


The nbsqlite -o backup command initiates the backup operation using the -S,
-P, -d, and-s as the required parameters. The parameter -z is the required
parameter for Linux LVM configured systems.
Configure these parameters in the nbsqlite.conf file or provide them on the
nbsqlite command line, when the parameters provided on the command line takes
precedence.
NetBackup for SQLite backup and restore 19
About SQLite database backups

Note: Ensure that the SQLite agent and NetBackup are of same version for
successful backup and restore operations.

Figure 4-1 NetBackup for SQLite backup workflow

Connect to the SQLite database and


prepare to take a snapshot.
1

SQLite Database
server Sends SQLite data for
back up
Requests snapshot, reads and
mounts snapshot, reads the NetBackup SQLite 3 NetBackup
SQLite data agent master server
2 5
Snapshot Back up status is
creation returned

NetBackup
media server
NetBackup client

NetBackup XBSA
SQLite data is
VSS/LVM Snapshot 4 backed up

Storage unit

The NetBackup for SQLite backup workflow


When you initiate a backup, the agent creates a snapshot, mounts the snapshot,
copies the file into the XBSA data object. The agent then sends the file to the
NetBackup XBSA interface.
The NetBackup XBSA interface writes this data to the mounted media or disk storage
managed by the NetBackup media server.
The command prompt displays the successful completion status of the backup.
The Activity Monitor also displays the status for the backup job.
NetBackup for SQLite backup and restore 20
Performing SQLite backups

Performing SQLite backups


Prerequisites
Before you perform the backups, you must meet the following prerequisites:
■ Ensure that versions of the SQLite agent and NetBackup are same. If you
upgrade NetBackup to newer version, then you must upgrade the agent version
also.
■ Ensure that the user has administrator (Windows) or root (Linux) access.
■ (Windows) Set the NetBackup\bin directory in the user variable path.
■ Configure the DataStore policy from the NetBackup Administration Console.
■ (LVM) Verify that there is enough space for the snapshot in the volume group,
and then set the snapshot size in nbsqlite.conf file or by the command line.

Note: Ensure that the snapshot size is 110% of the file size that you want to
backup.

■ Set the following parameters in the nbsqlite.conf file:


■ SQLITE_DB_PATH
■ MASTER_SERVER_NAME
■ POLICY_NAME
■ SCHEDULE_NAME
■ (Linux) SNAPSHOT_SIZE

To run backup
1 Configure the parameters in the nbsqlite.conf file or on the nbsqlite
command line.
2 Run the following command:
nbsqlite -o backup

-S master_server_name

-P policy_name

-s schedule_name

(Linux) -z snapshot_size
-d sqlitedb_db_path
NetBackup for SQLite backup and restore 21
Validating the backup information

Note: Ensure that the SQLite agent and NetBackup are of same version for
successful backup and restore operations.

Scheduling the SQLite backups from the NetBackup


You can schedule SQLite backups from the NetBackup Administration Console
using the DataStore policy to call a backup script.
For more information, see https://www.veritas.com/support/en_US/article.100041699

Validating the backup information


After a successful backup, you can list the backups to view and verify the backup
information using the following command:
nbsqlite -o query

Querying the backups


The nbsqlite -o query command lists the backup files according to the options
that you specify. You can configure these parameters from the nbsqlite.conf file
or provide the parameters using the nbsqlite command line.
The parameter -S is the required parameter. Alternatively, you can query the
backups using the -C and -P options to define a different client and policy.
By default, NetBackup uses the values that you have configured in the
nbsqlite.conf file.

Before you run a query, set the following parameters in the nbsqlite.conf file or
provide on the command line:
■ CLIENT_NAME

■ POLICY_NAME

■ MASTER_SERVER_NAME

To query backup
1 Configure the parameters in the nbsqlite.conf file or on the nbsqlite
command line.
2 Run the following command:
nbsqlite -o query -S master_server_name [-C ClientA] [-P
policy_name]

For example, to query a backup from the client ClientA, run the following command:
NetBackup for SQLite backup and restore 22
Deleting backup information from the NetBackup catalog files

nbsqlite -o query -S master_server_name [-C ClientA]

For example, to list backup files with the policy name policy_name, run the following
command:
nbsqlite -o query -S master_server_name [-P policy_name]

For example, to query a backup from the client ClientA with policy name
policy_name, run the following command:

nbsqlite -o query -S master_server_name [-C ClientA] [-P policy_name]

Deleting backup information from the NetBackup


catalog files
The nbsqlite command for delete, removes the backup information from the catalog
files but retains the backup files on the NetBackup media server. The parameter
-S and -id are required parameters.

Prerequisites
Before you delete the backups, set the following parameter in the nbsqlite.conf
file or provide them on the command line:
■ DB_BACKUP_ID

■ MASTER_SERVER_NAME

To delete backup
1 Configure the parameters, in the nbsqlite.conf file or provide on the command
line.
2 Run the following command:
nbsqlite -o delete -S master_server_name -id db_backup_image_name

About restoring SQLite backups


The nbsqlite -o restore command for restore initiates the restore operation
using -S and -t as required parameters. The parameters -id and -C are optional
parameters.
The parameter -id restores the backup using the specified backup image name.
The parameter -C lists all the backups that exists on the specified client. When you
do not specify the client, it defaults to the NetBackup master server.
NetBackup for SQLite backup and restore 23
About restoring SQLite backups

Note: Ensure that the SQLite agent and NetBackup are of same version for
successful backup and restore operations.

Figure 4-2 NetBackup for SQLite restore workflow

Read progress
file
2

Progress file

Restore SQLite Initiate restore


data NetBackup SQLite
NetBackup
agent 1
4 master server
3
SQLite Database
server Retrieve data
to restore

NetBackup
media server
NetBackup client
NetBackup XBSA

Storage unit

The NetBackup for SQLite restore workflow


When you initiate a restore, the agent reads the command line arguments and
parses the nbsqlite.conf configuration file. The agent then interacts with the
NetBackup XBSA interface to retrieve the backup according to the specified
parameters.
The NetBackup XBSA interface reads the progress files to receive the SQLite
backup files to restore them to the target directory.
The command prompt indicates the successful completion status of the restore.
The Activity Monitor also displays the status for the restore job.
NetBackup for SQLite backup and restore 24
Performing restores for SQLite backups

Performing restores for SQLite backups


Prerequisites
Before you run a restore, you must meet the following prerequisites:
■ Ensure that versions of the SQLite agent and NetBackup are same. If you
upgrade NetBackup to newer version, then you must upgrade the agent version
also.
■ Ensure that the user has administrator (Windows) or root (Linux) access.
■ (LVM users) Ensure that data logs and the logs directory reside on the logical
volume.
■ Set the following parameters in the nbsqlite.conf file:
■ CLIENT_NAME

■ DB_BACKUP_ID

■ TARGET_DIRECTORY

■ MASTER_SERVER_NAME

To restore backup
1 Configure the parameters in the nbsqlite.conf file, or provide them on the
command line.
2 Run the following command:
nbsqlite -o restore -S master_server_name -t target_directory
[-id db_backup_image_name][-C client_name]

Redirected restores
Redirected restores lets you restore backup files to a client different from the client
that originally performed the backup. The new location can be a different host or a
different file path using a different name for the redirected restore. To redirect a
restore to a different host, include the destination client name in the
install_path\NetBackup\db\altnames directory.

Note: Ensure that the SQLite agent and NetBackup are of same version for
successful backup and restore operations.
NetBackup for SQLite backup and restore 25
Disaster recovery

Performing redirected restores


To redirect a restore to a different host
1 Update the nbsqlite.conf file with the NetBackup client name as the host
and the SQLite target directory as the directory where you want to redirect the
restore.
2 On the NetBackup master server, create an altnames directory for the host
that you want to have permission to perform the redirected restore. For example,
to give Host B permissions to restore from another host, create the following
file:
■ (Windows) install_path\NetBackup\db\altnames\HostB
■ (Linux RHEL and SLES) /usr/openv/netbackup/db/altnames/HostB

3 In the altnames directory, add the names of the client(s) whose files the
requesting client wants to restore. For example, if you want Host B to have
permissions to redirect restores from Host A, add Host A to the Host B file.
4 Run the following command:
nbsqlite -o restore -S master_server_name -t target_directory -id
db_backup_image_name] [-C client_name]

5 After a successful redirected restore, undo the changes that you made on the
master server and the client.

Disaster recovery
Disaster recovery is a plan to recover the data that can get lost in a disaster event.
The agent supports redirected restore as a disaster recovery strategy.
For more information, See “Redirected restores” on page 24.
Chapter 5
Troubleshooting for
NetBackup for SQLite
This chapter includes the following topics:

■ Troubleshooting errors when using NetBackup for SQLite Agent

Troubleshooting errors when using NetBackup


for SQLite Agent
General guidelines to resolve problems
Table 5-1 lists the general steps that help you resolve problems you may encounter
when using the agent.

Table 5-1 General steps to resolve errors

Steps Action Action

Step1 Remember the error message. Error messages are usually the vehicles for telling you
something went wrong. If you do not see an error on the
command line, but still suspect a problem, check the logs
and the reports. These can provide an error message that
directly points to the problem. The logs and reports are
essential troubleshooting tools.
Troubleshooting for NetBackup for SQLite 27
Troubleshooting errors when using NetBackup for SQLite Agent

Table 5-1 General steps to resolve errors (continued)

Steps Action Action

Step2 Identify what you were doing Ask the following questions:
when the problem occurred.
■ What operation was tried?
■ What method did you use?
■ What type of server platform and operating system was
involved?
■ If your site uses both master server and media server,
was it a master server or a media server?
■ If a client was involved, what type of client was it?
■ Have you performed the operation successfully in the
past? If so, what is different now?
■ What is the service pack level?
■ Do you use operating system software with the latest
fixes supplied, especially those required for use with
NetBackup?
■ Is your device firmware at a level, or higher than the
level, at which it has been tested according to the posted
device compatibility lists?

Step3 Record all information. Capture potentially valuable information:

■ The NetBackup logs.


■ The logs specific to NetBackup for SQLite logs.
■ The logs specific to NetBackup XBSA .

Step4 Correct the problem. After you define the problem, use the information to correct
it.

Step5 Contact Technical Support If you cannot solve the error, contact the Technical support.

Troubleshooting errors using logs


To troubleshoot the errors, you can refer to the NetBackuplogs, NetBackup for
SQLite Agent logs, and the NetBackup XBSA logs. These logs are located at the
following locations:
The NetBackup logs are located at:
■ install_path\NetBackup\logs\bprd

■ install_path\NetBackup\logs\bpcd

■ install_path\NetBackup\logs\user_ops\dbext\logs

You must enable the bprd and the bpcd log files. For more information, see the
NetBackup Troubleshooting Guide
Troubleshooting for NetBackup for SQLite 28
Troubleshooting errors when using NetBackup for SQLite Agent

The logs that are specific to the NetBackup for SQLite Agent are located at:
■ install_path\nbsqlite.log

The logs that are specific to NetBackup XBSA are located at:
■ <NetBackup_install_path>/netbackup/logs/exten_client

For troubleshooting NetBackup errors, see Veritas NetBackup Troubleshooting


Guide and the Veritas NetBackup Commands Reference Guide

Troubleshooting NetBackup for SQLite Agent errors


Table 5-2 lists the errors and the solutions to troubleshoot the problems when
running the operations.

Table 5-2 Troubleshooting NetBackup for SQlite errors

Error Description Solution

The nbsqlite backup fails with The nbsqlite backup fails if the To run a nbsqlite backup successfully:
the following error: user environment variable path
■ Update the user environment variable path
is not updated with NetBackup
Unable to load xbsa.dll with NetBackup_install_path/bin.
bin directory.

The nbsqlite backup fails with The backup may fail when the Verify that you configure the valid master server
status code:7648 host validation fails for secure name and the host name.
connection.

The agent may take some time


to terminate the backup operation
and display the job status on the
nbsqlite command prompt.

The nbsqlite backup fails with The nbsqlite backup fails if the To run the backup successfully
the following error: nbsqlite.conf file is not
■ Configure the valid master server name,
updated with the required
XBSA initiation failed policy name, schedule type in the
parameters.
nbsqlite.conf file or from the command
line.
■ Verify for communication errors between the
nbsqlite agent and the NetBackup master
server. For more information see the
NetBackup Administration guide.

(Windows)VSS snapshot creation The nbsqlite backup may fail Run cmd.exe in Administrator mode.
failed when the user does not have the
privileges to run the nbsqlite
operations.
Troubleshooting for NetBackup for SQLite 29
Troubleshooting errors when using NetBackup for SQLite Agent

Table 5-2 Troubleshooting NetBackup for SQlite errors (continued)

Error Description Solution

The nbsqlite restore operation The nbsqlite restore fails if the For a successful restore
does not restore any data from the nbsqlite.conf file is not
■ Initiate the restore from the NetBackup
target NetBackup client. updated with the NetBackup
source client.
client name and the target
■ Set the NetBackup client name and target
directory.
directory parameters in the nbsqlite.conf
file.

The nbsqlite backup fails with The nbsqlite backup may fail To verify the space in the volume group,
the following error: when the volume group does not use the following command:
have sufficient space for the
(Linux) Error creating LVM 1 $vgs
snapshot.
snapshot
The command displays the volume group
details.

2 Update the nbsqlite.conf file with the


appropriate snapshot size. The snapshot
should be equivalent to or more than the
backup file size.

Error messages after a successful The nbsqlite backup gives To remove the snapshots
backup: these errors when the volume
1 To list the existing snapshot, run the
group contains the snapshots.
<volume_group>/<snapshot_name> following command:
You can list the snapshots and
Read failure after 0 of 4096 at
then remove them before you run $lvs
29393616896: input or output
the backup again.
error. The command displays the snapshot
details.
OR
2 To remove the snapshots, run the following
<volume_group>/<snapshot_name>:
command:
read failure after 0 of 4096 at
4096: input or output error. $ lvremove -f
<volume_group>/<snapshot_name>
Troubleshooting for NetBackup for SQLite 30
Troubleshooting errors when using NetBackup for SQLite Agent

Table 5-2 Troubleshooting NetBackup for SQlite errors (continued)

Error Description Solution

The nbsqlite backup on Linux The nbsqlite backup fails To unmount the snapshot
(LVM), fails with the following during an attempt to unmount the
1 List all mounted file systems using the
error: snapshot, the device, or when
following command:
you remove the existing
Error unmounting the
snapshots. $ mount-l
snapshot-Device or resource busy
2 If the snapshot still exists, run the following
OR
command:
Error removing the
$unmount<mount_directory>
snapshot-sqlitesnap_<timestamp>
Note: This directory is created in
/mnt/<snapshot_name>. The prefix
names for snapshot is sqlitesnap.

3 To remove the snapshot manually run the


following command:

1vremove -f
<volume_group>/<snapshot_name>

The nbsqlite.conf file is Starting from NetBackup 8.2, the If the nbsqlite.conf file does not exist, you
missing after installing the agent nbsqlite.conf file is not can create the file by running the backup utility
on RHEL or SUSE created by default when you command without any options. For example,
install the agent on RHEL or run the ./nbsqlite command. This command
SUSE. The existing configuration creates the default nbsqlite.conf file.
file is prevented from getting
overwritten as the RPM installer
simply overwrites any existing
files in the destination directory
/usr/NBSQLiteAgent/.
Appendix A
NetBackup for SQLite
commands and
conventions
This appendix includes the following topics:

■ About NetBackup for SQLite Agent commands

■ About NetBackup for SQLite Agent command conventions

About NetBackup for SQLite Agent commands


This section describes the commands, options, and parameters that are available
to run the nbsqlite operations. Each command contains a brief description, required
parameters, and optional parameters for the respective operations. The agent
supports only those commands, options, and parameters that are mentioned in this
document.
The nbsqlite.conf file keeps you from providing the parameters every time you
run the operations.
Observe for the following:
■ Set the parameters in the nbsqlite.conf file or on the nbsqlite command
line.
The parameters you set on the command line, takes precedence over the
nbsqlite.conf file.

■ Set the operation type (-o) on the nbsqlite command line.


■ Set the other parameters and options for the respective operation on the
nbsqlite command line or in the nbsqlite.conf file.
NetBackup for SQLite commands and conventions 32
About NetBackup for SQLite Agent command conventions

About NetBackup for SQLite Agent command


conventions
This document uses the following conventions when describing commands that are
specific to the agent.
Run the following commands in the command line interface to see the results:
■ The -help command (-h) option prints a command-line usage message when
it is the only option on the command line. For example,
nbsqlite -h

■ Brackets [ ] indicate that the enclosed component of the command line is optional.
Other parameters are required.
■ Italics indicate that the information is user supplied. For example, you may
provide the policy name and the schedule name for a backup operation.
nbsqlite -o backup -S master_server_name -P policy_name -s
schedule_name

The NetBackup for SQLite command options


Table A-1 lists the options for nbsqlite operations.

Table A-1 The nbsqlite command options

Option Description

-C Configures the NetBackup client name for redirected restores.

-d Configures the SQLite database path.

-h Displays the Help usage, when it is the only option on the nbsqlite
command line.

-id Configures the specified backup using the backup image name.

-o Configures the operation type (backup, restore, query, and delete).

-P Configures the DataStore policy.

-s Configures the NetBackup schedule.

-S Configures the NetBackup master server.

-t Configures the target directory to restore the data.

-z Configures the LVM snapshot size.


Appendix B
NetBackup for SQLite
commands
This appendix includes the following topics:

■ nbsqlite -o backup

■ nbsqlite -o restore

■ nbsqlite -o query

■ nbsqlite -o delete
NetBackup for SQLite commands 34
nbsqlite -o backup

nbsqlite -o backup
nbsqlite -o backup – runs the backup operation from the NetBackup client.

SYNOPSIS
nbsqlite -o backup

-S master_server_name

-P policy_name

-s schedule_name

(LVM) -z snapshot_size

[-d sqlite_db_path]

Description
This command invokes the backup operation from the NetBackup client using the
NetBackup DataStore policy name and the schedule type. The parameter -S, -d,
and -P are required parameters for Windows. The parameter -z is required
parameters for LVM users.
On Windows, the directory path is install_path\NBSQLiteAgent\
On Linux systems, the directory path is /usr/NBSQLiteAgent/

Options
-d Configures the path to connect to the SQLite database.
-P Configures the NetBackup DataStore policy name.
-S Configures the NetBackup server name.
-s Specifies the schedule name that you have configure for the DataStore policy.
-z (LVM backups) Specifies the LVM snapshot size.
NetBackup for SQLite commands 35
nbsqlite -o restore

nbsqlite -o restore
nbsqlite -o restore – restores the backup files from the NetBackup server.

SYNOPSIS
nbsqlite -o restore

-S master_server_name

-t target_directory

[-id db_backup_id]

[-C NetBackup_client_name]

Description
The nbsqlite command restores the backup file using -t and -S as the required
parameters. The -id and -C are optional parameters.
On Windows systems, the directory path to this command is
install_path\NBSQLiteAgent\

On Linux systems, the directory path to this command is /usr/NBSQLiteAgent/

Options
-C Specifies the client name.
-id
Specifies the backup image name.
-S Configures the NetBackup server name.
-t Specifies the target directory.
NetBackup for SQLite commands 36
nbsqlite -o query

nbsqlite -o query
nbsqlite -o query – queries the backups performed for SQLite database.

SYNOPSIS
nbsqlite - o query

-S master_server_name

[-P policy_name]

[-C client_name]

Description
The nbsqlite -o query command gets the backup using -S as the required
parameter and -C and -P as optional parameters.
On Windows systems, the directory path to this command is
install_path\NBSQLiteAgent\

On Linux systems, the directory path to this command is /usr/NBSQLiteAgent/

Options
-C Retrieves and lists all the backups of the specified client.
-P Retrieves and lists all backups with the specified policy name.
-S Configures the NetBackup master server.
NetBackup for SQLite commands 37
nbsqlite -o delete

nbsqlite -o delete
nbsqlite -o delete – deletes the backup information from the NetBackup catalog
files.

SYNOPSIS
nbsqlite - o delete

-S master_server_name

-id db_backup-id

Description
The nbsqlite -o delete command deletes the backup information from the
NetBackup catalog files, but retains the backups in the storage media.
The parameter -S and -id are the required parameters.

Options
-id
Specifies the backup using the backup image name.
-S Configures the NetBackup master server.
Index

B O
backup operations 14
backup image 19 optional parameters 14
backup information 19
delete 19 P
LVM configured systems 19
package 11
parameter 19
platform files 11
validate 19
platforms 10
backup schedule 14
POLICY_NAME 14
precedence 14
C prerequisites 10
CLIENT_NAME 14
S
D SCHEDULE_NAME 14
DataStore policy 16 single file 7
DB_BACKUP_ID 14 snapshot 7
Default Application Backup 16 SNAPSHOT_SIZE 14
default location 12 SQLITE_TARGET_DIRECTORY 14

I
installing 9

L
license 8
LOG _LEVEL 14
LOG_SIZE 14

N
nbsqlite.conf 7
nbsqlite.conf file
client 14
command line 14
configure 14
default 14
locations 14
parameters 14
pre-defined settings 14
required parameters 14

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy