sap.sap_operations.abap_system_info (1.25.0) — module

Fetch SAP ABAP system information

| "added in version" 1.2.0 of sap.sap_operations"

Authors: Gloria Ciavarrini (@gciavarrini), Kirill Satarin (@kksat)

Install collection

Install with ansible-galaxy collection install sap.sap_operations:==1.25.0


Add to requirements.yml

  collections:
    - name: sap.sap_operations
      version: 1.25.0

Description

Fetch information about SAP ABAP system

Information if fetched from SAP ABAP system using following remote enabled RFCs OCS_GET_INSTALLED_SWPRODUCTS OCS_GET_SFW_COMPONENTS TH_GET_VIRT_HOST_DATA DELIVERY_GET_INSTALLED_COMPS SMLG_GET_DEFINED_GROUPS SMLG_GET_DEFINED_SERVERS SMLG_GET_SETUP SLDAG_GET_COMPUTER_INFO

Uses NWRFC binary to connect to SAP and call remote enabled RFCs.


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Collection information about SAP ABAP system
  sap.sap_operations.abap_system_info:
  rfc_connection:
    ashost: application-instance-hostname
    client: '000'
    user: DDIC
    passwd: "SecretPa$$word" # notsecret
    sysnr: '00'

Inputs

    
rfc_connection:
    aliases:
    - abap_system
    description:
    - Dictionary with RFC connection parameters and configuration to connect to SAP ABAP
      system
    required: false
    suboptions:
      ashost:
        description: SAP ABAP application instance hostname
        required: false
        type: str
      client:
        default: '000'
        description: SAP ABAP connection client (mandant)
        required: false
        type: str
      group:
        description: SAP ABAP application system connection group (when connected to message
          service)
        required: false
        type: str
      lang:
        choices:
        - SR
        - ZH
        - TH
        - KO
        - RO
        - SL
        - HR
        - MS
        - UK
        - ET
        - AR
        - HE
        - CS
        - DE
        - EN
        - FR
        - EL
        - HU
        - IT
        - JA
        - DA
        - PL
        - ZF
        - NL
        - 'NO'
        - PT
        - SK
        - RU
        - ES
        - TR
        - FI
        - SV
        - BG
        - LT
        - LV
        - Z1
        - AF
        - IS
        - CA
        - SH
        - ID
        - HI
        - KK
        - VI
        default: EN
        description: SAP ABAP connection user language
        required: false
        type: str
      mshost:
        description: SAP ABAP application message server hostname
        required: false
        type: str
      msserv:
        description:
        - SAP ABAP message server service
        - msserv is needed only, if the service of the message server is not defined as
          sapms<SYSID> in /etc/services.
        required: false
        type: str
      passwd:
        description:
        - SAP ABAP connection user password
        - This is a no_log parameter - values will not be logged in ansible output
        required: false
        type: str
      return_import_params:
        default: false
        description:
        - Importing parameters of RFC call are returned by the RFC call
        - Usually, you do not need the IMPORT parameters in the result of Connection.call().
        - If I(return_import_params) is set to C(False), parameters of type IMPORT are
          filtered out.
        - 'Setting I(return_import_params) to C(True) is only recommended for debugging
          purposes.

          This will change return values of all NW RFC modules.

          '
        - There is no equivalent parameter when connecting via HTTP(s), see I(http_connection).
        type: bool
      rstrip:
        default: true
        description:
        - 'ABAP allows two different ways to store strings

          A fixed length string type C and a dynamic length string type STRING.

          '
        - Strings of type C are padded with blanks, if the content is shorter than the
          predefined length.
        - In order to unify the connectors behavior regarding strings, the rstrip option
          was introduced.
        - If set to True, all strings are right-stripped before being returned by an RFC
          call.
        - See <http://sap.github.io/PyRFC/client.html>
        - There is no equivalent parameter when connecting via HTTP(s), see I(http_connection).
        type: bool
      sysid:
        description: SAP ABAP system id (SID)
        required: false
        type: str
      sysnr:
        description: SAP ABAP application system number
        required: false
        type: str
      trace:
        choices:
        - '0'
        - '1'
        - '2'
        - '3'
        default: '0'
        description:
        - Trace level for NW RFC SDK (0-3)
        required: false
        type: str
      user:
        description: SAP ABAP connection user
        required: false
        type: str
    type: dict

