esxcli system snmp test fails with connect uds socket failed error
search cancel

esxcli system snmp test fails with connect uds socket failed error

book

Article ID: 442192

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

After reconfiguring SNMP settings using the esxcli system snmp set command, executing the esxcli system snmp test command fails with the following error:

Agent not responding, connect uds socket(/var/run/snmp.ctl) failed 2, err= No such file or directory

The issue automatically resolves on its own after a few minutes.

Cause

After a configuration change is executed via the esxcli system snmp set command, the snmpd service initialization task runs. This initialization includes time-consuming operations, such as scanning datastores. During this initialization period, connections to the snmpd UNIX Domain Socket (UDS) cannot be established. Depending on the total number and capacity of the configured datastores, this process can take several minutes to complete.

Resolution

This is expected behavior. Please wait a few minutes for the initialization task to complete, then retry the command.