IDEA无法启动本地glassfish服务器 [英] IDEA failed to start a local glassfish server

查看:404
本文介绍了IDEA无法启动本地glassfish服务器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Intellij IDEA 13.1.4中启动Glassfish 4.1。我在运行/调试配置窗口中设置了基本设置 - 选定的应用程序服务器jvm将2个工件部署,左侧启动/连接配置默认。当我尝试启动它时抛出异常。这里有完整的堆栈跟踪:

  / home / glassfish / glassfish / bin / asadmin start-domain domain1 

检测到的服务器管理端口:4848
检测到的服务器http端口:8080
[2014-11-14 03:09:49,839] Artifact ss-ear:ear:服务器没有连接.Deploy不可用。
[2014-11-14 03:09:49,839]神器ss-ear:耳朵爆炸:服务器未连接。部署不可用。

java.nio.file.AccessDeniedException:/home/glassfish/glassfish/domains/domain1/logs/server.log.lck
在sun.nio.fs.UnixException.translateToIOException(UnixException .java:84)
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102)
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107)
。在sun.nio.fs.UnixFileSystemProvider.newFileChannel(UnixFileSystemProvider.java:177)
处java.nio.channels中java.nio.channels.FileChannel.open(FileChannel.java:287)
。 FileChannel.open(FileChannel.java:335)
。在java.util.logging.FileHandler.openFiles(FileHandler.java:438)LT
。在java.util.logging.FileHandler&;初始化>(的FileHandler的.java:318)
处com.sun.enterprise.admin.launcher.GFLauncher.setup com.sun.enterprise.admin.launcher.GFLauncherLogger.addLogFileHandler(GFLauncherLogger.java:99)
(GFLauncher .java:192)
at com.sun.enterprise.admin.servermgmt.cli.StartDomainCommand.createLauncher(StartDomainCommand.java:228 )
在com.sun.enterprise.admin.servermgmt.cli.StartDomainCommand.executeCommand(StartDomainCommand.java:124)
在com.sun.enterprise.admin.cli.CLICommand.execute(CLICommand.java :322)
at com.sun.enterprise.admin.cli.AdminMain.executeCommand(AdminMain.java:366)
at com.sun.enterprise.admin.cli.AdminMain.doMain(AdminMain.java :300)
at org.glassfish.admin.cli.AsadminMain.main(AsadminMain.java:56)

等待domain1启动.Error启动domain domain1。
服务器过早退出并退出代码1.
命令启动域失败。
在它死亡之前,它产生了以下输出:

在地址:9009
处侦听传输dt_socket $在$ Felix平台上启动GlassFish
线程mainjava中的异常.lang.RuntimeException:域目录不可写。在com.sun.enterprise.glassfish.bootstrap.MainHelper.verifyDomainRoot(MainHelper.java:246)

在com.sun.enterprise.glassfish.bootstrap.MainHelper.findInstanceRoot(MainHelper.java:349)
at com.sun.enterprise.glassfish.bootstrap.GlassFishMain.main(GlassFishMain.java:78)
at com.sun.enterprise.glassfish.bootstrap.ASMain.main(ASMain.java:54)

我使用的是Ubuntu OS 14.04 LTS,java-1.7.0-openjdk-amd64。
安装在/ home / glassfish中的Glassfish,asadmin脚本拥有777个权限。
服务器启动时,我从终端运行它,但不是从IDE运行它。



请帮忙,这让我很生气!

试图用sudo权限启动IntelliJ并在IDE内启动服务器?


I'm trying to start Glassfish 4.1 in Intellij IDEA 13.1.4. I've set basic settings in Run/debug configurations window - selected application server, jvm, put 2 artifacts to deploy, left startup/connection configurations default. When I try to start it the exception is thrown. Here is full stack trace:

 /home/glassfish/glassfish/bin/asadmin start-domain domain1

   Detected server admin port: 4848
   Detected server http port: 8080
[2014-11-14 03:09:49,839] Artifact ss-ear:ear: Server is no connected.Deploy     is not available.
[2014-11-14 03:09:49,839] Artifact ss-ear:ear exploded: Server is not connected.  Deploy is not available.

java.nio.file.AccessDeniedException: /home/glassfish/glassfish/domains/domain1/logs/server.log.lck
at sun.nio.fs.UnixException.translateToIOException(UnixException.java:84)
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102)
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107)
at sun.nio.fs.UnixFileSystemProvider.newFileChannel(UnixFileSystemProvider.java:177)
at java.nio.channels.FileChannel.open(FileChannel.java:287)
at java.nio.channels.FileChannel.open(FileChannel.java:335)
at java.util.logging.FileHandler.openFiles(FileHandler.java:438)
at java.util.logging.FileHandler.<init>(FileHandler.java:318)
at com.sun.enterprise.admin.launcher.GFLauncherLogger.addLogFileHandler(GFLauncherLogger.java:99)
at com.sun.enterprise.admin.launcher.GFLauncher.setup(GFLauncher.java:192)
at com.sun.enterprise.admin.servermgmt.cli.StartDomainCommand.createLauncher(StartDomainCommand.java:228)
at com.sun.enterprise.admin.servermgmt.cli.StartDomainCommand.executeCommand(StartDomainCommand.java:124)
at com.sun.enterprise.admin.cli.CLICommand.execute(CLICommand.java:322)
at com.sun.enterprise.admin.cli.AdminMain.executeCommand(AdminMain.java:366)
at com.sun.enterprise.admin.cli.AdminMain.doMain(AdminMain.java:300)
at org.glassfish.admin.cli.AsadminMain.main(AsadminMain.java:56)

 Waiting for domain1 to start .Error starting domain domain1.
 The server exited prematurely with exit code 1.
 Command start-domain failed.
 Before it died, it produced the following output:

 Listening for transport dt_socket at address: 9009
 Launching GlassFish on Felix platform
 Exception in thread "main" java.lang.RuntimeException: the domain directory is not writable.
at  com.sun.enterprise.glassfish.bootstrap.MainHelper.verifyDomainRoot(MainHelper.java:246)
at   com.sun.enterprise.glassfish.bootstrap.MainHelper.findInstanceRoot(MainHelper.java:349)
at com.sun.enterprise.glassfish.bootstrap.GlassFishMain.main(GlassFishMain.java:78)
at com.sun.enterprise.glassfish.bootstrap.ASMain.main(ASMain.java:54)

I'm using Ubuntu OS 14.04 LTS, java-1.7.0-openjdk-amd64. Glassfish installed in /home/glassfish, asadmin script have 777 permissions. Server starts when i run it from terminal, but not from IDE.

Please help, it makes me mad!

解决方案

Have you tried to start IntelliJ with sudo permission and start the server within the ide?

这篇关于IDEA无法启动本地glassfish服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