Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

SAP HANA Installation Automation – by the SAP HANA Academy

Introduction

Recently, we have updated a number of SAP Hana Academy tutorial videos for the playlist

  • SAP HANA Installation and Update – SAP HANA 2.0 SPS 02

In this blog, I will provide some references and background information about installation automation with the SAP HANA platform lifecycle management tools.

This blog is part of a series:

  • SAP HANA 2.0 installation and update
  • SAP HANA 2.0 platform lifecycle management
  • SAP HANA Installation Automation (this blog)
  • SAP HANA 2.0 Server Installation
  • SAP HANA 2.0 XS Advanced Installation
  • SAP HANA 2.0 Client Installation and Update
  • SAP HANA 2.0 Studio Installation and Update
  • Getting Started with SAP HANA 2.0 cockpit

SAP HANA Academy – SAP HANA Installation and Update (YouTube Playlist)

Tutorial Video

SAP HANA Academy – SAP HANA Installation and Update: Installation Automation

Create the Configuration File

In the previous blogs about SAP HANA 2.0 platform lifecycle management and SAP HANA 2.0 Server Installation, I already briefly mentioned installation automation. Using a combination of configuration files, optional command line options, you can automate installations, that is, create a repeatable process that can be scheduled without any further human intervention.

The process is simple. First, you create a configuration or response file by running the hdblcm installation tool with the dump_configfile_template and the action parameter.

The location and name of the file, including the extension (if any), are for you to choose.

./hdblcm --action=install \
--dump_configfile_template=/tmp/install.rsp

This command will generate both the configuration template file and a password template file.

Configure the Configuration File

Next, we need to edit the installation parameters. There are a bit over 100 parameters available so this might take a bit time to get this right, depending on the requirements. However, the good news is that all parameters have a default value, except for the sid (system identifier) and the password parameters.

For the parameter reference, see

  • Parameter Reference – SAP HANA Server Installation and Update Guide

General and Action

In the General section, you specify where the installation media is located (component_medium, _dirs, _root), whether to use a master password – for the operating system accounts adm and sapadm and database users SYS and SYSTEM (amongst others, see below) and which components to install.

It also includes the configuration of remote execution which concerns a distributed (multi-host) installation which itself is configured in the AddHosts section (see below).

For remote execution of multiple-host system operations, see

  • Using SAP Host Agent to Execute Platform LCM Tasks

The Action section only has a single parameter, action, which will have been already specified with the value you provided on the command line when running the hdblcm command.

As I explained in the SAP HANA 2.0 platform lifecycle management blog, hdblcm is a ‘wrapper’ tool that calls other executables for the different actions. Action=install will call hdbinst and action=update will call hdbupd. In the Client section below, you can see that we can run these tools independently as well with a response file, for example, when installing the SAP HANA client on a client computer.

Server

In the Server section, all the parameters specific to the HANA database server are specified. The sid is required, all others are optional.

For more information about these parameters, see

  • SAP HANA 2.0 Server Installation

Storage

The storage_cfg parameter points to the directory where you have placed the customized global.ini file. This makes it possible to set up a storage connector, allowing SAP HANA to use hardware vendor-specific scripts for automated resource allocation and input/output fencing during failover.

For an example of such an implementation, see

  • Storage Configuration Best Practices for SAP HANA TDI on Dell EMC VMAX 33 Solution Guide
  • Implementing High Availability and Disaster Recovery Solutions with SAP HANA on IBM Power Systems

For the documentation, see

  • Tutorial: Using Custom Configuration Files – SAP HANA Server Installation and Update Guide

Note that the hdbparam utility is no longer included with SAP HANA 2.0 and has been deprecated.

  • 2267798 – Configuration of the SAP HANA Database during Installation Using hdbparam
  • 2399079 – Elimination of hdbparam in HANA 2

Storage Configuration Best Practices for SAP HANA TDI on Dell EMC VMAX 33 Solution Guide

Implementing High Availability and Disaster Recovery Solutions with SAP HANA on IBM Power Systems

The AddHosts section covers the parameters relevant to distributed (multi-host) systems: the hostname of the hosts and the host role.

Optional Components

