Konfigurieren Sie SNMPv3
Gehen Sie wie folgt vor, um SNMPv3 zu konfigurieren, das die Statusüberwachung des Ethernet-Switches (CSHM) unterstützt.
Mit den folgenden Befehlen wird ein SNMPv3-Benutzername auf Cisco 9336C-FX2-Switches konfiguriert:
-
Für keine Authentifizierung:
snmp-server user SNMPv3_USER NoAuth
-
Für * MD5/SHA-Authentifizierung*:
snmp-server user SNMPv3_USER auth [md5|sha] AUTH-PASSWORD
-
Für MD5/SHA-Authentifizierung mit AES/DES-Verschlüsselung:
snmp-server user SNMPv3_USER AuthEncrypt auth [md5|sha] AUTH-PASSWORD priv aes-128 PRIV-PASSWORD
Mit dem folgenden Befehl wird ein SNMPv3-Benutzername auf der ONTAP-Seite konfiguriert:
cluster1::*> security login create -user-or-group-name SNMPv3_USER -application snmp -authentication-method usm -remote-switch-ipaddress ADDRESS
Mit dem folgenden Befehl wird der SNMPv3-Benutzername mit CSHM eingerichtet:
cluster1::*> system switch ethernet modify -device DEVICE -snmp-version SNMPv3 -community-or-username SNMPv3_USER
-
Richten Sie den SNMPv3-Benutzer auf dem Switch so ein, dass Authentifizierung und Verschlüsselung verwendet werden:
show snmp user
Beispiel anzeigen
(sw1)(Config)# snmp-server user SNMPv3User auth md5 <auth_password> priv aes-128 <priv_password> (sw1)(Config)# show snmp user ----------------------------------------------------------------------------- SNMP USERS ----------------------------------------------------------------------------- User Auth Priv(enforce) Groups acl_filter ----------------- --------------- --------------- --------------- ----------- admin md5 des(no) network-admin SNMPv3User md5 aes-128(no) network-operator ----------------------------------------------------------------------------- NOTIFICATION TARGET USERS (configured for sending V3 Inform) ----------------------------------------------------------------------------- User Auth Priv ----------------- ------------------ ------------ (sw1)(Config)#
-
Richten Sie den SNMPv3-Benutzer auf der ONTAP-Seite ein:
security login create -user-or-group-name <username> -application snmp -authentication-method usm -remote-switch-ipaddress 10.231.80.212
Beispiel anzeigen
cluster1::*> system switch ethernet modify -device "sw1 (b8:59:9f:09:7c:22)" -is-monitoring-enabled-admin true cluster1::*> security login create -user-or-group-name <username> -application snmp -authentication-method usm -remote-switch-ipaddress 10.231.80.212 Enter the authoritative entity's EngineID [remote EngineID]: Which authentication protocol do you want to choose (none, md5, sha, sha2-256) [none]: md5 Enter the authentication protocol password (minimum 8 characters long): Enter the authentication protocol password again: Which privacy protocol do you want to choose (none, des, aes128) [none]: aes128 Enter privacy protocol password (minimum 8 characters long): Enter privacy protocol password again:
-
Konfigurieren Sie CSHM für die Überwachung mit dem neuen SNMPv3-Benutzer:
system switch ethernet show-all -device "sw1" -instance
Beispiel anzeigen
cluster1::*> system switch ethernet show-all -device "sw1" -instance Device Name: sw1 IP Address: 10.231.80.212 SNMP Version: SNMPv2c Is Discovered: true SNMPv2c Community String or SNMPv3 Username: cshm1! Model Number: N9K-C9336C-FX2 Switch Network: cluster-network Software Version: Cisco Nexus Operating System (NX-OS) Software, Version 9.3(7) Reason For Not Monitoring: None <---- displays when SNMP settings are valid Source Of Switch Version: CDP/ISDP Is Monitored ?: true Serial Number of the Device: QTFCU3826001C RCF Version: v1.8X2 for Cluster/HA/RDMA cluster1::*> cluster1::*> system switch ethernet modify -device "sw1" -snmp-version SNMPv3 -community-or-username <username> cluster1::*>
-
Stellen Sie sicher, dass die Seriennummer, die mit dem neu erstellten SNMPv3-Benutzer abgefragt werden soll, mit der im vorherigen Schritt nach Abschluss des CSHM-Abfragezeitraums enthaltenen identisch ist.
system switch ethernet polling-interval show
Beispiel anzeigen
cluster1::*> system switch ethernet polling-interval show Polling Interval (in minutes): 5 cluster1::*> system switch ethernet show-all -device "sw1" -instance Device Name: sw1 IP Address: 10.231.80.212 SNMP Version: SNMPv3 Is Discovered: true SNMPv2c Community String or SNMPv3 Username: SNMPv3User Model Number: N9K-C9336C-FX2 Switch Network: cluster-network Software Version: Cisco Nexus Operating System (NX-OS) Software, Version 9.3(7) Reason For Not Monitoring: None <---- displays when SNMP settings are valid Source Of Switch Version: CDP/ISDP Is Monitored ?: true Serial Number of the Device: QTFCU3826001C RCF Version: v1.8X2 for Cluster/HA/RDMA cluster1::*>