Technical Articles
SAP HANA SPS upgrade step-by-step guide
Introduction.
Basis Administration in the Age of SAP HANA requires new skills from SAP Basis Administrators. One of them HANA DB Maintenance & Upgrade. For example, SPS updates should be installed at regular intervals to avoid errors and to keep your Database up to date
Prerequisites for HANA DB Upgrade.
You want to install a new SPS on SAP HANA database. For example, in EWA report you found
“SAP HANA database: Support Package has run out of security maintenance. Support with SAP Security Notes is no longer ensured.”

and

Resolution.
Corrections are shipped in the form of Revisions and Support Packages Stack (SPS) of the product’s components. We start from DEV landscape
Step 1. Preparation phase.
Step 1.1 What’s New
Check What’s New in SAP blog-posts and Webinars
For example, if we want Upgrade from SPS03 to SPS05
Related Blogs:
What’s New in SAP HANA 2.0 SPS 04
https://blogs.sap.com/2019/04/05/whats-new-in-sap-hana-2.0-sps-04-2/
What’s New in SAP HANA 2.0 SPS 05
https://blogs.sap.com/2020/06/26/whats-new-in-sap-hana-2.0-sps-05-2/
Related Webinars:
What’s New in SAP HANA 2.0 SPS 04
What’s New in SAP HANA 2.0 SPS 05
Step 2.2 Libraries updating
New SPS version may require a new version of Linux libraries in your system
Without required libraries updating process interrupt with error (for example)
“Cannot access required library ‘/opt/rh/SAP/lib64/compat-sap-c++-9′”*

* compat-sap-c++ – provides additional runtime compatibility libraries required by newer SAP NetWeaver / SAP HANA releases. These libraries are installed independently of the standard runtime
libraries provided by RHEL.
Installation of compat-sap-c++ requires a “Red Hat Enterprise Linux for SAP Solutions” subscription
Resolution for RHEL
-
Log in to your RedHat account
-
Go to Subscriptions tab
-
Copy Pool ID to clipboard

in RHEL CLI:
-
Register (username and password from RedHat account)
subscription-manager register –username=XXX –password=YYYY
-
Attach to pool
subscription-manager attach –pool=<pool id from clipboard>
3.Enable all sap* repositories for this system
subscription-manager repos –enable=”*sap*”
Output:

Now system ready to install libraries
yum install compat-sap-c++-9

yum install libatomic

check version
rpm – q compat-sap-c++-9 libatomic
Links:
How to subscribe RHEL 7 SAP HANA system to Extended Update Support (EUS) channel?
Overview of the Red Hat Enterprise Linux for SAP Applications subscription
Step 2.3 Backup
Backup SysetmDB and all tenants

Step 2.4 Update strategy and Media Download
For example, if you have SAP HANA SPS03 you can upgrade the system to SPS05 in one step.
Don’t forget about the installed plugins. Check installed Plug-ins in Hana Studio or DBACockpit transaction.
Find SPS on SAP Launchpad. For example, if you want upgrade to SPS05:

Download SAR archives with a correct version of plug-in from Launchpad too
NB: For HANA DB Rev51 ->LCAPPS plugin must be Rev51 version too
Step 2.5 Media Upload
1. Upload SAR archives to HANA DB server.
2. Extract files from SAR archives.
3. Important moment. Structure after extracting procedure must be separated like:

Step 2.6 Check disk space
Check free space at the mount point /hana/shared/<SID>
Without required free space updating process interrupt with error /hana/shared/<SID> “NOT ENOUGH SPACE LEFT”
For example, updating procedure from SPS03 to SPS05 required 9.5GB of free space at /hana/shared/<SID>
N.B. For partitions in ext3/ext4 you can extend size “on the fly”
Find bindings between mount point /hana/shared/<SID> and volume group / logical volume
lsblk
For example, extend size on 10GB
lvextend -L +10G /dev/<volume group>/<lodical volume>xfs_growfs /dev/<volume group>/<lodical volume>

Step 2.7 Stop systems
-
Stop SAP systems running on HANA DB.
AAS -PAS – ASCS (SCS) – ERS
NB: stopsap j2ee *for Java systems
stopsap R3 *for ABAP systems
2 . Stop HANA DB
NB: su – <sidadm>
HDB stop
NB: Average time for HANA DB stopping: 5-20 minutes (this measure depends on the DB-size).
Step 2. Update phase.
Run command from root privileges from a folder with extracted HANA SPS-files,
/<extracted path>/SAP_HANA_DATABASE/hdblcm –ignore=check_signature_file (minus,minus)
HDBLCM found components for updating:

Updating procedure:

Step 3. Post update phase.
Step 3.1 Check new version
NB: su – <sidadm>
HDB version
Step 3.2 Start systems
HANA DB already started automatically at this point so time to start application server in reserve sequence
ERS – ASCS (SCS) – PAS – AAS
NB: startsap j2ee *for Java systems
startsap R3 *for ABAP systems
Step 3.3 Consistency check
Log-in in your SAP system to 000 client and check output of transaction SICK
Conclusion.
Repeat steps above for HANA DB in QAS system and after additional approvals in PROD landscape.
SAP BASIS Routine task with examples from real life was provided
Nice Info !
Hello,
Attention! I believe you forget something very important.
The command is not hdblcm –ignore=check_signature_file
The right command is the following one (with two hyphen symbol (-) and not only one): hdblcm - -ignore=check_signature_file
Keep in mind that in linux you need to use the following command:
./hdblcm - -ignore=check_signature_file (put both hyphen together)
Read the following sap note for all the details about this command and other things regarding this specific procedure:
2078425 – Troubleshooting note for SAP HANA platform lifecycle management tool hdblcm
Thank you,
João Dimas – SAP ADM
Hello
Does the SPS upgrade require any testing as far as application side is concerned or it's just a technical matter that can be sorted out by Basis Team w/o any concern?
Thanks!
I think in "Updating procedure" step you need to add some more steps or selecting all (1) option is enough?
We have a multi-Tenant platform for DEV and QA and Isolated Instance for PRD.
The following code works in DEV and QA but not in PRD. We went from SAP HANA 2.0.03 TO 2.0.05
I had check the configuration settings for SQLScript nothing out of the ordinary missing. What can it cause for this feature not to work...... Note: all other new features from 03 works in 05.
CREATE TABLE employees (employee_id INTEGER, employee_name VARCHAR(30));
INSERT INTO employees VALUES (1, 'John');
INSERT INTO employees VALUES (20010, 'Sam');
INSERT INTO employees VALUES (21, 'Julie');
INSERT INTO employees VALUES (10005, 'Kate');
DO BEGIN
DECLARE CURSOR cur FOR SELECT * FROM employees FOR UPDATE;
FOR r AS cur DO
IF r.employee_id < 10000 THEN
UPDATE employees SET employee_id = employee_id + 10000
WHERE CURRENT OF cur;
ELSE
DELETE FROM employees WHERE CURRENT OF cur;
END IF;
END FOR;
END;