#API not Found . Na_Ontap_rest_cli

2 messages · Page 1 of 1 (latest)

sweet trail
#

health_checks:

  - name: "Cluster Health / Eligibility"
    command: "cluster show -health !true -eligibility !true"

  - name: "Storage Failover Possible"
    command: "storage failover show -possible !true"

  - name: "Cluster Ring Status"
    command: "cluster ring show -online offline"

  - name: "Cluster Health False"
    command: "cluster show -health false"  

What is the api equivalent of these commands, I am getting api not found when I run my playbook

rough dagger
#

hi @sweet trail
Please try out the below Ansible tasks for your use cases:

    - name: Cluster Health / Eligibility
      tags: cluster_health
      netapp.ontap.na_ontap_rest_cli:
        command: 'cluster'
        verb: 'GET'
        params:
          health: false
          eligibility: false
      register: result
    - name: Cluster Ring Status
      tags: cluster_ring
      netapp.ontap.na_ontap_rest_cli:
        command: 'cluster/ring'
        verb: 'GET'
        params:
          online: 'offline'
      register: result
    - name: Storage Failover Possible
      tags: storage_failover
      netapp.ontap.na_ontap_rest_cli:
        command: 'storage/failover'
        verb: 'GET'
        params:
          possible: false
      register: result