linux-centos6.3 環境下使用eclipse開發rmi 出現“ObjID already in use”錯誤

來源:互聯網
上載者:User

標籤:localhost   creating   already   伺服器   linux   

在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

linux-centos6.3 環境下使用eclipse開發rmi 出現“ObjID already in use”錯誤

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.