我在Eclipse中使用GlassFish4进行Java动态Web开发。 GlassFish无法再部署我的项目。我已经在stackoverflow和互联网上尝试了几种方法来修复它。

我什至无法通过localhost:4848访问管理控制台。我看到了glassfish控制台的表面,但显示“状态:尚未安装管理控制台应用程序”。

这是我的错误:

 [2018-05-05T20:28:14.580+0200] [glassfish 4.1] [INFO] [NCLS-CORE-00093] [javax.enterprise.system.core] [tid: _ThreadID=104 _ThreadName=Thread-23] [timeMillis: 1525544894580] [levelValue: 800] [[
  Problem while attempting to install admin console!
org.jvnet.hk2.config.TransactionFailure: A ApplicationRef with the same key "__admingui" already exists in Server server
    at org.jvnet.hk2.config.ConfigSupport._apply(ConfigSupport.java:209)
    at org.jvnet.hk2.config.ConfigSupport.apply(ConfigSupport.java:139)
    at com.sun.enterprise.v3.admin.adapter.InstallerThread.install(InstallerThread.java:166)
    at com.sun.enterprise.v3.admin.adapter.InstallerThread.run(InstallerThread.java:99)
Caused by: java.lang.IllegalArgumentException: A ApplicationRef with the same key "__admingui" already exists in Server server
    at org.jvnet.hk2.config.WriteableView$ProtectedList.add(WriteableView.java:648)
    at com.sun.enterprise.v3.admin.adapter.InstallerThread$1.run(InstallerThread.java:161)
    at org.jvnet.hk2.config.ConfigSupport._apply(ConfigSupport.java:180)
    ... 3 more
]]


我感谢各种帮助。

最佳答案

我假设您正在使用glassfish应用程序服务器的本地实例。您可以在安装之前检查是否满足了GF 4.1 Release Notes中列出的要求。

您可以采取的另一种措施是使用安装目录/ bin文件夹中的命令asadmin verify-domain-xml验证domain.xml配置文件的完整性。

您说您无法访问管理控制台,但是服务器是否还在运行? (http://localhost:8080/)。

您也可以查看server.log以获取有关正在发生的事情的更多提示,可以在install-directory / domains / domain-name / logs中找到它们,或者尝试执行a manual deployment via asadmin并查看会发生什么。

07-24 09:47
查看更多