dellemc.openmanage.ome_diagnostics module – Export technical support logs(TSR) to network share location

Note

This module is part of the dellemc.openmanage collection (version 4.4.0).

You might already have this collection installed if you are using the ansible package. 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 dellemc.openmanage.

To use it in a playbook, specify: dellemc.openmanage.ome_diagnostics.

New in version 3.6.0: of dellemc.openmanage

Synopsis

  • This module allows to export SupportAssist collection logs from OpenManage Enterprise and OpenManage Enterprise Modular and application logs from OpenManage Enterprise Modular to a CIFS or NFS share.

Requirements

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

  • python >= 2.7.17

Parameters

Parameter

Comments

device_group_name

string

Name of the device group to export support_assist_collection logs of all devices within the group.

This is applicable for support_assist_collection logs.

This option is not applicable for OpenManage Enterprise Modular.

This option is mutually exclusive with device_ids and device_service_tags.

device_ids

list / elements=integer

List of target device IDs.

This is applicable for support_assist_collection logs.

This option is mutually exclusive with device_service_tags and device_group_name.

device_service_tags

list / elements=string

List of target identifier.

This is applicable for support_assist_collection logs.

This option is mutually exclusive with device_ids and device_group_name.

hostname

string / required

OpenManage Enterprise or OpenManage Enterprise Modular IP address or hostname.

job_wait

boolean

Whether to wait for the Job completion or not.

The maximum wait time is job_wait_timeout.

Choices:

  • no

  • yes ← (default)

job_wait_timeout

integer

The maximum wait time of job_wait in minutes.

This option is applicable job_wait is true.

Default: 60

log_selectors

list / elements=string

By default, the SupportAssist logs contains only hardware logs. To collect additional logs such as OS logs or RAID logs, specify these option in the choices list.

If not provided the default hardware log will be exported.

OS_LOGS to collect OS Logs.

RAID_LOGS to collect RAID controller logs.

This option is applicable only for support_assist_collection of log_type.

Choices:

  • OS_LOGS

  • RAID_LOGS

log_type

string

application is applicable for OpenManage Enterprise Modular to export the application log bundle.

support_assist_collection is applicable for one or more devices to export SupportAssist logs.

support_assist_collection supports both OpenManage Enterprise and OpenManage Enterprise Modular.

support_assist_collection does not support export of OS_LOGS from OpenManage Enterprise. If tried to export, the tasks will complete with errors, and the module fails.

Choices:

  • application

  • support_assist_collection ← (default)

mask_sensitive_info

boolean

Select this option to mask the personal identification information such as IPAddress, DNS, alert destination, email, gateway, inet6, MacAddress, netmask etc.

This option is applicable for application of log_type.

Choices:

  • no ← (default)

  • yes

password

string / required

OpenManage Enterprise or OpenManage Enterprise Modular password.

port

integer

OpenManage Enterprise or OpenManage Enterprise Modular HTTPS port.

Default: 443

share_address

string / required

Network share IP address.

share_domain

string

Network share domain name.

This option is applicable for CIFS if share_type.

share_name

string / required

Network share path.

Filename is auto generated and should not be provided as part of share_name.

share_password

string

Network share password

This option is applicable for CIFS of share_type.

share_type

string / required

Network share type

Choices:

  • NFS

  • CIFS

share_user

string

Network share username.

This option is applicable for CIFS of share_type.

test_connection

boolean

Test the availability of the network share location.

job_wait and job_wait_timeout options are not applicable for test_connection.

Choices:

  • no ← (default)

  • yes

username

string / required

OpenManage Enterprise or OpenManage Enterprise Modular username.

Examples

---
- name: Export application log using CIFS share location
  dellemc.openmanage.ome_diagnostics:
    hostname: "192.168.0.1"
    username: "username"
    password: "password"
    share_type: CIFS
    share_address: "192.168.0.2"
    share_user: share_username
    share_password: share_password
    share_name: cifs_share
    log_type: application
    mask_sensitive_info: false
    test_connection: true

- name: Export application log using NFS share location
  dellemc.openmanage.ome_diagnostics:
    hostname: "192.168.0.1"
    username: "username"
    password: "password"
    share_address: "192.168.0.3"
    share_type: NFS
    share_name: nfs_share
    log_type: application
    mask_sensitive_info: true
    test_connection: true

- name: Export SupportAssist log using CIFS share location
  dellemc.openmanage.ome_diagnostics:
    hostname: "192.168.0.1"
    username: "username"
    password: "password"
    share_address: "192.168.0.3"
    share_user: share_username
    share_password: share_password
    share_name: cifs_share
    share_type: CIFS
    log_type: support_assist_collection
    device_ids: [10011, 10022]
    log_selectors: [OS_LOGS]
    test_connection: true

- name: Export SupportAssist log using NFS share location
  dellemc.openmanage.ome_diagnostics:
    hostname: "192.168.0.1"
    username: "username"
    password: "password"
    share_address: "192.168.0.3"
    share_type: NFS
    share_name: nfs_share
    log_type: support_assist_collection
    device_group_name: group_name
    test_connection: true

Return Values

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

Key

Description

error_info

dictionary

Details of the HTTP Error.

Returned: on HTTP error

Sample: {“error”: {“@Message.ExtendedInfo”: [{“Message”: “Unable to process the request because an error occurred.”, “MessageArgs”: [], “MessageId”: “GEN1234”, “RelatedProperties”: [], “Resolution”: “Retry the operation. If the issue persists, contact your system administrator.”, “Severity”: “Critical”}], “code”: “Base.1.0.GeneralError”, “message”: “A general error has occurred. See ExtendedInfo for more information.”}}

jog_status

dictionary

Details of the export log operation status.

Returned: success

Sample: {“Builtin”: false, “CreatedBy”: “root”, “Editable”: true, “EndTime”: “None”, “Id”: 12778, “JobDescription”: “Export device log”, “JobName”: “Export Log”, “JobStatus”: {“Id”: 2080, “Name”: “New”}, “JobType”: {“Id”: 18, “Internal”: false, “Name”: “DebugLogs_Task”}, “LastRun”: “2021-07-06 10:52:50.519”, “LastRunStatus”: {“Id”: 2060, “Name”: “Completed”}, “NextRun”: “None”, “Params”: [{“JobId”: 12778, “Key”: “maskSensitiveInfo”, “Value”: “FALSE”}, {“JobId”: 12778, “Key”: “password”, “Value”: “tY86w7q92u0QzvykuF0gQQ”}, {“JobId”: 12778, “Key”: “userName”, “Value”: “administrator”}, {“JobId”: 12778, “Key”: “shareName”, “Value”: “iso”}, {“JobId”: 12778, “Key”: “OPERATION_NAME”, “Value”: “EXTRACT_LOGS”}, {“JobId”: 12778, “Key”: “shareType”, “Value”: “CIFS”}, {“JobId”: 12778, “Key”: “shareAddress”, “Value”: “100.96.32.142”}], “Schedule”: “startnow”, “StartTime”: “None”, “State”: “Enabled”, “Targets”: [{“Data”: “”, “Id”: 10053, “JobId”: 12778, “TargetType”: {“Id”: 1000, “Name”: “DEVICE”}}], “UpdatedBy”: “None”, “UserGenerated”: true, “Visible”: true}

msg

string

Overall status of the export log.

Returned: always

Sample: “Export log job completed successfully.”

Authors

  • Felix Stephen (@felixs88)