Active IQ Unified Manager Discussions

OCI 7.3.2 Performance Data export from the OCI Server HTML screen

jim515new
4,196 Views

Going to the HTML page and looking at a device I can see performance. Example, a chart for the Latency - Total. My question is how do I get the data, the actual numbers, not the graph itself, from the OCI Server? Would that require using the API?

 

-Jim K.

1 ACCEPTED SOLUTION

hotz
4,181 Views

Hi Jim,

 

Yes, correct. If you want the data represented in the chart, it can be retrieved via REST.

 

So for instance you could do something like this:

(In this example we have a storage device with ID 10 - but you can essentially do the same for any kind of device)

 

curl -k -u admin:admin123 https://<yourf_oci_server>/rest/v1/assets/storages

[
  {
    "id": "10",
    "self": "/rest/v1/assets/storages/10",
    "name": "somestoragename",
    "simpleName": "somesoragename",
    "naturalKey": "XXXXXXXX-XXXX-XXXX-XXXX-xxxxxxxxxxxx",
    "ip": "xx.xxx.xxx.xx",
    "serialNumber": "1-20-123456",
    "model": "FAS8060,FAS8080",
    "vendor": "NetApp",
    "microcodeVersion": "8.3.2P12 clustered Data ONTAP",
    "capacity": {
      "description": "Storage Capacity",
      "unitType": "MB",
      "total": {
        "value": 2.36018334E8
      },
      "storagePools": {
        "value": 1.06979438E8
      }
    },
    "isActive": true,
    "createTime": "2018-02-14T06:01:35-0500",
    "family": "FAS8000",
    "managementUrl": "HTTPS://xx.xxx.xxx.xx:443",
    "virtualizedType": "STANDARD"
  }
]%
     

curl -k -u admin:admin123 https://<your_oci_server>/rest/v1/assets/storages/10/performance\?expand\=history\&fromTime\=1519812000000\&toTime\=1521110400000

{
  "self": "/rest/v1/assets/storages/10/performance",
  "cacheHitRatio": {

    "read": {

    ...

    }
  },
  "history":
  [
    [
      1519859627938,
      {
        "latency.total": 1.73614,
        "latency.read": 0.51429,
        "ioDensity.read": 29.34272,
        "iops.write": 19447.0,
        "ioDensity.total": 251.55801,
        "throughput.read": 25.46743,
        "iops.total": 22753.0,
        "latency.write": 1.93929,
        "ioDensity.write": 215.00675,
        "iops.read": 2654.0,
        "throughput.write": 246.78407,
        "throughput.total": 272.2515
      }
    ],

    [
      1519860527941,
      {
        "latency.total": 1.68437,
        "latency.read": 0.35201,
        "ioDensity.read": 23.08501,
        "iops.write": 19808.0,
        "ioDensity.total": 248.90456,
        "capacity.raw": 230486.65504,
        "throughput.read": 9.79853,
        "iops.total": 22513.0,
        "latency.write": 1.86614,
        "ioDensity.write": 218.99798,
        "iops.read": 2088.0,
        "capacity.storagePools": 104472.11156,
        "throughput.write": 252.33931,
        "throughput.total": 262.13784
      }
    ],
    [
      1519861427932,
      {
        "latency.total": 1.67071,
        "latency.read": 0.40179,
        "ioDensity.read": 23.07395,
        "iops.write": 22152.0,
        "ioDensity.total": 274.27816,
        "throughput.read": 10.0467,
        "iops.total": 24808.0,
        "latency.write": 1.83083,
        "ioDensity.write": 244.91333,
        "iops.read": 2087.0,
        "throughput.write": 241.68757,
        "throughput.total": 251.73427
      }
    ],
    [
      1519862327938,
      {
        "latency.total": 1.4125,
        "latency.read": 0.36906,
        "ioDensity.read": 23.29507,
        "iops.write": 20727.0,
        "ioDensity.total": 259.58469,
        "throughput.read": 10.27041,
        "iops.total": 23479.0,
        "latency.write": 1.55946,
        "ioDensity.write": 229.15848,
        "iops.read": 2107.0,
        "throughput.write": 234.97686,
        "throughput.total": 245.24728
      }
    ],

...

    [
      1521109516968,
      {
        "latency.total": 2.80538,
        "latency.read": 0.99893,
        "ioDensity.read": 60.99616,
        "iops.write": 44558.0,
        "ioDensity.total": 560.14305,
        "throughput.read": 74.43913,
        "iops.total": 50664.0,
        "latency.write": 3.06381,
        "ioDensity.write": 492.63489,
        "iops.read": 5517.0,
        "throughput.write": 289.01248,
        "throughput.total": 363.45161
      }
    ]
  ]
}%

 

So this is essentially a list of all the data points in the sepecified timeframe with all the couters available.

 

Note that the fromTime and toTime parameters are in epoch notation.

On linux cmd prompt you can convert back and forth with something like:

echo $(date +%s -d 2018-02-28T11:00)000
1519812000000

 

date -d @$(echo 1519812000000/1000 | bc)
Wed Feb 28 11:00:00 CET 2018

 

