#rest_cli cannot get the output of "security key-manager onboard show-backup".

1 messages · Page 1 of 1 (latest)

oblique bramble
#

rest_cli cannot get the output of "security key-manager onboard show-backup". Below is my snippet of ansible play:


    - name: Get the OKM backup key
      connection: local
      na_ontap_rest_cli:
        <<: *login
        # use_rest: always
        verb: "GET"
        command: "security/key-manager/onboard/show-backup"
      register: backup_info
      tags:
        - backup

but output is empty, why?

TASK [Get the OKM backup key] ***************************************************************************
ok: [scc44.sc.intel.com]                                 
TASK [print] ********************************************************************************************
ok: [scc44.sc.intel.com] => {
    "backup_info": {                                "changed": false,                           "failed": false,
        "msg": {
            "num_records": 0,
            "records": []                            }                                      }                                        }        
lavish umbra
#

I use this set of tasks as part of a configuration role - it enables and sets the onboard key manager passphrase then backs up the key to a file on the Ansible controller

buoyant grail
#

Try command: security/key-manager/onboard/backup

oblique bramble
#

Thanks for the help. the rest_info works. rest_cli still yields no output. tried @buoyant grail 's suggestion, or with command: security/key-manager/onboard, not working. at least rest_info is working.

tender inlet
#

Is there something the rest_info isn't give that you need to use rest_cli for?