首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >通过SOAP对DMGR执行wsadmin脚本超时

通过SOAP对DMGR执行wsadmin脚本超时
EN

Stack Overflow用户
提问于 2016-06-30 11:06:08
回答 3查看 2.4K关注 0票数 0

我尝试通过wsadmin控制台在单个JVM上启动和停止应用程序,因为IBM BPM PS Adv.的Web UI不允许这种操作。因此,我有以下脚本:

https://gist.github.com/predatorian3/b8661c949617727630152cbe04f78d7e

当我对来自Cell Host的DMGR运行它时,我收到以下错误。

代码语言:javascript
复制
[wasadmin@server01 ~]$ cat /usr/local/bin/Run_wsadmin.sh
#!/bin/bash
#
#
#

/opt/IBM/WebSphere/AppServer/bin/wsadmin.sh -lang jython -user serviceAccount -password password $*

[wasadmin@cessoapscrt00 ~]$ time Run_wsadmin.sh -f /opt/IBM/wsadmin/wsadmin_Restart_Application.py WPS00 CRT00WPS01 redirectResource_war
WASX7209I: Connected to process "dmgr" on node CRTDMGR using SOAP connector;  The type of process is: DeploymentManager
WASX7303I: The following options are passed to the scripting environment and are available as arguments that are stored in the argv variable: "[WPS00, CRT00WPS01, redirectResource_war]"
WASX7017E: Exception received while running file "/opt/IBM/wsadmin/wsadmin_Restart_Application.py"; exception information: com.ibm.websphere.management.exception.ConnectorException
org.apache.soap.SOAPException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Read timed out; targetException=java.net.SocketTimeoutException: Read timed out]


real    3m21.275s
user    0m17.411s
sys     0m0.796s

因此,我没有指定连接类型,而是使用缺省值,即SOAP。然而,在reading about the other Connection Types上,它们似乎都没有改善,但我将其归因于IBM文档的模糊性。是否有增加超时等待时间或关闭超时等待时间的选项,或者是否有更好的连接类型?

同样直接在wsadmin控制台上运行,它似乎在收集应用程序管理器字符串时挂起。

代码语言:javascript
复制
[wasadmin@server01 ~]$ Run_wsadmin.sh
WASX7209I: Connected to process "dmgr" on node CRTDMGR using SOAP connector;  The type of process is: DeploymentManager WASX7031I: For help, enter: "print Help.help()"
wsadmin>appManager = AdminControl.queryNames('cell=CRTCELL,node=WPS00,type=ApplicatoinManager,process=CRT00WPS01,*')
WASX7015E: Exception running command: "appManager = AdminControl.queryNames('cell=CRTCELL,node=WPS00,type=ApplicationManager,process=CRT00WPS01,*')"; exception information:
 com.ibm.websphere.management.exception.ConnectorException
org.apache.soap.SOAPException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Read timed out; targetException=java.net.SocketTimeoutException: Read timed out]

wsadmin>
EN

回答 3

Stack Overflow用户

发布于 2016-06-30 14:50:51

您可以在{profile}/properties/soap.client.props中增加超时值

代码语言:javascript
复制
com.ibm.SOAP.requestTimeout=180
票数 0
EN

Stack Overflow用户

发布于 2016-06-30 21:14:43

如果您想关闭超时,请修改com.ibm.SOAP.requestTimeout=0,或者如果您想要更长的超时,可以将值180修改为其他值。另外,关于您的查询命令,我注意到您的MBean类型有一个拼写错误,您有type=ApplicatoinManager,它应该是type=ApplicationManager

票数 0
EN

Stack Overflow用户

发布于 2017-02-17 00:44:03

给你--我也有同样的问题。我想暂时覆盖超时属性。这就像冠军一样工作。我犯了一些错误,但道具没有通过,我想出来了,它起作用了。

从/properties复制soap.client.props文件,并为其指定一个新名称,如mysoap.client.props。根据需要编辑mysoap.client.props并更新wsadmin的值创建一个新的com.ibm.SOAP.requestTimeout属性文件soap_override.props并输入以下行: wsadmin使用-p选项将soap_override.props传递给wsadmin:wsadmin -p soap_override.props...

参考:https://www.ibm.com/developerworks/community/blogs/timdp/entry/avoiding_wsadmin_request_timeouts_the_neat_way32?lang=en

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/38113325

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档