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 al
On 12 September 2012 10:02, Jatin Bodarya 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 considered closing the pipe a
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
helps
Walter
From: Jatin Bodarya [mailto:[email protected]]
Sent: Mittwoch, 12. September 2012 08:49
To: [email protected]
Subject: net-snmp agent problem
Hello everyone,
I have generated a C code with mib2c tool, than implemented it
according to my need.
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 g
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 g