http_connection:
    aliases:
    - abap_system_http
    description:
    - Dictionary with HTTP(s) connection parameters and configuration to connect to SAP
      ABAP system
    required: false
    suboptions:
      client:
        default: '000'
        description: SAP ABAP connection client (mandant)
        required: false
        type: str
      hostname:
        description:
        - SAP ABAP system hostname (to connect via http/https)
        required: true
        type: str
      language:
        choices:
        - SR
        - ZH
        - TH
        - KO
        - RO
        - SL
        - HR
        - MS
        - UK
        - ET
        - AR
        - HE
        - CS
        - DE
        - EN
        - FR
        - EL
        - HU
        - IT
        - JA
        - DA
        - PL
        - ZF
        - NL
        - 'NO'
        - PT
        - SK
        - RU
        - ES
        - TR
        - FI
        - SV
        - BG
        - LT
        - LV
        - Z1
        - AF
        - IS
        - CA
        - SH
        - ID
        - HI
        - KK
        - VI
        default: EN
        description: SAP ABAP connection user language
        required: false
        type: str
      password:
        description:
        - SAP ABAP connection user password
        - This is a no_log parameter - values will not be logged in ansible output
        required: false
        type: str
      port:
        default: 443
        description: SAP ABAP http(https) connection port
        required: false
        type: int
      security:
        default: true
        description:
        - Flag to select connection protocol
        - C(True) - https protocol
        - C(False) - http protocol
        required: false
        type: bool
      username:
        description: SAP ABAP connection user
        required: false
        type: str
    type: dict

Outputs

