sap.sap_operations.system module – Manage SAP system

Note

This module is part of the sap.sap_operations collection.

It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install sap.sap_operations. You need further requirements to be able to use this module, see Requirements for details.

To use it in a playbook, specify: sap.sap_operations.system.

New in sap.sap_operations 1.0.0

Synopsis

  • Start and stop SAP system.

Requirements

The below requirements are needed on the host that executes this module.

  • python >= 3.6

  • suds >= 1.1.2

Parameters

Parameter

Comments

ca_file

string

ca_file use CA certificate to secure the communication. By default system CA store is used.

hostname

string

hostname of the SAP system

instance_number

string / required

The instance number of the managed service.

Must be between “0” and “99”.

name

string

name name of the feature to be managed.

Choices:

  • "ALL" ← (default)

  • "SCS"

  • "DIALOG"

  • "ABAP"

  • "J2EE"

  • "TREX"

  • "ENQREP"

  • "HDB"

  • "ALLNOHDB"

  • "LEVEL"

password

string

password of the SAP system

secure

string

secure specify if secure communication should be enforced.

By default system CA store is used. User can pass custom CA by ca_file parameter.

Choices:

  • "strict" ← (default)

  • "insecure"

  • "none"

state

string

State of the managed system.

Choices:

  • "started" ← (default)

  • "stopped"

username

string

username of the SAP system

wait

boolean

Wait for the operation to complete before returning.

If set to true, module will wait for service to start/ or stop.

If set to false, module will schedule the right operation and return immediately.

Choices:

  • false

  • true ← (default)

wait_timeout

integer

Wait timeout for the operation to complete before returning.

Default: 600

See Also

See also

How to use the SAPControl Web Service Interface

How to use the SAPControl Web Service Interface

Examples

- name: Use module with local socket on target machine
  sap.sap_operations.system:
    instance_number: "0"

- name: Start system
  sap.sap_operations.system:
    username: "npladm"
    password: "secret123!"
    hostname: "sap.system.example.com"
    instance_number: "0"
    state: started

- name: Stop system
  sap.sap_operations.system:
    username: "npladm"
    password: "secret123!"
    hostname: "sap.system.example.com"
    instance_number: "0"
    state: stopped

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

system

dictionary

System info

Returned: always

Sample: {"dispstatus": "SAPControl-GREEN", "features": "MESSAGESERVER|ENQUE,", "hostname": "vhcalnplcs,", "httpPort": "50113,", "httpsPort": "50114,", "instanceNr": "1,", "startPriority": "1,"}

Authors

  • Ondra Machacek (@machacekondra)

  • Kirill Satarin (@kksat)