sap-linuxlab / community.sap_operations

Automation for SAP - Collection of Ansible Roles for various operational tasks with SAP Systems
Apache License 2.0
23 stars 19 forks source link
ansible sap-automation

community.sap_operations Ansible Collection Ansible Lint

This Ansible Collection executes various SAP Systems operational tasks, which can be used day-to-day individually or combined for more complex regular maintainance automation

Functionality

This Ansible Collection executes various SAP Systems operational tasks, including:

Contents

An Ansible Playbook can call either an Ansible Role, or the individual Ansible Modules:

For further information regarding the development, code structure and execution workflow please read the Development documentation.

Within this Ansible Collection, there are various Ansible Roles and Ansible Modules.

Ansible Roles

Name                    Summary
os_ansible_user creates Ansible user ansadm with ssh key
os_etchosts updates /etc/hosts
os_knownhosts updates known hosts file /.ssh/known_hosts
sap_control starting and stopping SAP systems
sap_fapolicy update service fapolicyd for generic / sap nw / sap hana related uids
sap_firewall update service firewalld for generic / sap nw / sap hana related ports
sap_profile_update update default and instance profiles
sap_rfc executes SAP RFCs
sap_rhsm Red Hat subscription manager registration

Ansible Modules

Name                    Summary
sap_operations.sap_facts gather SAP facts in a host (e.g. SAP System IDs and SAP System Instance Numbers of either SAP HANA database server or SAP NetWeaver application server)
sap_operations.sap_monitor_hana_status check status of running SAP HANA database server
sap_operations.sap_monitor_nw_status check status of running SAP NetWeaver application server
sap_operations.sap_monitor_nw_perf check host performance metrics from SAP NetWeaver Primary Application Server (PAS) instance
sap_operations.sap_monitor_nw_response check system response time metrics from SAP NetWeaver Primary Application Server (PAS) instance

Execution examples

There are various methods to execute the Ansible Collection, dependant on the use case. For more information, see Execution examples with code samples and the summary below:

Execution Scenario Use Case Target
Ansible Playbook
-> source Ansible Collection
-> execute Ansible Task
--> run Ansible Module
---> run Python/Bash Functions
Simple executions with a few activities Localhost or Remote
Ansible Playbook
-> source Ansible Collection
-> execute Ansible Task
--> run Ansible Role
---> run Ansible Module
----> run Python/Bash Functions
--> run Ansible Role
---> ...
Complex executions with various interlinked activities;
run in parallel or sequentially
Localhost or Remote
Python/Bash Functions Simple testing or non-Ansible use cases Localhost

Requirements, Dependencies and Testing

Operating System requirements

Designed for Linux operating systems, e.g. RHEL and SLES.

This role has not been tested and amended for SAP NetWeaver Application Server instantiations on IBM AIX or Windows Server.

Assumptions for executing this role include:

Python requirements

Python 3 from the execution/controller host.

Testing on execution/controller host

Tests with Ansible Core release versions:

Tests with Python release versions:

Tests with Operating System release versions:

Testing on target/remote host

Tests with Operating System release versions:

License

Contributors

Contributors to the Ansible Roles within this Ansible Collection, are shown within /docs/contributors.