abap_system_info:
  contains:
    computer_info:
      contains:
        IP_ADDRESS:
          description: IP address
          sample: 10.0.0.234
          type: str
        IP_ADDRESSES:
          contains:
            VALUE:
              description: IP address
              type: str
          description: List of IP addresses
          elements: dict
          sample:
          - VALUE: 127.0.0.1
          - VALUE: 10.0.0.234
          type: list
        LOCALHOST:
          description: Local hostname
          sample: vhcalnplci
          type: str
        LOCALHOSTFULL:
          description: Local FQDN
          sample: vhcalnplci.dummy.nodomain
          type: str
        OPSYS:
          description: operating system
          sample: Linux
          type: str
        OPSYS_BITS:
          description: Operating system bits
          sample: ''
          type: str
        OPSYS_RELEASE:
          description: Operating system release
          sample: 4.12.14-197.102-default
          type: str
        PHYS_RAM:
          description: Physical RAM in MB
          sample: '32161'
          type: str
      description: Computer info
      type: dict
    host_data:
      contains:
        HOSTNAME:
          description: Hostname
          sample: vhcalnplci.dummy.nodomain
          type: str
        PORT:
          description: Port configured for web services
          sample: '8000'
          type: str
      description: Host data
      type: dict
    installed_components:
      contains:
        TT_COMPTAB:
          contains:
            COMPONENT:
              description: Component code
              sample: SAP_ABA
              type: str
            COMP_TYPE:
              description: Component type
              sample: S
              type: str
            DESC_TEXT:
              description: Component description
              sample: Cross-Application Component
              type: str
            EXTRELEASE:
              description: Component release SP level
              sample: '0002'
              type: str
            LANGU:
              description: Language
              sample: E
              type: str
            RELEASE:
              description: Component release
              sample: '751'
              type: str
          description: Installed components
          elements: dict
          sample:
          - COMPONENT: SAP_BASIS
            COMP_TYPE: S
            DESC_TEXT: SAP Basis Component
            EXTRELEASE: '0002'
            LANGU: E
            RELEASE: '751'
          - COMPONENT: SAP_BW
            COMP_TYPE: W
            DESC_TEXT: SAP Business Warehouse
            EXTRELEASE: '0002'
            LANGU: E
            RELEASE: '751'
          - COMPONENT: SAP_GWFND
            COMP_TYPE: S
            DESC_TEXT: SAP Gateway Foundation
            EXTRELEASE: '0000000002'
            LANGU: E
            RELEASE: '751'
          type: list
      description: Installed components
      type: dict
    installed_components_ocs:
      contains:
        ET_COMPLAYER:
          contains:
            COMP_TYPE:
              description: Component type
              sample:
              - V
              - R
              - P
              - X
              - W
              type: str
            LAYER_DESC:
              description: Layer description
              sample: Application Platform Components
              type: str
            LAYER_LVL:
              description: Layer level
              sample: '04'
              type: str
            MODEL_ID:
              description: Model ID
              sample: '0000000751'
              type: str
          description: Component layers
          elements: dict
          sample:
          - COMP_TYPE: S
            LAYER_DESC: NetWeaver Basis Components
            LAYER_LVL: '01'
            MODEL_ID: '0000000751'
          - COMP_TYPE: X
            LAYER_DESC: NetWeaver PlugIns
            LAYER_LVL: '02'
            MODEL_ID: '0000000751'
          - COMP_TYPE: W
            LAYER_DESC: NetWeaver Add-Ons
            LAYER_LVL: '03'
            MODEL_ID: '0000000751'
          type: list
        ET_COMPONENTS:
          contains:
            ACTIVE:
              description: Active flag
              sample: X
              type: str
            COMPONENT:
              description: Component code
              sample: SAP_GWFND
              type: str
            COMP_TYPE:
              description: Component type
              sample: S
              type: str
            DESC_TEXT:
              description: Component text description
              sample: SAP Gateway Foundation
              type: str
            INCMPL_STP:
              description: Service pack text description
              sample: ''
              type: str
            INCMPL_STPLVL:
              description: Service pack level
              sample: '0000'
              type: str
            MAINT_TYPE:
              description: Maintenance type
              sample: P
              type: str
            MASTERCOMP:
              description: Master component
              sample: ''
              type: str
            MASTERREL:
              description: Master release
              sample: ''
              type: str
            PATCHABLE:
              description: Patchable
              sample: X
              type: str
            RELEASE:
              description: Release
              sample: '751'
              type: str
            SFW_STATUS:
              description: Software status
              sample: N
              type: str
            SP:
              description: Service pack
              sample: SAPK-75102INSAPGWFND
              type: str
            SPP:
              description: Software patch
              sample: ''
              type: str
            SPP_LEVEL:
              description: Software patch
              sample: '0000'
              type: str
            SP_LEVEL:
              description: Software level
              sample: '0002'
              type: str
            SUBCOMP_STATUS:
              description: Subcomponent status
              sample: ''
              type: str
          description: Installed components
          elements: dict
          sample:
          - ACTIVE: X
            COMPONENT: SAP_BASIS
            COMP_TYPE: S
            DESC_TEXT: SAP Basis Component
            INCMPL_STP: ''
            INCMPL_STPLVL: '0000'
            MAINT_TYPE: S
            MASTERCOMP: ''
            MASTERREL: ''
            PATCHABLE: X
            RELEASE: '751'
            SFW_STATUS: N
            SP: SAPK-75102INSAPBASIS
            SPP: ''
            SPP_LEVEL: '0000'
            SP_LEVEL: '0002'
            SUBCOMP_STATUS: ''
          - ACTIVE: X
            COMPONENT: SAP_ABA
            COMP_TYPE: S
            DESC_TEXT: Cross-Application Component
            INCMPL_STP: ''
            INCMPL_STPLVL: '0000'
            MAINT_TYPE: S
            MASTERCOMP: ''
            MASTERREL: ''
            PATCHABLE: X
            RELEASE: '751'
            SFW_STATUS: N
            SP: SAPK-75102INSAPABA
            SPP: ''
            SPP_LEVEL: '0000'
            SP_LEVEL: '0002'
            SUBCOMP_STATUS: ''
          type: list
        ET_CPK:
          description: Components table
          elements: dict
          sample: []
          type: list
        ET_CVERS_SUB:
          description: Versions table
          elements: dict
          sample: []
          type: list
        TT_COMPTAB:
          contains:
            COMPONENT:
              description: Component
              sample: SAP_UI
              type: str
            COMP_TYPE:
              description: Component type
              sample: S
              type: str
            DESC_TEXT:
              description: Description text
              sample: User Interface Technology
              type: str
            EXTRELEASE:
              description: External release
              sample: '0002'
              type: str
            LANGU:
              description: Language
              sample: E
              type: str
            RELEASE:
              description: Release
              sample: '751'
              type: str
          description: List of components
          elements: dict
          sample:
          - COMPONENT: SAP_BASIS
            COMP_TYPE: S
            DESC_TEXT: SAP Basis Component
            EXTRELEASE: '0002'
            LANGU: E
            RELEASE: '751'
          - COMPONENT: SAP_ABA
            COMP_TYPE: S
            DESC_TEXT: Cross-Application Component
            EXTRELEASE: '0002'
            LANGU: E
            RELEASE: '751'
          - COMPONENT: SAP_GWFND
            COMP_TYPE: S
            DESC_TEXT: SAP Gateway Foundation
            EXTRELEASE: '0002'
            LANGU: E
            RELEASE: '751'
          type: list
      description: Installed components
      type: dict
    smlg_groups:
      description: SMLG groups
      sample:
        GROUPS:
        - GROUPNAME: PUBLIC
      type: dict
    smlg_servers:
      description: SMLG servers
      sample:
        INSTANCES:
        - APPLSERVER: vhcalnplci_NPL_00
      type: dict
    smlg_setup:
      description: SMLG setup
      sample:
        ERFC_SETUP: []
        SETUP:
        - APPLSERVER: vhcalnplci_NPL_00
          CLASSNAME: PUBLIC
          GROUPTYPE: ''
          IPV6: ''
          IPV6_ADDRESS: ''
          IPV6_ADDRESS_OLD: ''
          IP_ADDRESS: ''
          IP_ADDRESS_OLD: ''
          OP_MODE: ''
          RESP_TIME: '000000'
          USERS: '0000'
          WP_QUOTA: 0
      type: dict
    software_components:
      description: Software components
      sample:
        ET_ACTIVE_BFUNCS: []
        ET_BSET_COMP_MAPPING: []
        ET_SFW_COMPS: []
      type: dict
    swproducts:
      description: Software products
      sample:
        ET_INCL_SWFEATURES:
        - DESCRIPT: Application Server ABAP
          ID: '1'
          MASTER_ID: '2'
          MASTER_PRD: '73555000100900000781'
          NAME: NW AS ABAP INNOVATION PACKAGE
          PROD_ID: '73555000100900000781'
          VENDOR: sap.com
          VERSION: '7.51'
        ET_SWFEATURES:
        - DESCRIPT: Application Server ABAP
          ID: '1'
          NAME: NW AS ABAP INNOVATION PACKAGE
          PROD_ID: '73555000100900000781'
          VENDOR: sap.com
          VERSION: '7.51'
        - DESCRIPT: Basis Apps
          ID: '2'
          NAME: NW AS ABAP INNOVATION PACKAGE
          PROD_ID: '73555000100900000781'
          VENDOR: sap.com
          VERSION: '7.51'
        ET_SWPRODUCTS:
        - DESCRIPT: NW AS ABAP 7.51 INNOVATION PKG
          ID: '73555000100900000781'
          NAME: NW AS ABAP INNOVATION PACKAGE
          VENDOR: sap.com
          VERSION: '7.51'
        ET_SWPROD_SPSTACK:
        - ID: '73555000103300002362'
          PROD_DESCR: NW AS ABAP 7.51 INNOVATION PKG
          PROD_ID: '73555000100900000781'
          PROD_NAME: NW AS ABAP INNOVATION PACKAGE
          PROD_VERSION: '7.51'
          STACK_CAPTION: 02 (05/2017)
          VENDOR: sap.com
        ET_TECH_USAGES: []
      type: dict
  description: ABAP system info
  returned: success
  type: dict