
In this blog post, I share hands-on insights on how to minimize downtime for your SAP HANA Cloud database by leveraging SAP Automation Pilot. By simply going through this step-by-step guide, you will learn how easy it is to set up SAP Automation Pilot to perform automated availability checks effortlessly, so that you minimize disruptions, keep your business running smoothly and maximize performance!
Undoubtedly, ensuring that your HANA Cloud instances are always up and running can be crucial for the success of your business operations. In Biser Simeonov's last blog post co-authored by me, “Automated Availability Check for SAP HANA Cloud (on CF level) with SAP Automation Pilot”, we showed you how to automate the monitoring of your HANA Cloud instances enabled in a Cloud Foundry space by using SAP Automation Pilot and SAP Alert Notification Service for SAP BTP – two powerful tools from the SAP Business Technology Platform (SAP BTP) DevOps portfolio. You learned how to utilize these tools to check the availability of your instances, and even start the ones that are not accessible. So far so good!
However, with the 2022 QRC3 release in October 2022, SAP HANA Cloud went "multi-environment". As a result, now you can have HANA Cloud instances in subaccounts that don’t have the Cloud Foundry environment enabled. For more information, see:
In the following guide, I will show you how to perform the same HANA Cloud Availability Check for HANA Cloud instances enabled in “Other Environments” (multi-environment setup).
The process is visualized in the graphic below. I advise you to check out the previous blog post for a more detailed explanation.
After you’ve made sure that you meet all the prerequisites, you can proceed with the steps below.
1. Verify that you have provisioned SAP Automation Pilot. You should be able to see it in the “Subscriptions” section in your subaccount:
NOTE: SAP Automation Pilot can interact with resources in any BTP landscapes. All you need is to have at least one instance of SAP Automation Pilot.
2. Verify that you have Alert Notification and Service Manager instances, and that your HANA Cloud instance is enabled in “Other Environments”.
Your Service Manager instance can be provisioned either in your subaccount, or in your space. The only difference this will make is whether you will have to create a “Service Binding” or a “Service Key” later.
3. You need to create a Service Key for your Alert Notification service instance. This key will be used on a later stage by the SAP Automation Pilot command. To create a Service Key, choose the “Create Service Key” option:
Enter a name for your service key and choose “Create”:
4. Next, you need to create a “Service Binding” for your HANA Cloud instance, which will be used by the SAP Automation Pilot command. To do that, choose the “Create Service Binding” option:
Enter a name for your service binding and choose “Create”:
5. Depending on the scope of your Service Manager instance, you need to create:
6. The SAP Automation Pilot team has prepared a catalog with example commands, which can be imported directly into your SAP Automation Pilot instance.
Copy the contents of the catalog:
7. Now you need to import the catalog with example commands in your SAP Automation Pilot instance. From the left-side menu, choose “My Catalogs” and then “Import”:
Paste the catalog and choose “Import”:
8. You can see the imported catalog “Automation Pilot Examples” in “My Catalogs”. From this catalog, choose “Commands”:
9. From the catalog, open the “CheckHanaCloudMultiEnvAvailabilitySample” command by clicking on it. Explore the Input Keys, the Output Keys, and the Executors of the command:
10. Scroll down to “Configuration” and choose the “notifyANS” executor. You need to define the event that SAP Automation Pilot will ingest into Alert Notification service. Choose “Edit” to edit the properties of your event:
You can use these example values for the required event properties of your event:
11. After you have done that, trigger the command:
12. You need to provide values for the following input keys:
You can also look at the prepared outputs (no need to provide values for them but it is important to understand what data is returned as the command's output):
13. Provide values for all input keys and then trigger the command:
There are two possible options for the outcome of the execution:
Option 1: Your HANA Cloud instance is accessible and the command for starting HANA Cloud has not been triggered. You should be able to see the following execution details:
If you click on “Output Values”, you can see the output values for checkPing, isHanaCloudAvailable, and resultHanaStart:
You can verify in SAP Hana Cloud Central that your HANA Cloud instance is up and running:
Option 2: Your HANA Cloud instance is not accessible and the command for starting HANA Cloud has been triggered:
You can verify in SAP Hana Cloud Central that your HANA Cloud instance is starting:
If you click on “Output Values”, you can see the output values for checkPing, isHanaCloudAvailable, and resultHanaStart:
You have successfully performed the HANA Cloud Availability Check via SAP Automation Pilot. Now you can make a subscription in Alert Notification service, so that you can receive a notification when SAP Automation Pilot detects that your multi-environment HANA Cloud instance is not accessible. If you want to do that, continue with the following steps:
14. Navigate to your Alert Notification service instance and open it. Choose the “Subscriptions” tab form the left-side menu and then “Create” to create a new subscription:
15. Enter a name for your subscription and click “Create” to move on to the next step:
16. Next, create a Condition. Give your condition a name. Then define your condition by choosing the event property “eventType”, operand “Is Equal To”, and, in our case, expected value “FailedHCAvailabilityCheck”:
The expected value for “eventType” is the one you provided in step 10:
17. To finish your subscription in Alert Notification service, select an Action by choosing “Create Action”:
Select an Action Type of your preference, for example “Email” and choose “Next”:
Give your Action a name, and then provide the email address where you want to receive the email notification:
NOTE: After you have created some of the actions, they are labeled as Not Confirmed. To enable them, you have to confirm them as described in Confirming Actions.
Choose “Save” to finish making your subscription. You will see a confirmation that your subscription was created:
You can find more information about Subscriptions, Conditions, and Actions in Configuration Management Using the SAP BTP Cockpit.
18. Now you can test your subscription. If you stop your HANA Cloud Instance and trigger the CheckHanaCloudMultiEnvAvailabilitySample command again, you will receive an email from Alert Notification service with information that the HANA Cloud Availability Check has failed. You can see an example email below:
NOTE: If you also want to receive notifications in a Microsoft Teams channel of your choice, check out the previous blog post for a detailed step-by-step explanation on how to make this configuration.
In this blog, you've learned to utilize SAP Automation Pilot and SAP Alert Notification service for SAP BTP to effectively monitor the availability of your multi-environment HANA Cloud instances. By using these innovative tools in your daily operations, you can save time, prevent potential disruptions, and ensure your operations continue to run smoothly. If you are interested to learn more about these products and how they can transform your business, please refer to the following sources:
SAP Automation Pilot:
SAP Alert Notification service for SAP BTP:
You can also check out these very useful tutorials prepared by our colleague Dan van Leeuwen:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
12 | |
12 | |
11 | |
11 | |
11 | |
9 | |
8 | |
7 | |
7 | |
6 |