我正在尝试从远程执行 snmpget,但它只能从服务器本身起作用:
server $ ipAddress=$(ip -4 -o a show dev enp1s0f0 | awk -F ' *|/' '{print$4;exit}')
server $ snmpget -v3 -u svc_snmp_v3 -l authNoPriv -a SHA-512 -A $MDP_SNMP_V3 $ipAddress sysName.0
SNMPv2-MIB::sysName.0 = STRING: server
remote $ ipAddress=x.y.z.t # The IP address of my server
remote $ snmpget -v3 -u svc_snmp_v3 -l authNoPriv -a SHA-512 -A $MDP_SNMP_V3 $ipAddress sysName.0
sysName.0: Unknown Object Identifier (Sub-id not found: (top) -> sysName)
remote $ echo $?
1
怎么了 ?