找不到库:tibrvj

发布于 2024-10-27 11:25:06 字数 551 浏览 5 评论 0原文

我在使用 Tibco RV 的 Linux 服务器上运行 Java 应用程序,但收到以下错误:

TibrvException[error=901,message=Library not found: tibrvj]

是什么导致了此问题?

我已经将包含 *.so 的 lib 路径添加到 LD_LIBRARY_PATH 中,但结果仍然相同。

更新:

目前,我已将 /libs/tibrvj.jar 添加到 classpath 中。 tibrvj.jar 已从 Windows 环境复制到我运行应用程序的 Linux 环境中。我从类路径中删除了它并添加了另一个引用 /libs/tibrvj.jar 并解决了问题。它们与前一个文件的大小不同,从 Windows 复制的文件与当前 Linux 盒子中的文件之间可能存在差异。有人可以解释为什么会这样吗?

I'm running a Java application on a Linux server that uses Tibco RV and I get the following error:

TibrvException[error=901,message=Library not found: tibrvj]

What is causing this problem?

I have already added lib path containing *.so into LD_LIBRARY_PATH but still the same result.

UPDATE:

Currently, I have <MyApp>/libs/tibrvj.jar added into classpath. The tibrvj.jar was copied from Windows environment to the Linux box where I'm running my application. I removed this from the classpath and added another reference <TibcoDirectory>/libs/tibrvj.jar and it FIXED the problem. They have different sizes with the previous file and there's probably a difference between the one copied from Windows and the one currently in the Linux box. Can someone explain why is this so?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

左耳近心 2024-11-03 11:25:06

我遇到了同样的问题,并通过执行以下操作修复了它:

  1. 文件 tibrvj.jar 存在于我的应用程序的类路径中
  2. 文件 tibrvj.dll 通过 java 库路径存在。该文件通常位于 Tibco Rendezvous 主目录中的 bin 目录中(例如 C:/tibco/tibrv/8.2/bin)。
  3. 安装的 java 版本与安装的 tibco 版本兼容。

我的环境是:

  1. Windows 7,64 位
  2. Tibco Rendezvous 8.2,64 位
  3. JDK 1.6u29,64 位

之前,我为 i586 处理器安装了 JDK 1.6u17,当我尝试使用以下命令加载库时:

System.loadLibrary("tibrvj");

我收到此错误:

Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\TIBCO\tibrv\8.2\bin\tibrvj.dll: Can't load AMD 64-bit .dll on a IA 32-bit platform

它给了我安装正确的java版本的线索。

I had the same problem, and I fixed it doing the following:

  1. File tibrvj.jar is present in the classpath of my application
  2. File tibrvj.dll is present via java library path. This file is usually located at bin directory in Tibco Rendezvous home directory (e.g. C:/tibco/tibrv/8.2/bin)
  3. The installed java version is compatible with the installed tibco version.

My environment is:

  1. Windows 7, 64bits
  2. Tibco Rendezvous 8.2, 64bits
  3. JDK 1.6u29, 64bits

Before, I had installed a JDK 1.6u17, for a i586 processor and when I tried to load the library using:

System.loadLibrary("tibrvj");

I got this error:

Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\TIBCO\tibrv\8.2\bin\tibrvj.dll: Can't load AMD 64-bit .dll on a IA 32-bit platform

It gave me the clue to instal the correct java version.

梦明 2024-11-03 11:25:06

您是否使用 System.loadLibrary("tibrvj") 加载了库?您是否将其添加到 java.library.path 中?

Have you loaded the library using System.loadLibrary("tibrvj")? Have you added it to java.library.path?

不气馁 2024-11-03 11:25:06

使用

java -Djava.library.path=/opt/tibco/tibrv/lib -cp {}.jar

LD_LIBRARY_PATH=/opt/tibco/tibrv/lib export LD_LIBRARY_PATH

然后**System.loadLibrary("tibrvj");**

Use :

java -Djava.library.path=/opt/tibco/tibrv/lib -cp {}.jar

LD_LIBRARY_PATH=/opt/tibco/tibrv/lib export LD_LIBRARY_PATH

Then **System.loadLibrary("tibrvj");**

攀登最高峰 2024-11-03 11:25:06

rchavarria 和 DaveHowes 的答案有所帮助,但对我来说,问题是我的 IDE 在运行我的项目时覆盖了 PATH 变量(因此覆盖了 java.library.path)。

删除此覆盖使其可以正常工作,因为 IDE 外部的 tibrv 已位于 PATH 上。

The answers by rchavarria and DaveHowes helped, but for me the problem was that my IDE was overriding the PATH variable (and hence java.library.path) when running my project.

Removing this override made it work, as outside the IDE tibrv was already on the PATH.

樱娆 2024-11-03 11:25:06

你在使用包装器吗?

你的wrapper.conf中是否设置了java.library.path?
我在wrapper.conf中设置了java.library.path,更正这个值解决了我的问题。

Are you using Wrappers?

Do you have java.library.path set in your wrapper.conf?
I had java.library.path set in wrapper.conf, correct this value fixed the issue for me.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文