从 Eclipse 启动 JBoss
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/298312/
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
Starting JBoss from Eclipse
提问by
Staring JBoss server from within Eclipse Ganymede gives me the following problem: "Server JBoss v4.0 at localhost was unable to start within 120 seconds. If the server requires more time, try increasing the timeout in the server editor."
从 Eclipse Ganymede 中盯着 JBoss 服务器给我以下问题:“本地主机上的服务器 JBoss v4.0 无法在 120 秒内启动。如果服务器需要更多时间,请尝试在服务器编辑器中增加超时。”
The console shows JBoss has started in so and so minutes but soon after, there is a pop up if the above message. I can also start the JBoss externally.
控制台显示 JBoss 已在某某分钟内启动,但不久之后,如果出现上述消息,则会弹出一个窗口。我也可以从外部启动 JBoss。
回答by Romain Linsolas
I had a similar problem, but it was with a Tomcat 5.5 server. The startup time was quite important, so I got this error.
我有一个类似的问题,但它与 Tomcat 5.5 服务器有关。启动时间很重要,所以我得到了这个错误。
To solve this problem, I did that steps: In Preferences, Server, I changed the property "Server timeout delay" to "Unlimited".
为了解决这个问题,我做了以下步骤:在首选项,服务器中,我将属性“服务器超时延迟”更改为“无限制”。
Edit:
编辑:
For Eclipse Ganymede, you must do that: In the server view, double-click on your server JBoss. In the overview, you have a "Timeouts" panel (by default, it is collapsed). You can define the timeouts for server start and stop operations.
对于 Eclipse Ganymede,您必须这样做: 在服务器视图中,双击您的服务器 JBoss。在概览中,您有一个“超时”面板(默认情况下,它是折叠的)。您可以定义服务器启动和停止操作的超时时间。
回答by Aboubacar Toure
I had a similar problem. It turned out that Eclipse's server default port was set to 8080
while my JBoss was working from 8180
.
我有一个类似的问题。事实证明,8080
当我的 JBoss 从8180
.
By changing the server's configuration in Eclipse (double-click on the server and edit server property), it worked.
通过在 Eclipse 中更改服务器的配置(双击服务器并编辑服务器属性),它起作用了。
回答by Aboubacar Toure
Increasing the timeout doesn't solve the problem. Eclipse never recognizes that the server has started (not sure if that's a big deal), just irritated me. I had this problem for weeks and finally figured out that (at least for me) the host name and address had to be identical. I had hostname:localhost; address"127.0.0.1" and it would not work. I changed both to 127.0.0.1 and voila!
增加超时并不能解决问题。Eclipse 从来没有意识到服务器已经启动(不确定这是否是一个大问题),只是让我很恼火。我遇到了这个问题数周,最后发现(至少对我而言)主机名和地址必须相同。我有主机名:localhost; 地址“127.0.0.1”,它不起作用。我都改成了 127.0.0.1,瞧!
Like this:
像这样:
回答by Aboubacar Toure
In my Eclipse with Jboss Tools, that ocurred too, I change the "Host name", on General information of JbossServer, from my machine name to 127.0.0.1.
在我使用 Jboss Tools 的 Eclipse 中,也发生了这种情况,我将 JbossServer 常规信息中的“主机名”从我的机器名更改为 127.0.0.1。
Thanks, this works fine!
谢谢,这工作正常!
回答by Miroslav Berani?
You have to change ports defined in JBoss configuration panel. I have used -Djboss.service.binding.set=ports-01
to upgrade port numbers - and forgot to change Eclipse/JBoss configuration - and Eclipse failed to notice JBoss is already running.
您必须更改 JBoss 配置面板中定义的端口。我曾经使用过 -Djboss.service.binding.set=ports-01
升级端口号 - 忘记更改 Eclipse/JBoss 配置 - Eclipse 没有注意到 JBoss 已经在运行。
回答by valkyrior
Try the following:-
尝试以下操作:-
- Check if the port jboss configured correctly in the general information. It is usually 8080 unless you've changed it.
- I use the hostname as 0.0.0.0 so that it can be accessed from other computers on the network.
- I had a problem where I was connected to a vpn and it was causing this issue. Shut off any vpn connections.
- 检查通用信息中的端口 jboss 是否配置正确。它通常是 8080,除非你改变了它。
- 我将主机名用作 0.0.0.0,以便可以从网络上的其他计算机访问它。
- 我在连接到 vpn 时遇到了问题,这导致了这个问题。关闭任何 VPN 连接。
回答by skiphoppy
I've seen this behavior when I've changed JBoss to run via SSL on port 8443 instead of unencrypted on port 8080. It is my theory that the Eclipse plugin is checking on port 8080 to confirm that JBoss has started, and that this check is hardcoded and does not respect changes you make to the configuration to specify that the server runs on a different port.
当我将 JBoss 更改为在端口 8443 上通过 SSL 运行而不是在端口 8080 上未加密时,我已经看到了这种行为。我的理论是 Eclipse 插件正在检查端口 8080 以确认 JBoss 已启动,并且此检查是硬编码的,不尊重您对配置所做的更改,以指定服务器在不同的端口上运行。
Our workaround is to start JBoss from the debug pulldown menu, which apparently disables the timeout.
我们的解决方法是从调试下拉菜单启动 JBoss,这显然会禁用超时。
回答by Plink
I had the same issue and corrected it by modifying a "server.xml" file in the jboss folders.
我遇到了同样的问题,并通过修改 jboss 文件夹中的“server.xml”文件来纠正它。
I modified '<Connector port="8080"' by '<Connector port="server port defined in Eclipse"'
回答by Shrikant
Yes I had similar problem Jboss could not start from Eclipse Galileo within default 50 secs so just changed server startup time by double clicking Jboss server icon in Server window near console & error log (NOT at windows->preferences->server). It opens server editor and then increased the start up time to 300 It worked then. !!!
是的,我遇到了类似的问题 Jboss 无法在默认的 50 秒内从 Eclipse Galileo 启动,因此只需通过双击控制台和错误日志附近的服务器窗口中的 Jboss 服务器图标来更改服务器启动时间(不是在 windows->preferences->server)。它打开服务器编辑器,然后将启动时间增加到 300,然后就可以工作了。!!!
回答by Chucky
I've come upon the same problem and found the explanation. For Eclipse, JBoss is expected to support the jboss-web service (tomcat.sar) which implies an HTTP port to be opened at the end of the process. In my case, as this service is disabled, no HTTP port is opened when the server is running...
我遇到了同样的问题并找到了解释。对于 Eclipse,JBoss 预计支持 jboss-web 服务 (tomcat.sar),这意味着在进程结束时打开一个 HTTP 端口。就我而言,由于此服务已禁用,因此服务器运行时不会打开任何 HTTP 端口...
Solution: simply double click on the jboss server in the Servers panel and copy the JNDI port to the Port field, in Server Properties section. This makes it.
解决方案:只需在服务器面板中双击 jboss 服务器,然后将 JNDI 端口复制到服务器属性部分中的端口字段。这使它。
This way, it is no more necessary to change host name to 127.0.0.1, you may let it be what you want (e.g. localhost is the default).
这样,就不再需要将主机名更改为 127.0.0.1,您可以随心所欲(例如 localhost 是默认值)。