Veritas NetBackup™ for Sybase Administrator's Guide

Last Published:
Product(s): NetBackup (8.2, 8.1.2)
  1. Introduction to NetBackup for Sybase
    1.  
      About NetBackup for Sybase
    2.  
      Features of NetBackup for Sybase
    3.  
      NetBackup for Sybase terminology
    4. NetBackup for Sybase overview
      1.  
        SQL server and Sybase backup server
      2.  
        NetBackup for Sybase technical overview
      3.  
        Sequence of operation for NetBackup for Sybase backups
  2. Installing NetBackup for Sybase
    1.  
      Planning the installation of NetBackup for Sybase
    2.  
      Verifying the operating system and platform compatibility
    3.  
      NetBackup server and client requirements
    4.  
      Sybase server software requirements
    5.  
      Requirements for using NetBackup for Sybase in a NetBackup cluster
    6.  
      About the license for NetBackup for Sybase
    7.  
      Copying the NetBackup for Sybase library to each Sybase instance
    8.  
      Running the sybase_config script
    9.  
      Adding new Sybase instances
  3. Configuring NetBackup for Sybase
    1.  
      About NetBackup for Sybase configuration
    2. About configuring a backup policy for Sybase
      1.  
        Adding a new NetBackup for Sybase policy
      2.  
        About policy attributes
      3.  
        About schedule properties
      4. NetBackup for Sybase backup types
        1.  
          Configuring an application backup schedule
        2.  
          Example application backup schedule
        3.  
          Configuring automatic backup schedules
        4.  
          Example automatic backup schedule
      5.  
        Adding clients to a policy
      6.  
        Adding NetBackup for Sybase scripts to the backup selections list
      7.  
        Rules for NetBackup for Sybase scripts
    3. About the backup, restore, and load scripts for NetBackup for Sybase on UNIX
      1.  
        Modifying the backup script for NetBackup for Sybase on UNIX
      2.  
        Example sybase_mydb_backup.cmd script for NetBackup
      3.  
        Modifying the restore script for NetBackup for Sybase on UNIX
      4.  
        Example of a sybase_mydb_restore script
    4. About the backup, restore, and load scripts for NetBackup for Sybase on Windows
      1.  
        Modifying the backup script for NetBackup for Sybase on Windows
      2.  
        sybase_mdb_backup.cmd script
      3.  
        Additional information for editing the backup script for NetBackup for Sybase on Windows
      4.  
        Modifying the restore script for NetBackup for Sybase on Windows
      5.  
        sybase_mydb_restore.cmd script example for NetBackup
      6.  
        Additional information for editing the restore script for NetBackup for Sybase on Windows
    5.  
      Modifying the NetBackup for Sybase load script
    6.  
      NetBackup for Sybase environment variables
    7. NetBackup for Sybase configuration or bp.conf file settings
      1.  
        Creating a $SYBASE_HOME/bp.conf file on the UNIX client
      2.  
        Specifying options in /usr/openv/netbackup/bp.conf on the UNIX client
    8.  
      Configuring the logon account for the NetBackup Client Service for NetBackup for Sybase
    9. About striped dumps and loads with NetBackup for Sybase
      1.  
        Example Sybase scripts for striped dumps and loads
      2.  
        NetBackup for Sybase multiplexing considerations - duplicating tapes
      3.  
        NetBackup for Sybase multiplexing considerations - using more than 12 stripes
    10.  
      Reviewing the auto-discovered mappings in Host Management
    11.  
      About permissions for NetBackup for Sybase log files (UNIX)
    12.  
      Configuring the Maximum jobs per client
    13.  
      Performing a manual backup
  4. Using NetBackup for Sybase
    1. About Sybase database backups
      1.  
        Sybase backup strategy
      2.  
        Automatic backups of a Sybase database
      3.  
        Backing up a Sybase database manually
      4.  
        Performing a user-directed backup for Sybase
    2.  
      Browsing Sybase backups
    3. About restoring a Sybase database
      1.  
        Using isql to restore a Sybase database
      2.  
        Configuring a redirected restore on the NetBackup for Sybase client
  5. Troubleshooting NetBackup for Sybase
    1. NetBackup debug logs and reports
      1.  
        Enabling the debug logs for a NetBackup for Sybase client automatically (Windows)
      2.  
      3.  
        Enabling the debug logs manually (UNIX)
      4.  
        About the bphdb directory on the Windows database client
      5.  
        About the bphdb directory on the UNIX database client
      6.  
        About the sybackup directory on the UNIX database client
      7.  
        About the sybackup directory on the Windows database client
      8.  
      9.  
        Setting the debug level on a UNIX client
      10.  
        About NetBackup server reports
    2.  
      Sybase Backup Server log and messages
    3.  
      Minimizing timeout failures on large database restores
    4.  
      Minimizing the loading and unloading of tapes for database backups
    5.  
      Delays in completion of backup jobs
  6. Appendix A. Register authorized locations
    1.  
      Registering authorized locations used by a NetBackup database script-based policy

