Java Netbeans 无法启动 Glassfish 4 服务器

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/21328561/
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

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-13 08:05:00  来源:igfitidea点击:

Netbeans can't start Glassfish 4 server

javajakarta-eenetbeansglassfish

提问by Salih Erikci

I am using Netbeans 7.4 and Glassfish 4.0. I can start glassfish 4.0 manually from command line but when i click the run the project button from netbeans it says "Starting GlassFish Server". It became more than 10 minutes but nothing happens. It was running fine yesterday, i didn't change anything but today it can't start the server.

我使用的是 Netbeans 7.4 和 Glassfish 4.0。我可以从命令行手动启动 glassfish 4.0,但是当我从 netbeans 单击运行项目按钮时,它显示“正在启动 GlassFish Server”。它变成了 10 多分钟,但没有任何反应。昨天它运行良好,我没有改变任何东西,但今天它无法启动服务器。

What may be the problem?

可能是什么问题?

enter image description here

在此处输入图片说明

回答by salihcenap

This problem stems in your locale settings but the solution is pretty simple:

这个问题源于您的语言环境设置,但解决方案非常简单:

In Netbeans installation directory find netbeans/etc/netbeans.conf file. Open & Edit the file using a text editor. Locate *"netbeans_default_options="*in the file and add --locale ento the end of options. For example mine looks like:

在 Netbeans 安装目录中找到netbeans/etc/netbeans.conf file. 使用文本编辑器打开和编辑文件。在文件中找到*"netbeans_default_options="*并添加--locale en到选项的末尾。例如我的看起来像:

netbeans_default_options="-J-client -J-Xss2m -J-Xms32m -J-XX:PermSize=32m -J-Dapple.laf.useScreenMenuBar=true -J-Dapple.awt.graphics.UseQuartz=true -J-Dsun.java2d.noddraw=true -J-Dsun.java2d.dpiaware=true -J-Dsun.zip.disableMemoryMapping=true --locale en"

Now restart Netbeans. If you are still having the same problem, delete and recreate your glassfish domain and it will work.

现在重新启动 Netbeans。如果您仍然遇到同样的问题,请删除并重新创建您的 glassfish 域,它会起作用。