There is a dedicated section for each of the different host roles (Streaming Analytics, Dynamic Tiering, Accelerator for ASE and Remote Data Synch. When these components are not listed in the General section, these sections are ignored by the installer.

For more information about these features, see

  • SAP HANA 2.0 editions (2018)

XS Advanced

For the XS Advanced runtime, there is another dedicated parameter section.

For more information about these parameters and about installing XSA, see

  • SAP HANA 2.0 XS Advanced Installation

Client and Studio

Finally, there is a section about the SAP HANA client and studio. See

Configure the Password File

As we have seen, there are several locations where passwords can be specified in the configuration file. Master password in the General section, operating system accounts (root, sapadm, adm) and database users in the Server section, accounts for features, and for XS Advanced.

Typically, a security administrator will not be amused when passwords are specified in text files.

For this reason, the  read_password_from_stdin=xml parameter is available to indicate to hdblcm when running in batch mode to get the passwords from ‘standard input’, which for UNIX refers to commands entered on the command line.

However, as we still want to automate the installation, we are now going to set the passwords in another configuration file, this time in XML format, which we can secure and include in the installation process as appropriate.

In the vi editor, you can use the substitute command to easily change the asterisks to a new master password.

:%s/\*\*\*/your-master-password/

For more information, see

  • Specifying Passwords – SAP HANA Server Installation and Update Guide

Install in Batch Mode

When we are done with editing the configuration and password file, we can simply run the install in batch mode with the -b (or –batch) parameter together with —configfile.

Parameters passed as call options to the installer take precedence over parameter defined in the configuration file.

You could, for example, generate the SID parameter using a script and pass it to the installer in case you need unique values.

#!/bin/bash
# sample script to explain the concept
# do not try this at home or at work

for i in {0..9} do
./hdblcm -b --sid=EZ$i –-configfile=server.cfg
done
exit 0

To include our password parameter file, we are going to make use of more UNIX magic: the pipe. This allows us to pass the passwords to the installer without displaying them on the console or in command history.

cat ~/passwords.xml | ./hdblcm --sid=DB1 \
--read_password_from_stdin=xml \
--configfile=server.cfg -b

SAP HANA Client

To automate installations of the SAP HANA client (or studio) on a system that do not contain an SAP  HANA server installation, we can use the same approach.

First, generate a configuration file and edit the parameters. This time, use the hdbinst or hdbupd executable directly (and hence we no longer need to specify the action= parameter). Again, the name and extension of the response file are irrelevant.

To install, run the command specifying –batch (-b) with configfile.

For the parameter reference, see

  • Command and Call Option Reference – SAP HANA Client Installation and Update Guide
# Windows in command prompt
hdbinst.exe --dump_configfile_template=c:\temp\client.rsp
hdbinst.exe -b --configfile=c:\temp\client.rsp

# UNIX, Linux, macOS 
./hdbinst --dump_configfile_template=/tmp/client.cfg
./hdbinst -b --configfile=/tmp/client.cfg

References

For more information see:

SAP HANA Academy Playlists

  • SAP HANA Installation and Update – SAP HANA 2.0 SPS 02

SAP Community Blogs

  • SAP HANA 2.0 editions (2018)

SAP Documentation

  • Tutorial: Automating Installation – SAP HANA Server Installation and Update Guide
  • Tutorial: Using Custom Configuration Files – SAP HANA Server Installation and Update Guide
  • Parameter Reference – SAP HANA Server Installation and Update Guide
  • Specifying Passwords – SAP HANA Server Installation and Update Guide
  • Command and Call Option Reference – SAP HANA Client Installation and Update Guide

Notes

  • 2267798 – Configuration of the SAP HANA Database during Installation Using hdbparam
  • 2399079 – Elimination of hdbparam in HANA 2
  • 2186744 – FAQ: SAP HANA Parameters

SAP Partner Documentation

  • Storage Configuration Best Practices for SAP HANA TDI on Dell EMC VMAX 33 Solution Guide
  • Implementing High Availability and Disaster Recovery Solutions with SAP HANA on IBM Power Systems

Thank you for watching

The SAP HANA Academy provides technical enablement, implementation and adoption support for customers and partners with 1000’s of free tutorial videos.

For the full library, see SAP HANA Academy Library – by the SAP HANA Academy

For the full list of blogs, see Blog Posts – by the SAP HANA Academy

  • Subscribe to our YouTube channel for updates
  • Join us on LinkedIn linkedin.com/in/saphanaacademy
  • Follow us on Twitter @saphanaacademy
  • Google+ plus.google.com/+saphanaacademy
  • Facebook facebook.com/saphanaacademy



This post first appeared on Web Service Testing A Blackjack GUI And API, please read the originial post: here

Share the post

SAP HANA Installation Automation – by the SAP HANA Academy

×

Subscribe to Web Service Testing A Blackjack Gui And Api

Get updates delivered right to your inbox!

Thank you for your subscription

×