#api call for node serial numbers

1 messages · Page 1 of 1 (latest)

willow solstice
#

anyone have a restapi call that includes serial number and os version of all nodes?

hearty peak
#

I don't think there's a single API call that provides both

#

/cluster/nodes gives you serial numbers and /cluster/software gives you the ONTAP version

willow solstice
hearty peak
#

ah, right, I don't think there's an API for that in the Grid, but I'd love to be proven wrong 🤷‍♂️

sullen heath
#

I think there are only private API calls for this. Open the StorageGrid GUI and use your Browsers Dev Tools (F12). In the Network Tab you will see all the API calls that are happening. I think the answer can be found there. But as the name "private" implies, this is no API NetApp wants you to use and may change between StorageGrid versions.

willow solstice
sullen heath
#

I checked for myself in SG 11.7 and I found the necessary calls. You won't get it for all nodes at once I think. But I didn't test it, just grabbed the calls from the console.

Get the Node IDs
/api/v3/private/attributes/NTYP

Query per Node:
serial number
/api/v3/private/attributes/SFSN/node/<id>

software version
/api/v3/private/attributes/PKVR/node/<id>

It may be possible to combine the attribute query like this:
/api/v3/private/attributes/SFSN,PKVR/node/<id>

willow solstice
willow solstice
sullen heath
#

Private API is not documented as far as I know.

steep merlin
#

There is some private api documented in swagger but these ones are missing. Im testing this using 11.6 and the api/v3/private/attributes/SFSN/node/<id>

Comes back with success but no data

sullen heath
#

I could only test with 11.7

willow solstice
#

very strange how if running to collect PKVR you get all 24 nodes in the 2 site config but running SFSN I only get 18 of the 24 nodes.

#

this is my grid version 11.6.0.8-20230217.1724.99ffc92