Posts

Showing posts from July, 2020

How to disable Hana system replication

Stop the secondary system: sapcontrol -nr <instance_number> -function StopSystem HDB On secondary system unregister the secondary system: hdbnsutil -sr_unregister If you want to use this secondary as a normal SAP HANA installation from now on, you have to start it to complete the unregistration. On the secondary execute: sapcontrol -nr <instance_number> -function StartSystem HDB On primary system disable system replication: hdbnsutil -sr_disable

recoverSys failed: no valid master host found

Solution: 1> Check if the sapstartsrv is running.If not, start it and initiate the recovery again Command: sapcontrol -nr <instno> -function StartService <HanaSID>

Securing HANA 2.0 Cockpit via SSL / HTTPS

Problem: Generating SSL certificates for hana does not update the Cockpit/XS SSL Certificates Solution: IF the normal HANA Certificates and PSE files are already existing you can just continue with the commands below. Please keep in mind that the XSA will be automatically restarted at the end and that the HANA Cockpit will therefore be temporarily unavailable. Procedure is described in the note  2631903 - HANA Basic How-To Series - Securing HANA 2.0 Cockpit via SSL / HTTPS (EXAMPLE: Microsoft CA edition)    Useful commands cd $SECUDIR cp -p blueprint_sapsrv.pse cockpithttps.pse sapgenpse export_p12 -p cockpithttps.pse -C 0 cockpithttps.12 mv cockpithttps.12.p12 cockpithttps.p12 openssl pkcs12 -in cockpithttps.p12 -nocerts -nodes | sed -ne '/-BEGIN PRIVATE KEY-/,/-END PRIVATE KEY-/p' > privatekey.key openssl pkcs12 -in cockpithttps.p12 -clcerts -nokeys | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > certificate.pem openssl pkcs12 -in cockpithttps.p12 -...

HDB daemon does not start after a unclean stop/shutdown of services

Problem: HDB daemon does not start after a unclean stop/shutdown of services and the daemon status file still has the old value Solution:  Command: HDB stop ( give a try ) if not HDB kill-9 ( not recommended for production systems ) sapcontrol -nr <> -function StopService sapcontrol -nr <> -function StartService <SID> HDB start This should give a  clean restart of the services.

HDB Daemon does not start after Hana host rename failed

Problem:  Hana host rename is attempted and failed. Rename fails with hdbdaemon not starting . Solution: Hana rename generally touches the following files during rename.Give a check if it really has changed the old hostname in all the locations. Configuring user home '/hana/shared/SID/home'    ---------------------------------------------------------  INFO:     /hana/shared/SID/home/.cshrc already exists -> overwriting  INFO:     Copy /hana/shared/SID/global/hdb/install/support/CSHRC to /hana/shared/SID/home/.cshrc  INFO:     /hana/shared/SID/home/.sapsrc.sh already exists -> overwriting  INFO:     Copy /hana/shared/SID/global/hdb/install/support/SAPSRC.SH to /hana/shared/SID/home/.sapsrc.sh  INFO:     /hana/shared/SID/home/.sapsrc.csh already exists -> overwriting  INFO:     Copy /hana/shared/SID/global/hdb/install/support/SAPSRC.CSH to /hana/s...

XS/Cockpit URLs SSL certificates are not updated after HANA DB SSL Certificate renewal

Problem:  XS URLs  SSL certificates are not updated after HANA DB SSL Certificate renewal Cause:  AP HANA 2.0 Cockpit is based on  SAP HANA XS Advanced (XSA)  which handles certificates a bit different than the former XS classic implementation. The XSA SSL certification is sometimes overwritten with a new installation/update. Solution: You need to bundle the certificate chain and import it to the XSA cert path. Export certificates for XSA sapgenpse export_p12 -p cockpithttps.pse -C 0 cockpithttps.p12 Export private key, certificate and CA chain & combine certificate and CA chain into 1 file. openssl pkcs12 -in cockpithttps.p12 -nocerts -nodes | sed -ne '/-BEGIN PRIVATE KEY-/,/-END PRIVATE KEY-/p' > privatekey.key openssl pkcs12 -in cockpithttps.p12 -clcerts -nokeys | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > certificate.pem openssl pkcs12 -in cockpithttps.p12 -cacerts -nokeys | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > cach...