Giter VIP home page Giter VIP logo

hana-devops's Introduction

SAP HANA VM deployments using Azure Marketplace Images

This Repository can be used with Azure DevOps to deploy a SAP HANA DB 2.0 with the following features:

  • SLES 12 & 15
  • RHEL 7 & 8
  • VM sizes from 128GB to 12TB
  • OS Preparation with required patches and configurations according to relevant SAP notes
  • HANA 2.0 DB Installation
  • Backup Integration into an Azure Recovery Service Vault including execution of initial backups
  • Execution of HANA Clound Measurement Tool (HCMT)
  • Removal of the complete deployment

Note: Eds_v4 Series use premium disk without write accellerations, therefore this is recommended for Non-PRD envrionments only

VM Sizes and Storage Configurations

Size HANA VM HANA VM Storage (EXE + DATA + LOG + SHARE + BACKUP)
128_GB E16ds_v4 1xP6(64GB) + 3xP6(64GB) + 3xP10(128GB) + 1xP20(512GB) + 1xP20(512GB)
160_GB E20ds_v4 1xP6(64GB) + 4xP6(64GB) + 3xP10(128GB) + 1xP20(512GB) + 1xP20(512GB)
192_GB M32ts 1xP6(64GB) + 4xP6(64GB) + 3xP10(128GB) + 1xP20(512GB) + 1xP20(512GB)
256_GB M32ls 1xP6(64GB) + 4xP6(64GB) + 3xP10(128GB) + 1xP20(512GB) + 1xP20(512GB)
512_GB M64ls 1xP6(64GB) + 4xP10(128GB) + 3xP10(128GB) + 1xP20(512GB) + 1xP20(512GB)
1.000_GB M64s 1xP6(64GB) + 4xP15(256GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)
1.792_GB M64ms 1xP6(64GB) + 4xP20(512GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)
2.000_GB M128s 1xP10(128GB) + 4xP20(512GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)
2.850_GB M208sv2 1xP10(128GB) + 4xP30(1024GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)
3.892_GB M128ms 1xP10(128GB) + 5xP30(1024GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)
5.700_GB M416sv2 1xP10(128GB) + 4xP40(2048GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)
11.400_GB M416msv2 1xP10(128GB) + 4xP50(4096GB) + 3xP15(256GB) + 1xP30(1TB) + 1xP30(1TB)

Prerequesites

  1. Azure Subscription
  2. Azure DevOps and Github account
  3. S-User for SAP Software Downloads
  4. Basic Resources
    • VNET + Subnet
    • Recovery Service Vault with Policies for HANA & OS Backups, "HANA-Non-PRD", "HANA-PRD", "OS-Non-PRD", "OS-PRD"
    • Storage Account (For SAP binaries, Scripts & Boot Diagnostics)
    • Private DNS Zone (Makes everything easier)
    • For green field deployments and especially production workloads please consider using the Microsoft Cloud Adoption Framework for SAP on Azure
  5. Setup your own DevOps Deployment Agent within the same or peered VNET
    • Option A) Manually

      • Deploy an Ubuntu 18.04 VM. Use a public ssh-key
      • Store you private ssh-key in ~.ssh/id_rsa. Ensure correct file permission. This step is required for Ansible remote ssh to deployed HANA VMs
      • Install PowerShell
      • Install Ansible 2.10.*
      • Setup an Azure DevOps Deployment Agent in your landing zone
      • Add your private ssh key to the os user on the agent (.ssh/id_rsa)
      • Install Azure CLI: curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash and perform az login --use-device-code. Preferable for a permanent login create a service principle
      • User a puplic ssh-key
    • Option B) With this ARM-Template

      Deploy To Azure

      • Complete the DevOps Deployment Agent Setup with
        1. login with your ssh user and cd devopsagent ; ./config.sh -> follow the prompts and enter required information, have the PAT (personal access token) from DevOps ready see here where to retrieve the PAT
        2. sudo ./svc.sh install ; sudo ./svc.sh start
        3. az login
        4. put your private ssh-key in ~.ssh/id_rsa (ensure 600 file permission)

Deployment via Azure DevOps

  1. Fork this repository in Github or create your own new Repository based on this template
  2. Create a Project in Azure DevOps
  3. In the DevOps Pipeline Area
    • Create a "New Pipeline"
    • Where is your code? => "GitHub"
    • Select a repository => "/hana-devops"
    • Configure your pipeline => "Existing Azure Pipeline YAML file"
    • Branch "Main"
    • Path "/DevOpsPipeline/azure-pipelines.yml"
    • Continue and Click on the right side of the Run button to "Save"
    • Optionally change the name in the Pipeline overview
    • In the process you will need to connect your Github Repository with Azure DevOps details here
  4. Enter your required variables to the pipeline configuration, example here
  5. Add the Ansible Extension to your DevOps Project
  6. Download the SAP Binaries IMDB_SERVER*, HCMT* & SAPCAR* and store them in a storage container. Get the new URLs from for the files and update the variables url_sapcar, url_hdbserver, url_hcmt in Ansible/vars/defaults.yml
  7. Upload diskConfig.sh in the container and adapt variables url-disk-cfg in the Pipeline
  8. Upload msawb-plugin-config-com-sap-hana.sh to the container and adapt variable url_msawb_plugin in Ansible/vars/defaults.yml
  9. Adapt Target Subnet parameter, section: - name: vnet_subnet in the pipeline to match your landing zone target
  10. Setup the Azure Service Connection in project settings
  11. Add variable azureconnectionname in the pipeline
  12. Run the pipeline

Troubleshooting

  • ARM deployment fails because the URL to the diskConfig.sh Script is not reachable from the deployed VM. In this case login to the VM and try with wget to download the script. Use your own container in your storage account and ensure it's reachable from VMs in the target subnet
  • During Stage "Prepare_OS" ssh connection must work from the deployment agent to the HANA VM. In case of troubles try to connect from the agent maually via ssh and solve the issue. Connection must work without interactive ssh prompts. You might need to set StrictHostKeyChecking no in ~/.ssh/config when deploying VMs with different names to the same IP
  • HANA Installation fails when using forbidden SID: ADD, ALL, AMD, AND, ANY, ARE, ASC, AUX, AVG, BIT, CDC, COM, CON, DBA, END, EPS, FOR, GET, GID, IBM, INT, KEY, LOG, LPT, MAP, MAX, MIN, MON, NIX, NOT, NUL, OFF, OLD, OMS, OUT, PAD, PRN, RAW, REF, ROW, SAP, SET, SGA, SHG, SID, SQL, SUM, SYS, TMP, TOP, UID, USE, USR, VAR
  • more to come

hana-devops's People

Contributors

prasroy avatar videshmukh avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.