Skip to main content
ONTAP Automation
La versione in lingua italiana fornita proviene da una traduzione automatica. Per eventuali incoerenze, fare riferimento alla versione in lingua inglese.

Contatori delle performance

Collaboratori

Il contatore ONTAP conserva informazioni dettagliate sulle prestazioni di ciascun sistema ONTAP. Esporta questi dati come un insieme di contatori delle performance che puoi utilizzare per valutare le performance del tuo sistema ONTAP e contribuire a raggiungere i tuoi obiettivi di performance.

Accedere ai contatori delle prestazioni di ONTAP

È possibile accedere ai contatori delle prestazioni di ONTAP utilizzando due API diverse e tramite l'interfaccia della riga di comando di ONTAP.

Nota L'API REST di ONTAP è l'opzione preferita e strategica per l'automazione dell'amministrazione delle implementazioni ONTAP.

API ONTAPI

ONTAPI API è disponibile con NetApp Network Manageability SDK. Quando si utilizza ONTAPI, i contatori delle performance vengono definiti all'interno di un insieme di oggetti. Ogni oggetto corrisponde a un componente fisico o virtuale del sistema. In base alla configurazione di sistema, possono essere presenti una o più istanze di ciascun oggetto.

Ad esempio, se il sistema ONTAP dispone di quattro dischi fisici, saranno presenti quattro istanze di disk oggetto, ciascuno con il proprio set di contatori delle performance. È possibile utilizzare ONTAPI per accedere ai singoli contatori per ogni istanza di disco.

API REST di ONTAP

A partire da ONTAP 9.11.1, è anche possibile accedere ai dati delle performance attraverso l'API REST. In questo caso, i contatori delle performance sono organizzati in tabelle equivalenti agli oggetti ONTAPI. Ogni riga della tabella equivale a un'istanza di un oggetto ONTAPI.

Ad esempio, se il sistema ONTAP dispone di quattro dischi fisici, il disk la tabella conterrà quattro righe. È possibile accedere a ciascuna riga singolarmente e include un proprio set di contatori delle prestazioni disponibili come campi o colonne nella riga.

Prepararsi a utilizzare l'API REST

È necessario prepararsi prima di utilizzare l'API REST di ONTAP per accedere ai contatori delle prestazioni.

Contatori delle performance organizzati in tabelle

Un sottoinsieme degli oggetti ONTAPI è disponibile attraverso l'API REST di ONTAP e viene presentato come tabelle. Ad esempio, l'oggetto ONTAPI hostadapter viene presentato tramite l'API REST come tabella host_adpater. Ogni adattatore host del sistema è una riga con un proprio set di contatori delle prestazioni.

Nome dell'istanza Contatori delle performance

host_adapter_1

total_read_ops_1

total_write_ops_1

byte_read_1

bytes_written_1

max_link_data_rate_1

rscn_count_1

host_adapter_2

total_read_ops_2

total_write_ops_2

byte_read_2

bytes_written_2

max_link_data_rate_2

rscn_count_2

host_adapter_3

total_read_ops_3

total_write_ops_3

byte_read_3

bytes_written_3

max_link_data_rate_3

rscn_count_3

Riepilogo degli endpoint RIMANENTI

Sono disponibili quattro endpoint principali per accedere ai contatori delle performance di ONTAP e alle tabelle correlate.

Nota Ciascuno degli endpoint REST fornisce l'accesso in sola lettura e supporta solo il metodo HTTP GET. Vedere "Riferimento API" per ulteriori informazioni.
  • /cluster/contatore/tabelle

    Restituisce un insieme di tabelle di contatore e le relative definizioni di schema.

  • /cluster/counter/tables/{name}

    Restituisce informazioni su una singola tabella contatore denominata.

  • /cluster/counter/tables/{counter_name}/rows

    Restituisce un insieme di righe da una tabella contatore denominata.

  • /cluster/counter/tables/{counter_name}/rows/{id}

    Restituisce una riga specifica da una tabella contatore denominata.

Migrazione da ONTAPI all'API REST

