• SAP HANA

saphana
  1. Help Center
  2. SAP HANA
  3. User Guide (API)
  4. Typical Deployment Scenarios
  5. Single-Node Scenario Where HA Is Required
  6. Creating Two HANA ECSs

Creating Two HANA ECSs

Follow the instructions provided in section Creating a HANA ECS to create two HANA ECSs.

Ensure that the os:scheduler_hints anti-affinity group field is added to the message body for creating the HANA ECSs.

Create an ECS. Determine the ECS flavor based on the application scenario.

POST /v2/${tenant_id_1}/servers
{
    "server": {
        "flavorRef": "e1.xlarge",
        "name": "hanastudioAPI",//You are suggested to name the ECSs differently in HA scenario.
        "block_device_mapping_v2": [{
                "source_type": "volume" ,
                "device_name": "/dev/sda",
                "destination_type": "volume",
                "uuid": "772004c7-9ca9-4a1d-8ff1-84256f3e0ff9",                "delete_on_termination": "True",
                "boot_index": "0"
        }],
            "networks": [{
                 "port": "db9d412b-84e8-4d96-9d1a-cf1aaed9b501"
}],
            "key_name": "fankeypair01",//Key pair name
            "metadata":{
                "__vhostmd":true
            },
            "user_data":"I2Nsb3VkLWNvbmZpZwpkaXNhYmxlX3Jvb3Q6IGZhbHNlCnJ1bmNtZDoKLSBzZWQgLWkgJ3MvXlBlcm1pdFJvb3RMb2dpbi4qJC9QZXJtaXRSb290TG9naW4gd2l0aG91dC1wYXNzd29yZC8nIC9ldGMvc3NoL3NzaGRfY29uZmlnCi0gc2VkIC1pICcvXktleEFsZ29yaXRobXMuKiQvZCcgL2V0Yy9zc2gvc3NoZF9jb25maWcKLSBzZXJ2aWNlIHNzaGQgcmVzdGFydA==",
        "availability_zone": "aaa"//aaa is used as an example of the AZ.
    },
    "os:scheduler_hints":{
        "group": "2645f9ef-19d2-4247-ab30-4256b783a34f"//Anti-affinity group ID
    }
}