安装了collectd-java还报找不到java.so

当我们安装的collectd-java,就会生成java.so文件,但是重启collectd的时候却还是报找不到java.so文件是怎么回事呢,原来是collectd想找java 6版本的,为了修复这个bug,我们执行如下操作

安装yum install collectd-java
生成/usr/lib64/collectd/java.so文件,
重启systemctl restart collectd
报错:tail -f /var/log/collectd.log
lt_dlopen ("/usr/lib64/collectd/java.so") failed: file not found. The most common cause for this problem is missing dependencies. Use ldd(1) to check the dependencies of the plugin / shared object.

解决办法:
rm /usr/lib64/libjvm.so
ln -svf /m8/jdk/jdk1.8.0_101/jre/lib/amd64/server/libjvm.so /usr/lib64/libjvm.so
systemctl restart collectd

参考:https://community.rsa.com/thread/185477

是在安装hbase-collectd的时候解决的
因为10-jmx.conf文件里面有如下描述:

apt-get install collectd-java collectd-generic-jmx

If your collectd log shows an error loading java.so, see

http://www.willdurness.com/collectinggraphing-information-on-neo4j-via-collectd-and-graphite/

and how they setup LD_LIBRARY_PATH. The basic problem is

collectd wants open JDK 6. You can fix this by adding

export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/usr/lib/jvm/java-7-oracle/jre/lib/amd64/server

to your collectd init file, but pointing to the correct

library path for your java install.

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容