我对 Jboss AS 4.2.3 有一个小问题。我正在 Seam 中开发一个应用程序,所以我使用 Jboss 作为服务器。在客户公司中,他们在 Fedora 上安装了 Jboss AS 4.2.3 并配置为服务,因此它在带有 PostgreSQL 的引导计算机上自动启动。因此,如果我运行 chkconfig --list 我可以在这里看到 Jboss 作为一项服务。
但问题是当我尝试使用此命令重新启动、停止或启动此服务(我有 root 权限)时:
service jboss stop/restart
但我不知道会发生什么,看起来它找不到正在运行的 Jboss AS 实例,因为我得到此消息:
JOBSS_CMD_START = cd /opt/java/jboss/bin; /opt/java/jboss/bin/run.sh -c default
No JBossas is currently running
但它正在运行,因为如果我在浏览器上输入 localhost:8080,它会加载 Jboss 页面。公司的服务器管理员也不知道为什么服务无法重新启动或停止或启动,只有我知道他按照本教程安装和配置 JBoss AS:
thewiki4opentech.org/index.php/How_to_install_JBoss_AS_in_CentOS_/RedHat/_Fedora
另外,我尝试了
/etc/init.d/jboss stop
,并且得到了相同的输出。如果我使用
/opt/java/jboss/bin/start.sh -c default
它尝试启动 Jboss AS 的第二个实例,但它会给我错误,因为它试图使用与已启动的 Jboss 实例相同的端口。
这对我来说很困难,因为我正在使用 Teamviewer 进行远程连接,并且我想部署 EAR,但我不能,因为我无法重新启动服务来提取耳朵。因此,如果您知道为什么无法使用 service jboss stop 停止或启动正在运行的 Jboss AS,我想向您寻求帮助。
作为附加信息,我使用配置从其他机器访问 Jboss 应用程序(使用 0.0.0.0),并且服务器具有静态 IP。我的主机文件的配置是这样的:
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
192.168.1.106 entertechserver.localdomain entertechserver
#::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
问候。
i have a little issue with a Jboss AS 4.2.3 . I'm developing an application in Seam so i'm using Jboss as server. In the client company they have a Jboss AS 4.2.3 installed on Fedora and configured as a service, so it starts automatically on boot machine with PostgreSQL. So, if i run chkconfig --list i can see Jboss here as a service.
But the problem is when i try to restart, stop or start this service (i have root permissions) using this command:
service jboss stop/restart
But i don't know what happens that looks like it doesn't find the Jboss AS instance that's running because i get this message:
JOBSS_CMD_START = cd /opt/java/jboss/bin; /opt/java/jboss/bin/run.sh -c default
No JBossas is currently running
But it's running because if i enter localhost:8080 on a browser it loads the Jboss page. The server admin of the company doesn't know also why the service can't restart or stop or start and only i know that he followed this tutorial to install and configure JBoss AS:
thewiki4opentech.org/index.php/How_to_install_JBoss_AS_in_CentOS_/RedHat/_Fedora
Also, i tried with
/etc/init.d/jboss stop
And i get the same output. If i use
/opt/java/jboss/bin/start.sh -c default
It tries to start a second instance of Jboss AS but it gives me errors because is trying to use the same ports as already started Jboss instance.
And it's difficult to me because i'm connecting remotely using Teamviewer and i want to deploy an EAR but i can't because i can't restart the service to extract the ear. So i wanna ask you for help if you know why the Jboss AS that's running can't be stopped or started using service jboss stop.
As aditional info, i'm using the config to access Jboss apps from other machines (using 0.0.0.0) and the server has a static IP. The config of my hosts file is this:
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
192.168.1.106 entertechserver.localdomain entertechserver
#::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
Regards.
发布评论
评论(1)
好吧,我想我找到了答案。服务器管理员将脚本 run.sh 复制到 /etc/init.d/ 但我们看到还有另一个名为 jboss_init_redhat.sh 的脚本,我认为它针对 redhat/fedora 系统进行了优化,因此我们使用此脚本复制到 /etc/ init.d/ 并且它有效!现在,当我停止时,它会给出下一个输出:
实际上,我还没有看到两个脚本之间的区别,但看看会很有趣。
问候。
Well, i think that i found the answer. The server admin copy the script run.sh to /etc/init.d/ but we saw that there's another script named jboss_init_redhat.sh that i think is optimized for redhat/fedora systems, so we used this script to copy to /etc/init.d/ and it works!! Now when i stop it gives me the next output:
Really i haven't seen the difference between both scripts yet but it will be intersting to take a look.
Regards.