I am new to SNMP, thank you for bearing with me.... I have an existing Perl script for a sub-agent and the following issue came up when trying to run it: The agent seems to connect to the "default" snmpd deamon which is configured as a master agent (the line "master agentx" is present in the snmpd.conf). At this point the script assigns some values to the objects in my MIB. However, when I then perform a snmpwalk or snmpget on the master-agent, I get (for a v1 query) "End of MIB". When I perform a query on the system OID it works....something must be broken.
The MIB is registered correctly (I can do a snmptranslate) and uses the "enterprises" OID where the company this is for registered their own enterprise OID.
I have been looking around to see what the issue can be and it believe I am missing the configuration file for the sub-agent: On this site they add this comment with the sub-agent registration:
my $agent = new NetSNMP::agent(
# **makes the agent read a my_agent_name.conf file**
'Name' => "my_agent_name",
'AgentX' => 1
);
}
My setup (which I did not write myself but should be fully functional) does not have a file "my-agent_name.conf". I do have the correct snmpd.conf (for the master-agent) and the sub-agent seems to connect (If I remove the line "master agentx" from snmpd.conf the agent reports a connection failure).
Is the issue the missing sub-agent configuration file and if so, what should I put in there? I simply cannot find anything more on the subject and my knowledge of SNMP is too limited to figure this out using man-pages.
I am using Ubuntu/Xubuntu for testing.
Thanks