Java “GlassFish 服务器,部署,空,假”错误
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/20277110/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
"GlassFish Server, deploy, null, false" error
提问by migmig
I'm having problems with Glassfish 4.0 + Netbeans 7.4... whenever i try to run my project i get this erros:
我在使用 Glassfish 4.0 + Netbeans 7.4 时遇到问题......每当我尝试运行我的项目时,我都会遇到这个错误:
ant -f D:\Projetos\NetBeans\Sullimar -Dbrowser.context=D:\Projetos\NetBeans\Sullimar\web\index.html -DforceRedeploy=false -Dclient.urlPart=/index.html -Ddirectory.deployment.supported=true -Dnb.wait.for.caches=true -Dnb.internal.action.name=run.single run
init:
deps-module-jar:
deps-ear-jar:
deps-jar:
library-inclusion-in-archive:
library-inclusion-in-manifest:
compile:
compile-jsps:
In-place deployment at D:\Projetos\NetBeans\Sullimar\build\web
GlassFish Server, deploy, null, false
D:\Projetos\NetBeans\Sullimar\nbproject\build-impl.xml:1045: The module has not been deployed.
See the server log for details.
BUILD FAILED (total time: 0 seconds)
and my glassfish server output:
和我的 glassfish 服务器输出:
Informations: visiting unvisited references
Informations: Created HTTP listener http-listener-1 on host/port 0.0.0.0:2869
Informations: Created HTTP listener http-listener-2 on host/port 0.0.0.0:8181
Informatios: Created HTTP listener admin-listener on host/port 0.0.0.0:4848
Grave: Cannot start container web, exception: A MultiException has 2 exceptions. They are:
1. java.lang.IllegalArgumentException: virtual server server has an invalid docroot C:\Users\Thaís\GlassFish_Server\glassfish\domains\domain1/docroot
2. java.lang.IllegalStateException: Unable to perform operation: post construct on com.sun.enterprise.web.WebContainer
Grave: Aborting, Failed to start container com.sun.enterprise.web.WebContainer
Grave: Exception while deploying the app [Sullimar]
Grave: Exception during lifecycle processing
java.lang.Exception: Aborting, Failed to start container com.sun.enterprise.web.WebContainer
at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:736)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:374)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:219)
at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:491)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.run(CommandRunnerImpl.java:527)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.run(CommandRunnerImpl.java:523)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:356)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.execute(CommandRunnerImpl.java:522)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:546)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1423)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.access00(CommandRunnerImpl.java:108)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1762)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1674)
at com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:534)
at com.sun.enterprise.v3.admin.AdminAdapter.onMissingResource(AdminAdapter.java:224)
at org.glassfish.grizzly.http.server.StaticHttpHandler.service(StaticHttpHandler.java:297)
at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246)
at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:191)
at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:168)
at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:189)
at org.glassfish.grizzly.filterchain.ExecutorResolver.execute(ExecutorResolver.java:119)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:288)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:206)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:136)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:114)
at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:838)
at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access0(WorkerThreadIOStrategy.java:55)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
at java.lang.Thread.run(Thread.java:744)
Grave: Exception while deploying the app [Sullimar] : Aborting, Failed to start container com.sun.enterprise.web.WebContainer
What do I do to fix these errors? In my Services tab I can access my databases, and my dabatase connection to my Sullimar database works fine (I can view the data...) so I can't underastand the problem. Thanks a million!
我该怎么做才能修复这些错误?在我的服务选项卡中,我可以访问我的数据库,并且我与 Sullimar 数据库的 dabatase 连接工作正常(我可以查看数据...)所以我无法理解这个问题。太感谢了!
回答by Ben Tahar Nidhal
Take a look at your server.log file. It's located under /$YouGlassfishRoot/glassfish/domains/$Domain/logs/server.log The problem is probably your server's jdk version.
查看您的 server.log 文件。它位于 /$YouGlassfishRoot/glassfish/domains/$Domain/logs/server.log 下 问题可能是您服务器的 jdk 版本。
回答by Atorian
Got the S.O.B to work. Turns out Windows firewall was blocking Netbeans (as it should), which for whatever reason requires incoming connections for deployment.
让 SOB 开始工作。事实证明,Windows 防火墙阻止了 Netbeans(它应该如此),无论出于何种原因,它都需要传入连接进行部署。
Try create a rule allowing inbound TCP for C:\program files\netbeans 8.0\bin\netbeans64.exe
尝试创建一个允许入站 TCP 的规则 C:\program files\netbeans 8.0\bin\netbeans64.exe
回答by sowieso-fruehling
I had similar problem on Windows 7, for you it's to late, but it could help somebody else. First there was no server.log file in GLASSFISH_INSTALATION_DIRECTORY\glassfish\domains\domain1\logs and the reason was that my user didn't have rights to write anywhere in GLASSFISH_INSTALATION_DIRECTORY (glassfish was installed with netbeans )
我在 Windows 7 上遇到了类似的问题,对你来说为时已晚,但它可以帮助其他人。首先在 GLASSFISH_INSTALATION_DIRECTORY\glassfish\domains\domain1\logs 中没有 server.log 文件,原因是我的用户无权在 GLASSFISH_INSTALATION_DIRECTORY 中的任何地方写入( glassfish 与 netbeans 一起安装)
after fixing that I found "...Invalid resource : jdbc/..." exception and fix for that can be found at this webpage https://netbeans.org/kb/docs/web/jsf20-crud.htmlunder Troubleshooting paragraph
修复后,我发现“...无效资源:jdbc/...”异常并可以在此网页https://netbeans.org/kb/docs/web/jsf20-crud.html下的故障排除下找到修复段落