Example sybase_mydb_backup.cmd script for NetBackup

The following code example shows the sybase_mydb_backup script:

#***************************************************************************
# Replace /usr/sybase12 below with the actual Sybase home directory 
#***************************************************************************
SYBASE=/usr/sybase12
  
#***************************************************************************
# Replace SYBASE12 below with the actual name of the SQL Server
#***************************************************************************
SYBSERVER=SYBASE12
  
#***************************************************************************
# Replace SYB_DB below with the actual name of your Sybase database
#***************************************************************************
DATABASE_NAME=SYB_DB
  
#***************************************************************************
# Replace syb_files below with your actual name of the NetBackup 
# server Policy to be used to backup the directory with Sybase script files
#***************************************************************************
SYB_FILES_POLICY=syb_files
  
#***************************************************************************
# Replace /usr/sybase12/scripts below with your actual path of the Sybase files 
#***************************************************************************
SYB_FILES_DIR=/usr/sybase12/scripts
  
if [ ! -d "${SYBASE}"/ASE-12_0/ ]
then
#************** Sybase 11.9.2 or earlier *******************
ASE_QUAL=
OCS_QUAL=
else
#************** Sybase 12.0 ****************************
SYBASE_ASE=ASE-12_0; export SYBASE_ASE
SYBASE_OCS=OCS-12_0; export SYBASE_OCS
ASE_QUAL=/$SYBASE_ASE
OCS_QUAL=/$SYBASE_OCS
fi
  
  
echo "Started 'date'"
SYBASE=$SYBASE; export SYBASE
# These environment variables are set by NetBackup 
echo "SYBACKUP_SERVER = $SYBACKUP_SERVER"
echo "SYBACKUP_POLICY = $SYBACKUP_POLICY"
echo "SYBACKUP_SCHED = $SYBACKUP_SCHED"
echo "SYBACKUP_SCHEDULED = $SYBACKUP_SCHEDULED"
echo "SYBACKUP_USER_INITIATED = $SYBACKUP_USER_INITIATED"
  
RETURN_STATUS=0
  
#***************************************************************************
# Replace "database_dump" below with your actual NetBackup schedule name
# which is used for a full backup of the Sybase database.
#***************************************************************************
if [ "${SYBACKUP_SCHED}" = "database_dump" ]
then
############# NetBackup has started a "database_dump" backup ##############
DUMP_TYPE=DATABASE
  
else
############# NetBackup has started a "transaction log" backup ##############
DUMP_TYPE=TRANSACTION
fi
  
#***************************************************************************
# Replace "Default-Application-Backup" below with your actual NetBackup 
# Application Backup type schedule name for the Sybase database. 
#***************************************************************************
    echo dump $DUMP_TYPE $DATABASE_NAME to \"sybackup::-SERV $SYBACKUP_SERVER -POL 
$SYBACKUP_POLICY -SCHED Default-Application-Backup\" > ./syb_${DATABASE_NAME}_dump
  
#**************************************************************************
# Remove the '#' from the beginning of the line below if you are going to
# use multiple stripes for the backup. Repeat this line for each stripe.
# Replace "Default-Application-Backup" below with your actual NetBackup
# Application Backup type schedule name for the Sybase database.
# **************************************************************************
# echo stripe on \"sybackup::-SERV $SYBACKUP_SERVER -POL $SYBACKUP_POLICY 
-SCHED Default-Application-Backup\" >> ./syb_${DATABASE_NAME}_dump 
  
echo go >> ./syb_${DATABASE_NAME}_dump
  
#***************************************************************************
# Replace "manager" with your Sybase server Administrator's Password
#***************************************************************************
    echo "$SYBASE$OCS_QUAL/bin/isql -Usa -Pmanager -I$SYBASE/interfaces -S$SYBSERVER 
< ./syb_${DATABASE_NAME}_dump"
  
    $SYBASE$OCS_QUAL/bin/isql -Usa -Pmanager -I$SYBASE/interfaces -S$SYBSERVER 
< ./syb_${DATABASE_NAME}_dump
    RETURN_STATUS=$?
  
if [ "${DUMP_TYPE}" = "DATABASE" ]
then
#  Initiate a backup of any file related to the Sybase database, such as script files.
  
    echo "bpbackup -c $SYB_FILES_POLICY $SYB_FILES_DIR"
    /usr/openv/netbackup/bin/bpbackup -c $SYB_FILES_POLICY $SYB_FILES_DIR
    BPBACKUP_STATUS=$?
  
    if [ "$BPBACKUP_STATUS" -ne 0 ]
    then
        echo ""
        echo "bpbackup of $SYB_FILES_DIR returned $BPBACKUP_STATUS"
    fi
fi
  
  
echo "Finished 'date'"
  
echo "exit $RETURN_STATUS"
echo ""
  
exit $RETURN_STATUS