Installing HANA Express 2.0 and XSA: Installation
This blog post is a part of a larger series. You can navigate the series here:
|Installation (this post)|
Remember from our deployment options discussion that our objective is to have a fully functioning SAP HANA instance available over the internet while being hosted in the cloud. In this post we’ll walk through the necessary installation steps for native Linux deployments on AWS.
|AWS Account Registration||You must register for an AWS account at aws.amazon.com|
|SAP Account Registration||You must register for an SAP account at developers.sap.com.|
|HANA Download Manager||Navigate to the Trials and Downloads section and choose SAP HANA Express. Click the Free Download button and complete the registration form. Be sure to download the 64 bit Linux version.|
The installation requires Java 8 runtime. The best version is the SAP JVM available here: https://tools.hana.ondemand.com/#cloud. You can also use the main repository at java.com. The file names will be different but either will work.
Make sure to download the most recent (8.1+) .rpm file for 64bit linux.
|SSL Certificate||An SSL certificate is required for communication with SAP HANA Express. Since I will be using my own domain name I will also need an SSL certificate for that domain to be installed on the server. You can use GoDaddy or a similar provider of domains & certificates.|
|SAPCRYPTOLIB||The current SAP HANA Express version has an old version of SAPCRYPTOLIB used for secure communications. We’ll need to download the latest version from support.sap.com.|
A few side notes before we continue:
The Download Manager step doesn’t actually download SAP HANA Express, but a small executable that we will copy to the server later to run natively from Linux.
Also, you will want to update and maintain your environment as time goes on. Unfortunately, as of this writing, the current version of HANA Express is unable to execute HXECheckUpdate_linux.bin. This executable is used post-install for maintenance updates.
This file is not downloadable anywhere that I could find and it can’t be redistributed by me, so the best workaround is to spin up a CAL deployment of the current image, copy the file for safekeeping, and terminate all instances and storage for the CAL deployment. At a later time you can copy this file to the correct location on your SAP HANA Express server.
Finally, I am performing this tutorial from OSX so my downloads default to the Downloads folder. My step-by-step terminal commands depend on this assumption. If you are not on OSX or are using a different folder for downloads you will need to adjust the local commands executed on your machine accordingly.
Login to your Amazon account and navigate to the EC2 Dashboard and select Launch Instance.
This will initiate a short workflow in which we will configure according to the following options:
|AMI Image||SUSE Linux Enterprise Server 12 SP4 (HVM)|
|Configure Instance||Default settings|
|Add Storage||200GB (GP2)|
|Configure Security Group||See Port Listing|
Select the SUSE Linux Enterprise Server 12 SP5 (HVM) edition machine image.
Choose an instance type. I prefer an r5.xlarge as it gives me the best tradeoff between cost and performance. An r5.xlarge gives me 4 CPUs and 32GB of RAM.
Accept the default settings on the Configure Instance tab.
Increase the storage to a minimum of 150GB. I prefer 200GB and I prefer to use the General Purpose SSDs to avoid incurring costs associated with the premium storage options which are more expensive and incur costs even when the system is shutdown.
Next, you can add tags if you wish. For our small environment we’ll skip this for now.
In the security group configuration we will open the necessary ports to allow communication from our local machine to the SAP environment.
Make sure to include all of the following ports:
Finally you will be able to review all configuration settings one last time. Choose Launch Instance when you are ready.
Access to your server will require a key. In this step you create a new key pair and download a copy (or use an existing key pair if you already have one). Be sure to store the key in a safe place!
Be sure to name your key pair something meaningful to you. Your server will take a few minutes to initialize but should be visible in the EC2 dashboard. The dashboard will show the IP address of your server. At this point, you can continue to use the IP address given but I prefer to associate an Elastic IP address with the instance and change my domain DNS entry (managed at GoDaddy) to point to the static IP address. This makes it much easier to SSH into the server for installation and maintenance tasks.
Now we need to make sure we can SSH into the server to continue the installation process. We start on our local machine where we downloaded the server key during the launch process.
Since the key is a sensitive file we need to adjust the permissions to reflect greater security using the chmod command. Then we add the key to the keychain using ssh-add. Finally, we ssh to our instance using the IP address or domain name (optional). Note the AWS default user is ec2-user.
Open a terminal session on your local machine and use the commands below. Be sure to use the name of the key file you specified before downloading the key pair.
cd Downloads chmod 400 RADE-HANA.pem ssh-add -k RADE-HANA.pem ssh -i RADE-HANA.pem email@example.com
At this point you should have a working, accessible linux instance to serve as a foundation for your SAP HANA Express Install. You should also update your repositories with the following command:
sudo zypper update
We’ll be using the sudo command throughout and need to make sure the necessary user accounts have sudo privileges.
Find the two lines in the file that look like this:
Defaults targetpw # ask for the password of the target user i.e. root
ALL ALL=(ALL) ALL # WARNING! Only use this together with ‘Defaults targetpw’!
and comment them out by adding the double pound sign in front.
Then add the following lines
ec2-user ALL=(ALL) NOPASSWD:ALL hxeadm ALL=(ALL) NOPASSWD:ALL
Save the file by pressing ESC, then :wq, then ENTER.
We still need to install the Java runtime that we downloaded in the preparation phase. Using the same terminal session I will exit to my local machine and copy the Java .rpm file from my Downloads folder to the server.
exit scp jre-8u231-linux-x64.rpm firstname.lastname@example.org:/tmp/jre-8u231-linux-x64.rpm
Connect to the server and begin the Java installation using the following commands:
ssh email@example.com cd /tmp sudo rpm -ivh jre-8u231-linux-x64.rpm
When Java completes, clean up the disk and exit back to your local machine:
sudo rm *.rpm exit
Next we’ll copy the HXEDownloadManager_linux.bin file in our local Downloads folder to the server then make sure the file is executable. We’ll also create a folder on the server to store the downloads triggered by the installation process.
scp HXEDownloadManager_linux.bin firstname.lastname@example.org:/tmp/HXEDownloadManager_linux.bin
Connect to the server and change the file permissions
ssh email@example.com cd /tmp chmod +x HXEDownloadManager_linux.bin
Create a folder on the server for downloads and execute the download manager with the desired options for installation
cd /home/ec2-user mkdir Downloads cd /tmp ./HXEDownloadManager_linux.bin linuxx86_64 installer hxe.tgz hxexsa.tgz eadesigner.tgz shine.tgz eml.tgz apl.tgz sdi.tgz dwf.tgz
NOTE: I recommend NOT installing SAP HANA Streaming Analytics during the initial installation. Installing SAP HANA Streaming Analytics causes a conflict with openssl which is necessary to properly configure the SSL certificates for the server. It will save you some trouble to install this component AFTER the server is securely accessible.
|shine.tgz||SAP HANA Interactive Education|
|sdi.tgz||Smart Data Integrator|
|hsa.tgz||HANA Streaming Analytics|
|apl.tgz||Automated Predictive Library|
|eml.tgz||External Machine Learning|
|dwf.tgz||Data Warehousing Foundation|
Once the downloads are complete we can extract the archives
cd /home/ec2-user/Downloads tar vxf hxe.tgz tar vxf hxexsa.tgz tar vxf shine.tgz tar vxf sdi.tgz tar vxf hsa.tgz tar vxf apl.tgz tar vxf eml.tgz tar vxf dwf.tgz tar vxf eadesigner.tgz
Finally, we can begin the installation
At this point, the installation should run attended for 90 minutes or so as it completes the setup process.
In the next post we will perform additional steps to configure the server for our domain name and SSL certificates.