netapp.storagegrid.na_sg_grid_snmp module – Configure SNMP agent on StorageGRID.
Note
This module is part of the netapp.storagegrid collection (version 21.15.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 netapp.storagegrid.
To use it in a playbook, specify: netapp.storagegrid.na_sg_grid_snmp.
New in netapp.storagegrid 21.15.0
Synopsis
Configure SNMP monitoring on NetApp StorageGRID.
Parameters
Parameter  | 
Comments  | 
|---|---|
Local binding addresses for the SNMP agent.  | 
|
SNMP agent local network interface address. Choices: 
  | 
|
SNMP agent local address port. Default:   | 
|
SNMP agent address protocol. Choices: 
  | 
|
The url to the StorageGRID Admin Node REST API.  | 
|
The authorization token for the API request  | 
|
1 - enable SNMP authentication traps. 2 - disable SNMP authentication traps. Choices: 
  | 
|
List of community strings.  | 
|
Disable all SNMP notifications. Choices: 
  | 
|
Enable or disable SNMP monitoring. Choices: 
  | 
|
USM users allowed read-only access.  | 
|
The snmp agent should be present. Choices: 
  | 
|
SNMP system contact.  | 
|
SNMP system location.  | 
|
SNMP trap community.  | 
|
SNMP trap destinations for V1, V2C, and Inform notifications.  | 
|
SNMP trap destination community (cannot be used with   | 
|
SNMP trap destination host.  | 
|
SNMP trap destination port.  | 
|
SNMP trap destination protocol. Choices: 
  | 
|
SNMP trap destination type. Choices: 
  | 
|
USM user to send notification under (cannot be used with   | 
|
USM user.  | 
|
USM user authentication passphrase.  | 
|
USM user authentication protocol. Choices: 
  | 
|
The engine ID to use for localized key hashing. From 5 to 32 bytes in hex. Only for use on users specified in informsess trap destinations.  | 
|
USM user name.  | 
|
USM user privacy passphrase.  | 
|
USM user privacy protocol. Choices: 
  | 
|
USM user security level. Choices: 
  | 
|
Should https certificates be validated? Choices: 
  | 
Notes
Note
The modules prefixed with
na_sgare built to manage NetApp StorageGRID.
Examples
- name: Configure SNMP monitoring
  na_sg_grid_snmp:
    api_url: "https://<storagegrid-endpoint-url>"
    auth_token: "storagegrid-auth-token"
    enable_snmp: true
    community_strings:
      - public
    sys_location: RTP-L1-R23S10
    sys_contact: [email protected]
    trap_community: public
    auth_trap_enable: 2
    disable_notifications: false
    trap_destinations:
      - type: trapsink
        host: 172.12.10.100
        port: 162
        community: public
        protocol: udp
    agent_addresses:
      - protocol: udp
        network: admin
        port: 161
- name: Configure usm user
  na_sg_grid_snmp:
    api_url: "https://<storagegrid-endpoint-url>"
    auth_token: "storagegrid-auth-token"
    enable_snmp: true
    usm_users:
      - name: user1
        security_level: authNoPriv
        auth_protocol: SHA
        auth_passphrase: password
        priv_protocol: AES
        priv_passphrase: privpass
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key  | 
Description  | 
|---|---|
Returns information about the StorageGRID SNMP agent. Returned: If state is ‘present’. Sample:   |