NetApp offre un supporto completo per la migrazione del codice di automazione da ONTAPI all'API REST di ONTAP. Ciò include la mappatura della documentazione per l'identità della tabella dei contatori delle performance equivalenti disponibile nell'API REST per un dato oggetto ONTAPI.

Consultare la documentazione di mappatura appropriata in base alla release di ONTAP in uso:

Inizia a utilizzare l'API REST di ONTAP

I seguenti esempi illustrano come utilizzare l'API REST per accedere ai contatori delle prestazioni di ONTAP. Ciò include il recupero di un elenco delle tabelle disponibili e l'esplorazione della struttura della tabella.

Prima di iniziare

Prima di utilizzare gli esempi, leggere le seguenti informazioni.

Credenziali ONTAP

È necessario disporre di un account amministratore di ONTAP con la password.

IP di gestione del cluster

È necessario configurare l'indirizzo IP di gestione del cluster per il sistema ONTAP.

Tutte le chiamate API utilizzano il metodo GET

Tutti gli esempi riportati di seguito possono essere utilizzati solo per recuperare informazioni con il metodo HTTP GET.

Sostituzione variabile

Ogni esempio di curl include una o più variabili come indicato con lettere maiuscole e testo tra parentesi. Assicurarsi di sostituire queste variabili con valori effettivi appropriati per l'ambiente in uso.

Gli esempi corrispondono agli endpoint

La sequenza di esempi riportata di seguito illustra come utilizzare gli endpoint REST disponibili per recuperare i contatori delle prestazioni. Vedere Riepilogo degli endpoint RIMANENTI per ulteriori informazioni.

Esempio 1: Tutte le tabelle dei contatori delle performance

È possibile utilizzare questa chiamata API REST per scoprire tutte le tabelle di gestione dei contatori disponibili.

