{"id":303,"date":"2018-12-13T21:14:24","date_gmt":"2018-12-13T13:14:24","guid":{"rendered":"https:\/\/dragonyue.fortiddns.com\/blog\/?p=303"},"modified":"2022-07-31T13:07:02","modified_gmt":"2022-07-31T05:07:02","slug":"esxi-snmp-v3","status":"publish","type":"post","link":"https:\/\/dragonyue.fortiddns.com\/blog\/esxi-snmp-v3\/","title":{"rendered":"esxi snmp v3"},"content":{"rendered":"<p><a href=\"https:\/\/docs.vmware.com\/tw\/VMware-vSphere\/6.5\/com.vmware.vsphere.monitoring.doc\/GUID-2E4B0F2A-11D8-4649-AC6C-99F89CE93026.html\">\u53c3\u8003\u7db2\u5740\uff1ahttps:\/\/docs.vmware.com\/tw\/VMware-vSphere\/6.5\/com.vmware.vsphere.monitoring.doc\/GUID-2E4B0F2A-11D8-4649-AC6C-99F89CE93026.html<\/a><\/p>\n<pre class=\"lang:sh decode:true \">#\u8a2d\u5b9a\u5f15\u64ceID(\u5341\u516d\u9032\u5236\u5b57\u4e32\u9577\u5ea6\u9700\u4ecb\u65bc5~32)\r\nesxcli system snmp set --engineid id\r\n\r\n#\u8a2d\u5b9a\u8a8d\u8b49\u52a0\u5bc6\u65b9\u5f0f\r\nesxcli system snmp set --authentication \u52a0\u5bc6\u65b9\u5f0f(none, SHA1, MD5)\r\n\r\n#\u8a2d\u5b9a\u96b1\u79c1\u52a0\u5bc6\u65b9\u5f0f\r\nesxcli system snmp set --privacy \u52a0\u5bc6\u65b9\u5f0f(none, AES128)\r\n\r\n#\u7522\u751f\u9a57\u8b49\u3001\u96b1\u79c1\u96dc\u6e4a\u503c\r\nesxcli system snmp hash --auth-hash authsecret --priv-hash privsecret --raw-secret\r\nauthsecret, privsecret:\u8acb\u81ea\u884c\u8f38\u5165\r\n\u7bc4\u4f8b\u8f38\u5165\r\nesxcli system snmp hash --auth-hash dragonyue --priv-hash dragonyue --raw-secret\r\n\u7bc4\u4f8b\u8f38\u51fa\r\nAuthhash: 52bc8e54a245feefb806750f869900a4251a0028\r\nPrivhash: 52bc8e54a245feefb806750f869900a4251a0028\r\n\r\n#\u8a2d\u5b9aSNMP\u4f7f\u7528\u8005\r\nesxcli system snmp set --users userid\/authhash\/privhash\/security\r\nuserid:\u8acb\u81ea\u884c\u8f38\u5165\r\nauthhash, privihash:\u8acb\u7528\u7522\u751f\u51fa\u4f86\u7684\u96dc\u6e4a\u503c\r\nsecurity:auth (\u4ee3\u8868\u50c5\u9a57\u8b49), priv (\u4ee3\u8868\u9a57\u8b49\u548c\u96b1\u79c1), none (\u4ee3\u8868\u7121\u9a57\u8b49\u6216\u96b1\u79c1)\r\n\r\n#\u555f\u7528SNMP\r\nesxcli system snmp set --enable true\r\n\r\n#\u67e5\u770bSNMP\u8a2d\u5b9a\u8cc7\u8a0a\r\nesxcli system snmp get<\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u53c3\u8003\u7db2\u5740\uff1ahttps:\/\/docs.vmware.com\/tw\/VMware-vSphere\/6.5\/com. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-303","post","type-post","status-publish","format-standard","hentry","category-esxi"],"_links":{"self":[{"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/posts\/303","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/comments?post=303"}],"version-history":[{"count":2,"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/posts\/303\/revisions"}],"predecessor-version":[{"id":420,"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/posts\/303\/revisions\/420"}],"wp:attachment":[{"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/media?parent=303"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/categories?post=303"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dragonyue.fortiddns.com\/blog\/wp-json\/wp\/v2\/tags?post=303"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}