The linux date utility's epoch notation is in seconds since 1970-01-01 00:00:00 UTC, but java and by extension OCI counts in millisecons. Hence the 1000th mutiplicator.

 

Hope this helps.

Gerhard

View solution in original post

1 REPLY 1

hotz
4,182 Views

Hi Jim,

 

Yes, correct. If you want the data represented in the chart, it can be retrieved via REST.

 

So for instance you could do something like this:

(In this example we have a storage device with ID 10 - but you can essentially do the same for any kind of device)

 

curl -k -u admin:admin123 https://<yourf_oci_server>/rest/v1/assets/storages

[
  {
    "id": "10",
    "self": "/rest/v1/assets/storages/10",
    "name": "somestoragename",
    "simpleName": "somesoragename",
    "naturalKey": "XXXXXXXX-XXXX-XXXX-XXXX-xxxxxxxxxxxx",
    "ip": "xx.xxx.xxx.xx",
    "serialNumber": "1-20-123456",
    "model": "FAS8060,FAS8080",
    "vendor": "NetApp",
    "microcodeVersion": "8.3.2P12 clustered Data ONTAP",
    "capacity": {
      "description": "Storage Capacity",
      "unitType": "MB",
      "total": {
        "value": 2.36018334E8
      },
      "storagePools": {
        "value": 1.06979438E8
      }
    },
    "isActive": true,
    "createTime": "2018-02-14T06:01:35-0500",
    "family": "FAS8000",
    "managementUrl": "HTTPS://xx.xxx.xxx.xx:443",
    "virtualizedType": "STANDARD"
  }
]%
     

curl -k -u admin:admin123 https://<your_oci_server>/rest/v1/assets/storages/10/performance\?expand\=history\&fromTime\=1519812000000\&toTime\=1521110400000

{
  "self": "/rest/v1/assets/storages/10/performance",
  "cacheHitRatio": {

    "read": {

    ...

    }
  },
  "history":
  [
    [
      1519859627938,
      {
        "latency.total": 1.73614,
        "latency.read": 0.51429,
        "ioDensity.read": 29.34272,
        "iops.write": 19447.0,
        "ioDensity.total": 251.55801,
        "throughput.read": 25.46743,
        "iops.total": 22753.0,
        "latency.write": 1.93929,
        "ioDensity.write": 215.00675,
        "iops.read": 2654.0,
        "throughput.write": 246.78407,
        "throughput.total": 272.2515
      }
    ],

    [
      1519860527941,
      {
        "latency.total": 1.68437,
        "latency.read": 0.35201,
        "ioDensity.read": 23.08501,
        "iops.write": 19808.0,
        "ioDensity.total": 248.90456,
        "capacity.raw": 230486.65504,
        "throughput.read": 9.79853,
        "iops.total": 22513.0,
        "latency.write": 1.86614,
        "ioDensity.write": 218.99798,
        "iops.read": 2088.0,
        "capacity.storagePools": 104472.11156,
        "throughput.write": 252.33931,
        "throughput.total": 262.13784
      }
    ],
    [
      1519861427932,
      {
        "latency.total": 1.67071,
        "latency.read": 0.40179,
        "ioDensity.read": 23.07395,
        "iops.write": 22152.0,
        "ioDensity.total": 274.27816,
        "throughput.read": 10.0467,
        "iops.total": 24808.0,
        "latency.write": 1.83083,
        "ioDensity.write": 244.91333,
        "iops.read": 2087.0,
        "throughput.write": 241.68757,
        "throughput.total": 251.73427
      }
    ],
    [
      1519862327938,
      {
        "latency.total": 1.4125,
        "latency.read": 0.36906,
        "ioDensity.read": 23.29507,
        "iops.write": 20727.0,
        "ioDensity.total": 259.58469,
        "throughput.read": 10.27041,
        "iops.total": 23479.0,
        "latency.write": 1.55946,
        "ioDensity.write": 229.15848,
        "iops.read": 2107.0,
        "throughput.write": 234.97686,
        "throughput.total": 245.24728
      }
    ],

...

    [
      1521109516968,
      {
        "latency.total": 2.80538,
        "latency.read": 0.99893,
        "ioDensity.read": 60.99616,
        "iops.write": 44558.0,
        "ioDensity.total": 560.14305,
        "throughput.read": 74.43913,
        "iops.total": 50664.0,
        "latency.write": 3.06381,
        "ioDensity.write": 492.63489,
        "iops.read": 5517.0,
        "throughput.write": 289.01248,
        "throughput.total": 363.45161
      }
    ]
  ]
}%

 

So this is essentially a list of all the data points in the sepecified timeframe with all the couters available.

 

Note that the fromTime and toTime parameters are in epoch notation.

On linux cmd prompt you can convert back and forth with something like:

echo $(date +%s -d 2018-02-28T11:00)000
1519812000000

 

date -d @$(echo 1519812000000/1000 | bc)
Wed Feb 28 11:00:00 CET 2018

 

The linux date utility's epoch notation is in seconds since 1970-01-01 00:00:00 UTC, but java and by extension OCI counts in millisecons. Hence the 1000th mutiplicator.

 

Hope this helps.

Gerhard

Public