I am having a great deal of difficulty getting yourkit to find the library on x86_64.
I have checked and rechecked the path. I keep getting the following:
[solman@jabberwock linux-amd64]$ java -Xrunyjpagent:help
Error occurred during initialization of VM
Could not find agent library on the library path or in the local directory: yjpagent
Here is some possibly helpful output based on a similar query in these forums:
[solman@jabberwock linux-amd64]$ ldd libyjpagent.so
libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00002aaaaac76000)
libm.so.6 => /lib64/libm.so.6 (0x00002aaaaae75000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00002aaaaaffa000)
libc.so.6 => /lib64/libc.so.6 (0x00002aaaab108000)
/lib64/ld-linux-x86-64.so.2 (0x0000555555554000)
[solman@jabberwock linux-amd64]$ uname -a
Linux jabberwock.cozmo.tv 2.6.12-1.1390_FC4smp #1 SMP Tue Jul 5 20:09:48 EDT 2005 x86_64 x86_64 x86_64 GNU/Linux
The path is:
LD_LIBRARY_PATH=/var/tmp/yjp/bin/linux-amd64
(I put it there and set all permissions just to rule out any possibility of security issues. I first tried it from a more conventional location)
Can't find agent library on Linux x86_64 for EAP 628
-
- Posts: 6
- Joined: Fri Jul 22, 2005 5:44 pm
-
- Posts: 1626
- Joined: Tue Aug 10, 2004 7:52 pm
-
- Posts: 6
- Joined: Fri Jul 22, 2005 5:44 pm
Explicitly using 64bit JDK doesn't solve problem
Here is my output:Vladimir Kondratyev wrote:I suppose that your java is 32 bit. What is ouput of "java -version"?
[solman@jabberwock bin]$ ./java -version
java version "1.5.0_04"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_04-b05)
Java HotSpot(TM) 64-Bit Server VM (build 1.5.0_04-b05, mixed mode)
[solman@jabberwock bin]$ ./java -Xrunyjpagent:help
Error occurred during initialization of VM
Could not find agent library on the library path or in the local directory: yjpagent
[solman@jabberwock bin]$ set
[...]
JAVA_HOME=/usr/java/jdk1.5.0_04
[...]
LD_LIBRARY_PATH=/var/tmp/yjp/bin/linux-amd64
[...]
PATH=/usr/java/jdk1.5.0_04/bin:/usr/java/jdk1.5.0_04/jre/bin:/home/systems/ant/bin:/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/solman/bin
-
- Posts: 6172
- Joined: Wed Aug 11, 2004 8:37 am
-
- Posts: 6
- Joined: Fri Jul 22, 2005 5:44 pm
Fixed, but I don't know how
In doing this, I noticed that ldd libyjpagent.so only worked from the directory in which the library exists.
I wrongly concluded that I needed to get ldd to work from other directories. Although I was never successful in this, by the time I gave up, YourKit was working.
Amongst the things I tried was copying the library to /lib, /usr/lib and /lib64.
Runing ldconfig.
Rebooting the machine.
Adding a : in front of LD_LIBRARY_PATH
Specifying SHLIB path.
Regretably I have no idea which of these fixed the problem, and I lack the clue to figure it out.
I wrongly concluded that I needed to get ldd to work from other directories. Although I was never successful in this, by the time I gave up, YourKit was working.
Amongst the things I tried was copying the library to /lib, /usr/lib and /lib64.
Runing ldconfig.
Rebooting the machine.
Adding a : in front of LD_LIBRARY_PATH
Specifying SHLIB path.
Regretably I have no idea which of these fixed the problem, and I lack the clue to figure it out.
-
- Posts: 6
- Joined: Fri Jul 22, 2005 5:44 pm
How I fixed it
I just repeated the procedure on a new machine and was able to determine which step fixed the problem. In summary:
PROBLEM: On x86_64 runing 64-bit fedora core 4 with the 64-bit linux jdk1.5.0_04 downloaded from sun, the JDK can't find the yjp library:
[solman@prospero ~]$ java -Xrunyjpagent:help
Error occurred during initialization of VM
Could not find agent library on the library path or in the local directory: yjpagent
SOLUTION: copy the linux-amd64 verison of libyjpagent.so to /lib64
This fixes the problemt without any of the other steps. None of the other steps seem to help,
PROBLEM: On x86_64 runing 64-bit fedora core 4 with the 64-bit linux jdk1.5.0_04 downloaded from sun, the JDK can't find the yjp library:
[solman@prospero ~]$ java -Xrunyjpagent:help
Error occurred during initialization of VM
Could not find agent library on the library path or in the local directory: yjpagent
SOLUTION: copy the linux-amd64 verison of libyjpagent.so to /lib64
This fixes the problemt without any of the other steps. None of the other steps seem to help,