snmp笔记


生成generater配置操作

点击查看代码
###安装依赖模块
```shell script
yum install -y epel-release
yum group install -y "Development Tools"
yum install -y wget net-snmp net-snmp-utils net-snmp-libs net-snmp-devel golang p7zip*

测试SNMP

snmpwalk -v2c -c tcpipro 10.1.1.216 .1

git snmp_exporter

cd /
git clone https://github.com/prometheus/snmp_exporter.git

go国内代理

export G0111MODULE=on
export GOPROXY=https://goproxy.cn,direct

build generator

go get github.com/prometheus/snmp_exporter/generator
cd snmp_exporter/generator/
go build
make mibs
参考: 我是参考这个安装的https://blog.csdn.net/sinat_21302587/article/details/75127133 https://www.cnblogs.com/alanjl/p/11685064.html