无法从Eclipse启动JBoss [英] Cannot start JBoss from Eclipse

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

问题描述

我正在Linux上使用Eclipse和JBoss AS 7.1.1进行开发.我已经安装了JBoss工具,以便可以从Eclipse部署到JBoss.

I'm developing with Eclipse and JBoss AS 7.1.1 on Linux. I've installed the JBoss tools so I can deploy to JBoss from Eclipse.

现在我遇到了问题,JBoss服务器将无法从Eclipse启动(运行/调试).我收到的消息是:Reference to undefined variable PATH.

Now I've got a problem, the JBoss server won't start (run/debug) from Eclipse. The message I get is: Reference to undefined variable PATH.

这对我完全没有意义.服务器日志中没有任何内容,当我从控制台运行eclipse时,唯一的输出是:

This is not making sense to me at all. There is nothing in the server logs and when I run eclipse from console the only output is:

Jul 12, 2012 1:38:55 PM org.xnio.Xnio <clinit>
INFO: XNIO Version 3.0.3.GA
Jul 12, 2012 1:38:56 PM org.xnio.nio.NioXnio <clinit>
INFO: XNIO NIO Implementation Version 3.0.3.GA
Jul 12, 2012 1:38:56 PM org.jboss.remoting3.EndpointImpl <clinit>
INFO: JBoss Remoting version 3.2.3.GA

我认为该错误是在JBoss运行时关闭Eclipse之后发生的.

I think the error occurred after I shut down Eclipse while JBoss was running.

从命令行启动JBoss可以正常工作,eclipse甚至可以通过这种方式连接到它.如果Eclipse连接到JBoss,它可以将其关闭,那么问题就出在服务器的启动上.

Starting JBoss from the command line works without a problem, eclipse can even connect to it that way. If Eclipse is connected to JBoss it can shut it down, so the problem is purely the starting of the server.

我尝试了干净的JBoss安装,但是存在相同的问题.

I've tried with a clean JBoss install, but the same problem exists.

更新:我尝试使用干净的工作空间和干净的配置目录(〜/.eclipse),重新安装了JBoss工具,并遇到了相同的问题.

UPDATE: I've tried using a clean workspace and a clean config directory (~/.eclipse), reinstalled the JBoss tools and experienced the same problem.

推荐答案

我通过重新启动计算机解决了问题.为什么我一开始没有这么做?重新启动后,问题立即显示出来.

I solved my problem by restarting my computer. Why I didn't do so in the first place? The problem showed itself right after a restart.

我尝试了几件事,然后才发现以root身份运行Eclipse时问题不存在.当然,我认为这是一个与权限相关的问题,因此我将/usr/lib/eclipse-3.7/的所有权更改为我的用户.这没有帮助.尝试了所有内容之后,我重新启动了,然后以某种方式完成了窍门.

I tried several things and it was then I discovered that the problem didn't exist when I ran Eclipse as root. Of course I thought this was a permission related problem so I changed ownership of /usr/lib/eclipse-3.7/ to my user. This didn't help. After trying everything I did a restart and this somehow did the trick.

我最近又遇到了这个问题,终于找到了问题所在.问题来自/etc/env.d/中设置的环境变量.其中一个文件违反了以下规则:

I recently had this problem again and I finally tracked down the problem. The problem came from an environment variable that was set in /etc/env.d/. One of the files violated the following rule:

定义其他变量时不能使用外壳变量.这意味着禁止使用FOO ="$ BAR"(其中$ BAR是另一个变量)之类的东西.

You cannot use shell variables when defining other variables. This means things like FOO="$BAR" (where $BAR is another variable) are forbidden.

结果是$PATHPATH环境变量中设置,导致PATH=/usr/bin/:$PATH当然是错误的.

The result was $PATH getting set in the PATH environment variable resulting in PATH=/usr/bin/:$PATH which of course is wrong.

这篇关于无法从Eclipse启动JBoss的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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