I am trying to write a snmp subagent that using agentX, which is supported by net-snmp. At first, I used the example codes from net-snmp FAQ:
http://www.net-snmp.org/wiki/index.php/TUT:Writing_a_Subagent
And from the example codes (example-demon.c,nstAgentSubagentObject.c,nstAgentSubagentObject.h), I build a subagent which can use agentX to perform snmpget and snmpset.
My question is: From the code in nstAgentSubagentObject.c, there are many trace codes such as follows:
DEBUGMSGTL(("nstAgentSubagentObject",
"Initializing the nstAgentSubagentObject module
"));
但是,我可以看一看这个记录。
I tried to start snmpd (demon of snmp) by
snmpd -f -DnstAgentSubagentObject -Lf /tmp/snmp.log
.
但我仍然看着这个记录。 谁能告诉我,如何看到DEBUGMSGTL的标志?