BRS SAP HANA NAS Data Protection Using Data Domain and NetWorker 11
BRS SAP HANA NAS Data Protection Using Data Domain and NetWorker 11
BRS SAP HANA NAS Data Protection Using Data Domain and NetWorker 11
Abstract
This white paper provides technical considerations and specific
configuration guidance for successfully deploying EMC Data
Domain Systems in an SAP HANA environment.
September 2013
Copyright © 2013 EMC Corporation. All Rights Reserved.
For the most up-to-date listing of EMC product names, see EMC
Corporation Trademarks on EMC.com.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 2
Table of Contents
Executive Summary ................................................................................................. 4
The Solution Overview ............................................................................................. 4
Audience................................................................................................................. 4
Technology overview ............................................................................................... 5
EMC Data Domain System ........................................................................................ 5
SAP HANA Appliances.............................................................................................. 6
SAP HANA Backup and Recovery .............................................................................. 7
SAP HANA Columnar Data Storage Compression ....................................................... 8
Solution Test Scenarios ........................................................................................... 9
Methodology ......................................................................................................... 10
Results.................................................................................................................. 11
One Step Backup using EMC NetWorker ................................................................. 12
Simple Disaster Recovery ...................................................................................... 24
Conclusion ............................................................................................................ 24
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 3
Executive Summary
SAP HANA is an in-memory data platform that is deployable as an on-premise appliance, or
in the cloud. It is a ground-breaking platform that’s best suited for performing real-time
analytics, and developing and deploying real-time applications. At the core of this real-time
data platform is the SAP HANA database that is fundamentally different than any other
database engine in the market today.
Many IT organizations perform SAP HANA database backups on a nightly basis. To meet
their backup and recovery window requirements, most businesses store these backups for
thirty days or more. Unfortunately this leads to rapid growth in backup storage
requirements, which has kept some users stuck with legacy tape systems as the default
solution for database backups. However, this reliance on tape can limit the number of
backups that can be performed, impacting recovery point objectives (RPOs).
In addition, SAP administrators are constantly challenged to improve recovery time
objectives (RTOs). Recovering HANA databases from previous backups, then rolling the
archive/redo logs forward is time consuming and complex. However, restoring the
database in the shortest possible time is essential to business operations.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 4
Audience
This white paper is intended for SAP Basis administrators, Backup administrators, technical
consultants, partners, and members of the EMC and partner professional services community
who are looking for faster, more efficient SAP HANA database backup and recovery with
complete control over the SAP HANA disaster recovery procedures.
Technology overview
The following section provides an overview of components as listed in table 1.
System Components
EMC Data Domain DD640 DDOS 5.2.2.4
Data Domain deduplication storage systems dramatically reduce the amount of disk storage
needed to retain and protect enterprise data. With the industry’s fastest deduplication storage
controller, Data Domain systems allow more backups to complete faster while putting less pressure
on limited backup windows.
All Data Domain systems are built as the data store of last resort. The data in each Data Domain
system is protected by the EMC Data Domain Data Invulnerability Architecture – an end-to-end data
verification, continuous fault detection and self-healing mechanisms coupled with other resiliency
features transparent to the application.
Data Domain systems also integrate easily into your existing environment, enabling you to take
advantage of the benefits of deduplication across workloads, infrastructure, and backup and
archiving applications. For example, it enables efficient and non-disruptive backup of large
databases such as data warehouses and data marts.
For more details on Data Domain Data Invulnerability Architecture, click here:
http://www.emc.com/collateral/software/white-papers/h7219-data-domain-data-invul-arch-
wp.pdf
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 5
SAP HANA Appliances
The SAP HANA database is an in-memory database that combines transactional data
processing, analytical data processing, and application logic processing functionality in
memory. SAP HANA removes the limits of traditional database architecture that have severely
constrained how business applications can be developed to support real-time business.
SAP HANA’s database design thus enables one to perform real-time online application
processing (OLAP) analysis on an online transaction processing (OLTP) data structure. As a
result, one can address today’s demand for real-time business insights by creating business
applications that previously were neither feasible nor cost-effective.
SAP HANA was delivered as an appliance with factory pre-installed hardware, operating system
and SAP HANA database software, either single node or multi-node cluster, on proven hardware
provided by SAP’s hardware partners. It can also be delivered under SAP’s Enterprise Shared
Storage and Tailored Datacenter Integration program, which allows customer to use existing
infrastructure.
With the appliance model, the hardware components include dedicated servers using the latest
Intel CPU architecture to run the SAP HANA database software as well as dedicated network and
storage components.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 6
Single host configuration (Scale-Up)
In a SAP HANA single host configuration, all SAP HANA components run on a single server. The
persistence layer resides on server internal flash and SAS disks. The scalability of the database
is limited by the amount of RAM that can be installed in the server. A Single host configuration
does not provide HA (High Availability) functionality.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 7
Even though SAP HANA database is an in-memory database, it maintains its own persistency.
Data is always saved from memory to disk at save points and data changes are written into redo
log files. In case of failure, this persistency can be leveraged for recovery.
Backups can be triggered using the SAP HANA studio, the DBA Cockpit in Business Warehouse
(BW), SQL script commands or 3rd party tools. Since these are not automatically run by the SAP
HANA system, each HANA database administrator will have to design a backup strategy with
the hardware vendor before purchasing SAP HANA to ensure that they have the
appropriate hardware to support the backup process.
When performing a backup of the SAP HANA system the tables, views, undo logs, packages,
information views and metadata are all saved to a configurable persistent disk location. In
summary, the benefit is that all of the data that is stored in SAP HANA will be backed up to a
data path that you specify. The default location of the data backup is configured as
$(DIR_INSTANCE)/backup/data.
Local Disa
Data Center Recove
DB
SAP
Logs HANA NFS
Studio WAN
D
SAP HANA
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 8
Solution Test Scenarios
This document presents a test scenario that demonstrates how Data Domain systems
complement SAP HANA environments as shown in Figure 3 above.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 9
Methodology
The SAP HANA Studio was the backup application used to perform backup and restore testing.
A proprietary synthetic data generation tool was used to generate globally unique data within a
controlled change rate environment. Three SAP HANA nodes were connected directly to a Data
Domain DD640 system over two 10 Gbps data links.
The NFS Protocol was used in all tests. The “Destination Type” used was File for NFS backups.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 10
Results
Figure 4 shows seven days of full backups with HANA where column compression is enabled
(this is the default setting on the HANA configuration). The initial backup took 41 min for 500+
GB datasets. The balance of all six subsequent backups with a 5% controlled change rate
ranged from 23 - 27 minutes completion.
Size(GB) Time(min)
As shown in Figure 3 below, the deduplication ratios show that the local compression factor is
1.2x across the seven days of full backups. The global compression ratios started at 1.4x and
and then increase to 6.9x after seven days of backups.
The global compression values show the amount of storage required for the file after the
deduplication process finishes, but before local compression occurs.
The local compression value provides the storage requirement after local compression (LZ
[default], gzfast, gz) is applied to the deduplicated segments.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 11
Compression Ratio - Local vs. Global
8
7
6
5
4
3
2
1
0
day1 day2 day3 day4 day5 day6 day7
Figure 5. Global-Comp Factor = Pre-Comp / (Size after de-dupe) Local-Comp Factor = (Size after
de-dupe) / Post-Comp. Total-Comp Factor = Pre-Comp / Post-Comp
In Figure 6 below, the total compression ratio is varies from 1.6 to 7.6 over the seven day range
of full backups.
The pre-compression value is the storage requirement for the contents of data to be backup.
The post-compression values is the actual space required to store the deduplicated data
Deduplication Factor
4500 8
4000 7
3500 6
3000
5
2500
4
2000
3
1500
1000 2
500 1
0 0
day1 day2 day3 day4 day5 day6 day7
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 12
Native SAP HANA Backup and Restore
SAP HANA comes with native tools and commands to perform backups of database data and
redo logs to disk, as well as restoring the database from these backups.
There are a few ways to perform SAP HANA database data backup, such as using SAP HANA
Studio, using SQL commands, etc. In this document, and specifically, in the script, we use SQL
commands to perform data backups with SAP HANA client tool “hdbsql”.
Using explicitly username and password with hdbsql is not recommended by SAP HANA,
because the password will be visible in the process list. SAP HANA provides a tool,
“hdbuserstore”, which can be used to create a user key. The user key encapsulates the
credential information, including username, password, and the instance number. Using user
key instead of plain username and password with hdbsql looks like:
> hdbsql –U <user_key> “backup data using file (<path>/<prefix>)”
Refer to section 13.9.3 in SAP HANA Administration Guide for details on creating user key.
For details on how to perform backup and recovery with SAP HANA native tools, refer to Chapter
13 in SAP HANA Administration Guide.
Introduction to NSRSAPHANA
nsrsaphana is a shell script written to perform SAP HANA 1-step backup to NetWorker.
It can be used to configure a scheduled backup with NMC, and it can also be used on its own to
perform a manual backup. The scheduled backups can be further replicated to remote site
using NetWorker catalog-aware Clone Controlled Replication if desired.
The script consists of three sections: pre-command section, backup to NetWorker section, and
post-command section.
The primary functionality of the pre-command section is to perform the first stage of the 1-step
backup process: SAP HANA database backup to disk. It uses the “hdbsql” client tool of SAP
HANA to perform this backup operation. The syntax of hdbsql performing a database data
backup:
> hdbsql -i <instance number> -u <username> -p <password> “backup data using file
(<path>/<prefix>)”
Or, if using the user key:
> hdbsql –U <user_key> “backup data using file (<path>/<prefix>)”
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 13
nsrsaphana accepts either user key or username/password/instance number combination for
connection authentication.
<path> would be a user-provided destination for the backup, as mentioned in section 1. In the
script, it is the staging area to which the intermediate backup files will be generated. This is
provided by the user.
<prefix> would be a user-provided prefix for the backup name, as mentioned in section 1. In the
script, it is the timestamp of when the backup started. This is internally provided by the script,
and not by the user.
Once the pre-command issues hdbsql and successfully performs a database backup to the
staging area (we refer to backups made in the staging area “backup files”), the script invokes
NetWorker “save” command to backup the backup files to NetWorker. All the backup files in
the staging area will be saved to one saveset. The name of the saveset has the following
format:
SAPHANA_<Data/Log>_<SID>_<HANA_Instance>_<Timestamp>_<Path>
The saveset name identifies whether the backup is data backup or logs backup. “SID” (System
ID) identifies to which SAP HANA system the backup belongs. “HANA_Instance” identifies from
which instance in the SAP HANA system the backup came. “Timestamp” identifies when the
backup was performed. “Path” is the staging area where the backup files in the saveset were
from.
The last section, post-command, performs cleanup operation to the staging area. The user can
configure that files older than a certain number of days can be deleted from this staging area.
Data Backup:
The user can follow the following steps to configure a SAP HANA scheduled backup of database
data to NetWorker:
1. Firstly, we need to set some parameters in nsrsaphana. The script can be found in the
Appendix, and you shall see that towards the beginning of the script, three parameters
are required to be set by the user:
hdbsql_cmd: Specify the full path to hdbsql.
hana_SID: Specify the SAP HANA System ID (SID).
hana_instance: Specify the SAP HANA instance number.
There are examples in the script to show how to set these parameters.
The user also needs to set credential parameters. If the user has already created a user key,
then set the following parameter in the script:
hana_key: Specify the SAP HANA user key for backup.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 14
Otherwise, the user needs to specify a database username and password that has privilege
BACKUP ADMIN:
hana_username: Specify the database username that performs the backup.
hana_password: Specify the corresponding password for the username.
If all of the three parameters above are provided, the user key takes the higher precedence and
will be used, because it is more secure than the plain username/password (password can be
leaked through the process list).
Above are all the parameters that the user needs to set in the nsrsaphana script.
The nsrsaphana script needs to be deployed under the same directory where NetWorker “save”
is, such as /usr/sbin/on Linux systems.
Configure a client resource with NMC (The NMC version used in this document is 8.0.1). Under
the “Configuration” tab in NMC, click on “File” menu, and then click “New” to start creating a
client resource. Under the “General” tab, fill in the information required for the client resource.
In the following example (Figure 1), I provided the following three piece of information (circled
in red): Client resource name, “Saveset”, and “Group”.
“Saveset” is special. It specifies the staging area. SAP HANA will backup the data to this
staging area during the first stage of the backup, and then NetWorker will backup the backup
files from this area. The user needs to make sure that the staging area is big enough to hold the
intermediate backup files (at least large enough to hold one backup of SAP HANA database
data).
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 15
Figure 7: NMC GUI
Under “Apps & Modules”, fill in the “Backup command” textbox, with the name of the script:
nsrsaphana (Figure 2). You can optionally put a number after nsrsaphana. This number
specifies that any files that are older than this number of days will be deleted from the staging
area at the end of the backup. If no number is specified, all files are removed immediately after
the backup to NetWorker is done. This number affects the size of the staging area: The longer
the backup files stay, the more backup files accrue, and the bigger this area has to be.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 16
Figure 8: NMC GUI
Click “OK”, and the client resource for SAP HANA database data backup is created.
2. Perform a scheduled backup with this newly created client resource. After the backup is
finished you can see that a saveset containing the backup files from the staging area is
created (Figure 3).
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 17
The saveset contains all backup files in the staging area. If the backup files are erased from the
staging area every time after the data backup, then the saveset only contains backup files
corresponding to one database backup. If the user configures the client resource in such a way
that backup files stay in the staging area for a period of time, then the saveset might contain
backup files from a few database backups.
For more information on configuring scheduled backups with NMC, refer to EMC NetWorker
Administration Guide.
To configure a scheduled backup for redo logs is very similar to that of database data backup.
Step 1 in the previous data backup section applies the same to redo logs backup.
Step 2 for redo logs backup is almost the same as that for data backup in the previous section,
except that the value for the “Backup Command” textbox is different. As shown in Figure 4, the
user needs to put “log” argument right after the nsrsaphana, in order for nsrsaphana to know
that this is for redo logs backup. Again, the user can optionally put a number at the end of the
command to specify that any files that are older than this number of days will be deleted from
the staging area at the end of the backup. If no number is specified, then by default the number
is 1, which implies that the intermediate redo log backup files are retained for 1 day. This
behavior is different from that of data backup. (As mentioned in the previous section, data
backup by default uses value 0, i.e., all files are deleted from the staging area at the end of the
backup.) The reason for retaining redo log backup files for 1 day is that redo logs backup to
disk is not controlled by the nsrsaphana script, and therefore the script could be backing up the
log files from the staging area to NetWorker at the same time that the SAP HANA database
server is backing up redo logs to the staging area. In this situation, we could backup
incomplete redo log backup files. If we erase the backup files immediately after the backup to
NetWorker is finished, then we would have incomplete redo logs backed up on NetWorker, and
the complete ones would have been deleted.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 18
Figure 10: NMC GUI
After the client resource for log backup is configured, it can be scheduled to perform redo log
backups to NetWorker. An example saveset produced by SAP HANA redo logs backup is shown
in Figure 5.
Same as data backup, every redo logs backup backs up all the files in the staging area. These
files may represent many redo log backups from the SAP HANA server, depending on how often
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 19
the SAP HAHA performs a redo log backup, and how long nsrsaphana retains the backup files in
the staging area.
Data Backup:
The syntax of using nsrsaphana to perform SAP HANA database data backup:
> nsrsaphana [num_of_days] [CLI options for NetWorker save command] <staging area>
num_of_days: Specify an integer representing the number of days. Any file in the staging area
that is older than this number of days will be deleted at the end of the 1-step backup. If this
option is not specified, all files in the staging area will be deleted at the end of the 1-step
backup.
CLI options for NetWorker save command: Specify any CLI options for NetWorker save. These
options will be passed on to the save command verbatim by nsrsaphana. Refer to EMC
NetWorker Command Reference Guide for all CLI options for the save command. Note that the “-
N” switch will be ignored, because nsrsaphana creates its own symbolic names for savesets.
staging_area: Specify the directory to which SAP HANA will perform backup, and from which
NetWorker will then backup the intermediate backup files.
Example:
> nsrsaphana 3 –s bu-saphana1.emc.com /usr/sap/AAA/HDB01/backup/data
This command performs SAP HANA database data backup to NetWorker server bu-
saphana1.emc.com, with /usr/sap/AAA/HDB01/backup/data as the staging area. Any file in
the staging area that is older than 3 days will be deleted at the end of the backup.
Example:
> nsrsaphana 5 –s bu-saphana1.emc.com /usr/sap/AAA/HDB01/backup/log
This command performs SAP HANA redo logs backup to NetWorker server bu-
saphana1.emc.com, with /usr/sap/AAA/HDB01/backup/log as the staging area. Any file in the
staging area that is older than 5 days will be deleted at the end of the backup.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 20
With this command-line backup option, the user can create scheduled backup with tools other
than NMC, such as cron.
The recovery of SAP HANA Database is performed through SAP HANA Studio graphical user
interface. SAP HANA supports the following recovery types: (1). Recover the database to its
most recent state, (2). recover the database to a point-in-time, and (3) recover the database to
a specific data backup. For (1) and (2), both data backup and redo log backup will be used. For
(3), only data backup will be used. (There is another not-commonly-used recovery option which
is to recover the database to a log position. Both data backup and redo log backup will be used
for this option.)
The recovery process involves two manual steps: 1). Restore the desired backup from
NetWorker to the staging area. 2). Restore the backup in the staging area to SAP HANA
database server. The script, nsrsaphana, does not perform any recovery operation.
The saveset names produced from the 1-step backup with the script can aid the user in
preparing for database recovery by helping the user to identify the following information about
the backup: (1) whether the backup contains database data or redo logs, (2) the SAP HANA
system that the backup belongs to, (3) the instance in the system that the backup belongs to,
and (4) the time corresponding to when the backup was made. We will, in the following
paragraphs, expand on how to leverage these benefits, especially the timestamp, for restoring
the data backups as well as redo log backups from NetWorker to the staging area, regardless
which one of the three types of SAP HANA recovery operation (mentioned in section 1) is being
carried out.
The user first needs to figure out what data backup and redo log backups are needed to
perform a SAP HANA recovery. The user can use SAP HANA backup catalog or the SAP HANA
backup log for this task. We will not elaborate on how to do so, but to ask the user to refer to
chapter 13 of SAP HANA Administration Guide on how to identify what backups to use for any
type of SAP HANA recovery operation.
Once the user figures out which data and redo log backups are needed, the user then needs to
identify which savesets on NetWorker contain the desired data and redo log backups for the
SAP HANA database recovery operation, and restores these savesets from NetWorker to the
staging area.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 21
<HANA Instance> helps to identify the instance in the SAP HANA system where the backup came
from.
<Timestamp> helps to identify when the 1-step backup operation was started.
<Path> is the staging area where the backup files in the saveset were from.
The user can use NetWorker “mminfo” command to query for the list of savesets stored on the
NetWorker server. For details on “mminfo” command, refer to EMC NetWorker Command
Reference Guide. For example:
> mminfo
volume client date size level name
bu_saphana1.001 bu-saphana1 05/02/2013 1086 MB manual
SAPHANA_Data_AAA_01_2013y_05m_02d_11h_08m_/hanamnt/AAA/HDB01/backup/data/
bu_saphana1.001 bu-saphana1 05/02/2013 2173 MB manual
SAPHANA_Data_AAA_01_2013y_05m_02d_11h_11m_/hanamnt/AAA/HDB01/backup/data/
bu_saphana1.001 bu-saphana1 05/02/2013 3268 MB full
SAPHANA_Data_AAA_01_2013y_05m_02d_13h_02m_/usr/sap/AAA/HDB01/backup/data/
bu_saphana1.001 bu-saphana1 05/01/2013 1022 MB full
SAPHANA_Log_AAA_01_2013y_05m_01d_12h_57m_/usr/sap/AAA/HDB01/backup/log/
bu_saphana1.001 bu-saphana1 05/02/2013 1177 MB full
SAPHANA_Log_AAA_01_2013y_05m_02d_12h_49m_/usr/sap/AAA/HDB01/backup/log/
In the above, there are 5 savesets. Three are data backups and two are redo log backups.
“AAA” is the SID, and “01” is the instance number. The timestamp and staging area form the
last part of the saveset name.
Here is an example on how one can identify the saveset that contains the desired data backup:
SAP HANA maintains a history of all backups in a log file called backup.log (usually under
directory $DIR_INSTANCE/<SAPLOCALHOST>/trace/). Whenever a backup is started, the start
time of the backup as well as the content of backup, among other information, are logged into
this file. The user can leverage this history file and their recovery requirement to figure out
which data backup is needed for the restore. Once the data backup is identified, the user can
use the start time in the backup.log for that backup to cross-reference the corresponding
saveset on NetWorker, as the timestamp in the saveset name corresponds closely to the start
time in backup.log (there may be a deviation of a few minutes).
Even if backup.log is not available, the user shall be able to figure out which data backup is
needed by using the timestamp information in the saveset name, as it corresponds to the start
time of the SAP HANA database backup.
Once the saveset that needs to be restored is identified, the user can perform NetWorker
filesystem files recovery operation to restore backup files in the saveset to the staging area. For
details on how to restore flat files with NetWorker, refer to EMC NetWorker Administration
Guide. Here is a simple example on how to restore saveset based on SSID (Save Set ID):
1). Use “mminfo –v” to get the corresponding SSID for the saveset that you want to restore.
Let’s say that the SSID is: 12345678
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 22
2). Use “recover –S 12345678” to recover the files in the saveset to the directory where they
were backed up.
Regarding restoring redo logs, the user needs to identify the saveset(s) that contains the
necessary redo logs that will be used to recover the SAP HANA database. For example, if the
user wants to perform database recovery to the most recent time, then the redo logs needed are
usually the ones generated from the last full database backup till the most recent redo log.
Differing from data backup, the timestamp in the redo log saveset name represents when the
redo log backup to NetWorker happened, not when the redo logs in the saveset were generated
by SAP HANA (Recall that redo logs backup to disk is always initiated by SAP HANA database
server, in user-configurable time intervals.). Therefore, the timestamp tells that this saveset
contains redo logs generated up to the point-in-time represented by this timestamp. How many
days’ worth of redo logs a saveset contains depends on how long the user keeps the redo log
files in the staging area (via the “num_of_days” argument to nsrsaphana).
If the user cannot decide which savesets contain all necessary redo logs based on just the
timestamp information in the saveset name, then the user can use NetWorker “nsrinfo”
command to look into the saveset, and get information on each redo log file contained in the
saveset. Specifically, the “-V” switch for “nsrinfo” shows the creation time (ctime) of each redo
log file. For details on how to use “nsrinfo”, refer to EMC NetWorker Command Reference Guide.
Once the necessary data and redo log backup files are restored from NetWorker to the staging
area in the file system, the user can perform the second step, which is to restore and recover
the SAP HANA database. This document will not expand on how to perform restore and recovery
of SAP HANA database from backup files. Chapter 13 of SAP HANA Administration Guide
contains details on how to do so.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 23
Simple Disaster Recovery
Integration with Data Domain Replicator software provides streamlined, network-efficient and
cost effective disaster recovery protection by sending only unique, compressed data segments
across the WAN to the remote Data Domain system.
Data Domain Replicator software provides automated, fast, and reliable replication of data for
disaster recovery (DR), remote office data protection, and multiple site tape consolidation.
Conclusion
The backup test results presented here confirm that using an NFS setting on Data Domain
storage systems is one of the simplest and most effective methodologies to backup a HANA
database. HANA delivers leading performance and scalability while enabling businesses to
backup in-memory databases in an aggressive production OLAP environment. The test results
should be used only as a general guideline since these results will also vary from
implementation to implementation due to a number of factors such as the workload of
application datasets.
Backups were done online while the database was running, the impact on HANA system
resources were negligible, and users can continue to work normally.
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 24
Appendix
One Step Back up With Networker
The following shell script is provided as an example for customers to use EMC NetWorker for
their SAP HANA FileSystem Backups. The script allows the customer to do both manual and
scheduled one step backup using a staging area.
#!/bin/bash
################################################
# SAP HANA 1-step backup to NetWorker
# V0.1
# April 30, 2013
################################################
################################################
# Specify the full path to hdbsql, for example:
# hdbsql_cmd=/hanamnt/<SID>/HDB01/exe/hdbsql
#
# Specify the SAP HANA System ID, SID. For example:
# hana_SID=ABC
#
# Specify the SAP HANA instance number. For example:
# hana_instance=01
################################################
# hdbsql_cmd=
# hana_SID=
# hana_instance=
################################################
# Specify the SAP HANA user key for backup. This key
# is created by the hdbuserstore tool. For example:
# hana_key=BACKUPKEY
#
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 25
# If no user key created, then specify
# the username and password. However, this is not a
# preferred authentication method, as SAP HANA
# user key has better security feature. See section
# 13.9.3 in SAP HANA Administration Guide for detail.
# hana_username=backupadmin
# hana_password=abc123
################################################
# hana_key=
# hana_username=
# hana_password=
################################################
# User provided value verification
################################################
if [ "$hdbsql_cmd" = "" ]
then
echo "Path to hdbsql is not specified."
exit 1
fi
if [ "$hana_SID" = "" ]
then
echo "SAP HANA SID is not specified."
exit 1
fi
if [ "$hana_instance" = "" ]
then
echo "SAP HANA instance number is not specified."
exit 1
fi
if [ "$hana_key" = "" ]
then
echo "SAP HANA user key is not specified."
echo "Use username/password for authentication instead."
if [ "$hana_username" = "" ]
then
echo "username for SAP HANA backup is not specified."
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 26
exit 1
elif [ "$hana_password" = "" ]
then
echo "password for user \"${hana_username}\" is not specified."
exit 1
fi
fi
################################################
# pre-cmd section
################################################
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 27
if [ ${savepath:(-1)} != "/" ]
then
savepath=${savepath}/
fi
################################################
# NW save section
################################################
nwsave_cmd=save
save_options="${save_options} ""$1"
shift
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 28
done
if [ "$?" != "0" ]
then
echo "SAP HANA database backup failed."
exit 1
fi
fi
if [ "$?" != "0" ]
then
echo "NetWorker backup of \"${savepath}\" failed."
exit 1
fi
################################################
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 29
# post-cmd section
################################################
exit 0
####################END#########################
EMC Data Domain Storage Systems – SAP HANA appliances Data Protection 30