Here is snippet from output of "strace -f -o strace.log snmpd -c
/config/snmpd.conf"

.....
13145 fstat64(8, {st_mode=S_IFREG|0644, st_size=1989, ...}) = 0
13145 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS,
-1, 0) = 0xf65f5000
13145 read(8, "################################"..., 4096) = 1989
13145 open("/root/gtmmib.so", O_RDONLY) = -1 EACCES (Permission denied)
13145 fstat64(3, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0
13145 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS,
-1, 0) = 0xf65f4000
13145 write(3, "dlopen failed: /root/gtmmib.so: "..., 82) = 82
13145 write(3, "Turning on AgentX master support"..., 34) = 34
13145 brk(0)                            = 0x8916000
13145 brk(0x8937000)                    = 0x8937000
13145 open("/etc/mtab", O_RDONLY)       = 9
.....


-----Original Message-----
From: Thomas Anders [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 07, 2006 7:02 PM
To: Fong Tsui
Cc: [email protected]
Subject: Re: dlopen failed

Fong Tsui wrote:
> Fong Tsui wrote:
>>> When I try to use dlmod to load shared module, I got the following
>>> error:
>>> dlopen failed: /root/gtmmib.so: cannot open shared object file:
>>> Permission denied
>>>
>>> /root/gtmmib.so has been set to "chmod 777".
> /root is also "chmod 777".
> 
> Thomas Anders> What are the permissions of the /root directory itself?
> /root is also "chmod 777".
> 
> Thomas Anders> If you strace the process, what's the output for the
> dlopen call?
> Attached is my strace -o strace.log snmpd -c /config/snmpd.conf.
> I don't see anything for dlopen call in strace.log file.

You're not tracing the forked child. Rerun with:

  strace -f -o strace.log snmpd -c /config/snmpd.conf

and only post the *snippet* related to the dlopen call.


+Thomas

-- 
Thomas Anders (thomas.anders at blue-cable.de)

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to