GlassFish WAR文件部署到非默认端口 [英] GlassFish WAR file deployment to a non-default port

查看:439
本文介绍了GlassFish WAR文件部署到非默认端口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将部署在RHEL服务器上的GlassFish 3.1.2.2服务器部署一个战争文件(Oracle的APEX监听器)(我也在家里的Ubuntu服务器上看到相同的问题)。

I am attempting to deploy a war file (Oracle's APEX Listener) to a GlassFish 3.1.2.2 server deployed on an RHEL server (I am also seeing the same issues on an Ubuntu server at home).

我使用以下命令创建域:

I used the following command to create the domain:


$ GLASSFISH_HOME / bin / asadmin create-domain --portbase 8100 myDomain

$GLASSFISH_HOME/bin/asadmin create-domain --portbase 8100 myDomain

[我也在同一个GlassFish服务器上创建多个域(一个具有多个域的GF实例)使用值对于portbase值为8200,8300和8400,并使用不同的域名。]

[I am also creating multiple domains on the same GlassFish server (one GF instance with multiple domains) using values of 8200, 8300, and 8400 for the portbase value and using different domain names.]

然后我使用以下方式启动域:

I then start the domain using:


$ GLASSFISH_HOME / bin / asadmin start-domain myDomain

$GLASSFISH_HOME/bin/asadmin start-domain myDomain

接下来,我尝试部署APEX.WAR文件:

Next, I attempt to deploy the APEX.WAR file using:


$ GLASSFISH_HOME / bin / asadmin deploy --contextroot apex apex.war

$GLASSFISH_HOME/bin/asadmin deploy --contextroot apex apex.war

但是,我收到以下错误:

But, I get the following error:


远程服务器不监听[localhost:4848]上的请求。服务器是否启动?无法获取远程命令。最近匹配的本地
命令:
帮助命令部署失败。

我有也使用以下命令,结果相同:

I have also used the following commands with the same result:


$ GLASSFISH_HOME / bin / asadmin deploy apex.war

$ GLASSFISH_HOME / bin / asadmin deploy --target myDomain apex.war

$ GLASSFISH_HOME / bin / asadmin deploy --target domain apex.war

$GLASSFISH_HOME/bin/asadmin deploy apex.war
$GLASSFISH_HOME/bin/asadmin deploy --target myDomain apex.war
$GLASSFISH_HOME/bin/asadmin deploy --target domain apex.war

我每次都收到相同的错误。

And I get the same error each time.

我可以使用admin gui部署文件,但这是为了客户安装,我真的很想从我创建的bash shell脚本中尽可能多地执行。

I can deploy the file using the admin gui, but this is for a customer installation and I would really like to do as much as possible from the bash shell script I have created.

我还在安装Java 1.7.0_45 JDK并修改$ GLASSFISH_HOME / config /asenv.conf文件以包含AS_JAVA =

I am also installing the Java 1.7.0_45 JDK and modifying the $GLASSFISH_HOME/config/asenv.conf file to include AS_JAVA=

错误实际上是正确的,因为管理端口是8148.但是,如何让GlassFish知道使用8148而不是4848。

The error is actually correct because the admin port is 8148. But, how do I get GlassFish to "know" to use 8148 instead of 4848.

我也有tr如下:


$ GLASSFISH_HOME / bin / asadmin create-domain --adminport 8148
--domainproperties http.ssl。 port = 8152

$GLASSFISH_HOME/bin/asadmin create-domain --adminport 8148 --domainproperties http.ssl.port=8152

但这样做与上述相同。

感谢您阅读这篇文章,任何有关如何解决这个问题的信息将不胜感激!

Thanks for reading this tome of a post and any info on how to fix this would be greatly appreciated!

/ dave

推荐答案

我得到相同的错误,你应该这样做:

i get the same error ,you should do like this:

$ GLASSFISH_HOME / bin / asadmin --port 8148部署apex.war

$GLASSFISH_HOME/bin/asadmin --port 8148 deploy apex.war

并输入用户名和密码,默认用户为admin,密码为adminadmin

and input username and password the default user is admin and password is adminadmin

祝你好运给你!

这篇关于GlassFish WAR文件部署到非默认端口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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