Esempio di arricciamento
curl --request GET --user admin:<PASSWORD> 'https://<ONTAP_IP_ADDRESS>/api/cluster/counter/tables'
Esempio di output JSON
{
  "records": [
    {
      "name": "copy_manager",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/copy_manager"
        }
      }
    },
    {
      "name": "copy_manager:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/copy_manager%3Aconstituent"
        }
      }
    },
    {
      "name": "disk",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/disk"
        }
      }
    },
    {
      "name": "disk:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/disk%3Aconstituent"
        }
      }
    },
    {
      "name": "disk:raid_group",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/disk%3Araid_group"
        }
      }
    },
    {
      "name": "external_cache",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/external_cache"
        }
      }
    },
    {
      "name": "fcp",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcp"
        }
      }
    },
    {
      "name": "fcp:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcp%3Anode"
        }
      }
    },
    {
      "name": "fcp_lif",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcp_lif"
        }
      }
    },
    {
      "name": "fcp_lif:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcp_lif%3Anode"
        }
      }
    },
    {
      "name": "fcp_lif:port",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcp_lif%3Aport"
        }
      }
    },
    {
      "name": "fcp_lif:svm",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcp_lif%3Asvm"
        }
      }
    },
    {
      "name": "fcvi",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/fcvi"
        }
      }
    },
    {
      "name": "headroom_aggregate",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/headroom_aggregate"
        }
      }
    },
    {
      "name": "headroom_cpu",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/headroom_cpu"
        }
      }
    },
    {
      "name": "host_adapter",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/host_adapter"
        }
      }
    },
    {
      "name": "iscsi_lif",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/iscsi_lif"
        }
      }
    },
    {
      "name": "iscsi_lif:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/iscsi_lif%3Anode"
        }
      }
    },
    {
      "name": "iscsi_lif:svm",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/iscsi_lif%3Asvm"
        }
      }
    },
    {
      "name": "lif",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/lif"
        }
      }
    },
    {
      "name": "lif:svm",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/lif%3Asvm"
        }
      }
    },
    {
      "name": "lun",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/lun"
        }
      }
    },
    {
      "name": "lun:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/lun%3Aconstituent"
        }
      }
    },
    {
      "name": "lun:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/lun%3Anode"
        }
      }
    },
    {
      "name": "namespace",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/namespace"
        }
      }
    },
    {
      "name": "namespace:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/namespace%3Aconstituent"
        }
      }
    },
    {
      "name": "nfs_v4_diag",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/nfs_v4_diag"
        }
      }
    },
    {
      "name": "nic_common",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/nic_common"
        }
      }
    },
    {
      "name": "nvmf_lif",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/nvmf_lif"
        }
      }
    },
    {
      "name": "nvmf_lif:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/nvmf_lif%3Aconstituent"
        }
      }
    },
    {
      "name": "nvmf_lif:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/nvmf_lif%3Anode"
        }
      }
    },
    {
      "name": "nvmf_lif:port",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/nvmf_lif%3Aport"
        }
      }
    },
    {
      "name": "object_store_client_op",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/object_store_client_op"
        }
      }
    },
    {
      "name": "path",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/path"
        }
      }
    },
    {
      "name": "processor",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/processor"
        }
      }
    },
    {
      "name": "processor:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/processor%3Anode"
        }
      }
    },
    {
      "name": "qos",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos"
        }
      }
    },
    {
      "name": "qos:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos%3Aconstituent"
        }
      }
    },
    {
      "name": "qos:policy_group",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos%3Apolicy_group"
        }
      }
    },
    {
      "name": "qos_detail",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos_detail"
        }
      }
    },
    {
      "name": "qos_detail_volume",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos_detail_volume"
        }
      }
    },
    {
      "name": "qos_volume",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos_volume"
        }
      }
    },
    {
      "name": "qos_volume:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qos_volume%3Aconstituent"
        }
      }
    },
    {
      "name": "qtree",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qtree"
        }
      }
    },
    {
      "name": "qtree:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/qtree%3Aconstituent"
        }
      }
    },
    {
      "name": "svm_cifs",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_cifs"
        }
      }
    },
    {
      "name": "svm_cifs:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_cifs%3Aconstituent"
        }
      }
    },
    {
      "name": "svm_cifs:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_cifs%3Anode"
        }
      }
    },
    {
      "name": "svm_nfs_v3",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v3"
        }
      }
    },
    {
      "name": "svm_nfs_v3:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v3%3Aconstituent"
        }
      }
    },
    {
      "name": "svm_nfs_v3:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v3%3Anode"
        }
      }
    },
    {
      "name": "svm_nfs_v4",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v4"
        }
      }
    },
    {
      "name": "svm_nfs_v41",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v41"
        }
      }
    },
    {
      "name": "svm_nfs_v41:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v41%3Aconstituent"
        }
      }
    },
    {
      "name": "svm_nfs_v41:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v41%3Anode"
        }
      }
    },
    {
      "name": "svm_nfs_v42",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v42"
        }
      }
    },
    {
      "name": "svm_nfs_v42:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v42%3Aconstituent"
        }
      }
    },
    {
      "name": "svm_nfs_v42:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v42%3Anode"
        }
      }
    },
    {
      "name": "svm_nfs_v4:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v4%3Aconstituent"
        }
      }
    },
    {
      "name": "svm_nfs_v4:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/svm_nfs_v4%3Anode"
        }
      }
    },
    {
      "name": "system",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/system"
        }
      }
    },
    {
      "name": "system:constituent",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/system%3Aconstituent"
        }
      }
    },
    {
      "name": "system:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/system%3Anode"
        }
      }
    },
    {
      "name": "token_manager",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/token_manager"
        }
      }
    },
    {
      "name": "volume",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/volume"
        }
      }
    },
    {
      "name": "volume:node",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/volume%3Anode"
        }
      }
    },
    {
      "name": "volume:svm",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/volume%3Asvm"
        }
      }
    },
    {
      "name": "wafl",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/wafl"
        }
      }
    },
    {
      "name": "wafl_comp_aggr_vol_bin",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/wafl_comp_aggr_vol_bin"
        }
      }
    },
    {
      "name": "wafl_hya_per_aggregate",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/wafl_hya_per_aggregate"
        }
      }
    },
    {
      "name": "wafl_hya_sizer",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/wafl_hya_sizer"
        }
      }
    }
  ],
  "num_records": 71,
  "_links": {
    "self": {
      "href": "/api/cluster/counter/tables"
    }
  }
}

Esempio 2: Informazioni di alto livello su una tabella specifica

