Hello everyone,
I have generated a C code with mib2c tool, than implemented
it according to my need. Everything is working fine .I have assigned values
with system calls. These system call calling a shell script and getting
output from there. When I am using SNMPGET or WALK it
Hello everyone,
I have generated a C code with mib2c tool, than implemented
it according to my need. Everything is working fine .I have assigned values
with system calls. These system call calling a shell script and getting
output from there. When I am using SNMPGET or WALK it
To: Net-snmp-coders@lists.sourceforge.net
Subject: net-snmp agent problem
Hello everyone,
I have generated a C code with mib2c tool, than implemented it
according to my need. Everything is working fine .I have assigned values with
system calls. These system call calling a shell
int temp()
{
FILE *pipe = NULL;
pipe=popen(/home/jatin/net-snmp-5.7.2.rc1/agent/mibgroup/cpu.sh,r);
if(!pipe)
{
snmp_log(LOG_ERR, popen failed in temp(), errno: %d\n, errno);
return -1;
}
Thank you Sir,
But the issue is with popen();
On 12 September 2012 10:02, Jatin Bodarya jatin.boda...@elitecore.com wrote:
But the issue is with popen(); call... when I am using SNMPWALK
command to get value it is working perfectly and returning me correct
value... but only 10-15 time... then after popen fails !
Have you
You are very much right sir, Ignoring warnings and error values can give
troubles.
Its working !! with pclose(pipe); only..thank you so much sir...
--
Live Security Virtual Conference
Exclusive live event will cover