linux-centos6.3 环境下使用eclipse开发rmi 出现“ObjID already in use”错误
2015-05-06 14:31
701 查看
在Linux-centos6.3下使用eclipse开发rmi,启动tomcat服务,发现“ObjID already in use”错误。日志截取如下:
ERROR [org.springframework.web.context.ContextLoader] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'avmRemoteService' ...
: internal error: ObjID already in use
分析错误原因,应该归属于linux环境下的rmi常见问题,出现这种问题及有可能是/etc/hosts文件中指定的IP并不是当前服务器的真实IP,RMI在初始化时注册服务失败。
解决方法:
修改/etc/hosts文件,在这个文件中增加一行,如下所示,192.168.67.129 alf1 localhost localhost.localdomain localhost4 localhost4.localdomain4就行,或者将/etc/hosts文件中默认的127.0.0.1改成当前机器的IP即可!
127.0.0.1 alf1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.10.103 alf1 localhost localhost.localdomain localhost4 localhost4.localdomain4
修改后,重新启动服务,成功.
附加:使用hostname查看主机名称。
本文出自 “lendcode” 博客,请务必保留此出处http://lendcode.blog.51cto.com/3532846/1642531
ERROR [org.springframework.web.context.ContextLoader] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'avmRemoteService' ...
: internal error: ObjID already in use
分析错误原因,应该归属于linux环境下的rmi常见问题,出现这种问题及有可能是/etc/hosts文件中指定的IP并不是当前服务器的真实IP,RMI在初始化时注册服务失败。
解决方法:
修改/etc/hosts文件,在这个文件中增加一行,如下所示,192.168.67.129 alf1 localhost localhost.localdomain localhost4 localhost4.localdomain4就行,或者将/etc/hosts文件中默认的127.0.0.1改成当前机器的IP即可!
127.0.0.1 alf1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.10.103 alf1 localhost localhost.localdomain localhost4 localhost4.localdomain4
修改后,重新启动服务,成功.
附加:使用hostname查看主机名称。
本文出自 “lendcode” 博客,请务必保留此出处http://lendcode.blog.51cto.com/3532846/1642531
相关文章推荐
- 地址已经被使用——Address already in use(纠正《后台开发:核心技术于应用实践》书中的错误)
- Eclipse使用Git导入项目时可能出现的错误【A .project file already exists in directory】解决办法
- MAC电脑怎么解决?错误: 代理抛出异常错误: java.rmi.server.ExportException: Port already in use: 1099;
- 解决Eclipse中启动Tomcat时出现 Port 8080 required by Tomcat v7 Server at localhost is already in use...
- 启动tomcat 时错误: 代理抛出异常错误: java.rmi.server.ExportException: Port already in use: 1099;
- 启动tomcat时 错误: 代理抛出异常 : java.rmi.server.ExportException: Port already in use: 1099的解决办法
- 解决 eclipse出现 Address already in use: bind
- VMWare虚拟机安装CentOS 7 Linux及Hadoop与Eclipse学习环境(3-Eclipse开发环境)
- Linux启动服务时提示错误:Address already in use
- 错误: 代理抛出异常错误: java.rmi.server.ExportException: Port already in use: 1099; nested exception is
- Linux使用基础二:开发环境搭建(jdk+tomcat+eclipse)
- linux下Eclipse+CDT开发环境配置与使用
- 在使用eclipse 运行 maven install的时候,出现这个错误:Unable to locate the Javac Compiler in:…
- 解决 eclipse出现 Address already in use: bind
- 错误: 代理抛出异常错误: java.rmi.server.ExportException: Port already in use: 1099; nested exception is
- 【ARM-Linux开发】Linux环境下使用eclipse开发C++动态链接库程序
- myeclipse使用jta遇到Error in init: Log already in use? tmlog in ./\错误
- 启动tomcat时 错误: 代理抛出异常 : java.rmi.server.ExportException: Port already in use: 1099的解决办法