È possibile utilizzare questa chiamata API REST per visualizzare la descrizione e i metadati di una tabella specifica. L'output include lo scopo della tabella e il tipo di dati contenuti in ciascun contatore di performance. In questo esempio viene utilizzata la tabella host_adapter.

Esempio di arricciamento
curl --request GET --user admin:<PASSWORD> 'https://<ONTAP_IP_ADDRESS>/api/cluster/counter/tables/host_adapter'
Esempio di output JSON
{
  "name": "host_adapter",
  "description": "The host_adapter table reports activity on the Fibre Channel, Serial Attached SCSI, and parallel SCSI host adapters the storage system uses to connect to disks and tape drives.",
  "counter_schemas": [
    {
      "name": "bytes_read",
      "description": "Bytes read through a host adapter",
      "type": "rate",
      "unit": "per_sec"
    },
    {
      "name": "bytes_written",
      "description": "Bytes written through a host adapter",
      "type": "rate",
      "unit": "per_sec"
    },
    {
      "name": "max_link_data_rate",
      "description": "Max link data rate in Kilobytes per second for a host adapter",
      "type": "raw",
      "unit": "kb_per_sec"
    },
    {
      "name": "node.name",
      "description": "System node name",
      "type": "string",
      "unit": "none"
    },
    {
      "name": "rscn_count",
      "description": "Number of RSCN(s) received by the FC HBA",
      "type": "raw",
      "unit": "none"
    },
    {
      "name": "total_read_ops",
      "description": "Total number of reads on a host adapter",
      "type": "rate",
      "unit": "per_sec"
    },
    {
      "name": "total_write_ops",
      "description": "Total number of writes on a host adapter",
      "type": "rate",
      "unit": "per_sec"
    }
  ],
  "_links": {
    "self": {
      "href": "/api/cluster/counter/tables/host_adapter"
    }
  }
}

Esempio 3: Tutte le righe di una tabella specifica

È possibile utilizzare questa chiamata API REST per visualizzare tutte le righe di una tabella. Indica le istanze degli oggetti Counter Manager esistenti.

Esempio di arricciamento
curl --request GET --user admin:<PASSWORD> 'https://<ONTAP_IP_ADDRESS>/api/cluster/counter/tables/host_adapter/rows'
Esempio di output JSON
{
  "records": [
    {
      "id": "dmp-adapter-01",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/host_adapter/rows/dmp-adapter-01"
        }
      }
    },
    {
      "id": "dmp-adapter-02",
      "_links": {
        "self": {
          "href": "/api/cluster/counter/tables/host_adapter/rows/dmp-adapter-02"
        }
      }
    }
  ],
  "num_records": 2,
  "_links": {
    "self": {
      "href": "/api/cluster/counter/tables/host_adapter/rows"
    }
  }
}

Esempio 4: Riga singola in una tabella specifica

È possibile utilizzare questa chiamata API REST per visualizzare i valori del contatore delle prestazioni per una specifica istanza del contatore nella tabella. In questo esempio, vengono richiesti i dati relativi alle prestazioni di uno degli adattatori host.

Esempio di arricciamento
curl --request GET --user admin:<PASSWORD> 'https://<ONTAP_IP_ADDRESS>/api/cluster/counter/tables/host_adapter/rows/dmp-adapter-01'
Esempio di output JSON
{
  "counter_table": {
    "name": "host_adapter"
  },
  "id": "dmp-adapter-01",
  "properties": [
    {
      "name": "node.name",
      "value": "dmp-node-01"
    }
  ],
  "counters": [
    {
      "name": "total_read_ops",
      "value": 25098
    },
    {
      "name": "total_write_ops",
      "value": 48925
    },
    {
      "name": "bytes_read",
      "value": 1003799680
    },
    {
      "name": "bytes_written",
      "value": 6900961600
    },
    {
      "name": "max_link_data_rate",
      "value": 0
    },
    {
      "name": "rscn_count",
      "value": 0
    }
  ],
  "_links": {
    "self": {
      "href": "/api/cluster/counter/tables/host_adapter/rows/dmp-adapter-01"
    }
  }
}