配置jboss EAP 6.4 数据库连接超时时间
Environment
- Red Hat JBoss Enterprise Application Platform (EAP)
- 6.x
- 7.x
Issue
- Server throws following error while start up :
12:21:13,956 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS013412: Timeout after [300] seconds waiting for service container stability. Operation will roll back. Step that first updated the service container was 'add' at address '[("interface" => "management")]'
There are pretty big applications running on server and it may take 5-6 min to start the servers. So how to set the timeout to 600 or 900 seconds ? Where and how to set it ?
Slave
JBoss EAPinstance won't start when application code takes too long to load.We are coming across this bug mentioned in https://bugzilla.redhat.com/show_bug.cgi?id=1117945 and were wondering if it has been fixed in 6.3.3 or the up-coming 6.4.
When trying to deploy a new version of our application I get the following error. ” Operation timeout awaiting service container stability" typically the application will deploy pretty quick. Now it waits until it times out, What could be causing this problem?
Jboss application server is not able to restart after throwing the below error. We had this issue in of our servers in the past, so had set this property, looks like the server is waiting 600 seconds for the deployment to happen and failing after that. Could you please advice us on what the issue could be, as our QA environment is down at this moment?
02:30:20,757 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS013412: Timeout after [600] seconds waiting for service container stability. Operation will roll back. Step that first updated the service container was 'add' at address '[
("core-service" => "management"),
("management-interface" => "native-interface")
]'
- We run
jbosson a rather underpowered VM for test purposes,sometimes it can take a long time to start, and then times out.Is it possible to extend the timeout? - Unable to deploy WAR file on AWS VM
- When we start the JBOSSEAP6 windows service, the deployment produces a ".failed" file in the deployments folder, rather than a ".deployment" file. This is a newly-created AWS EC2 Windows Server 2012 R@ instance - a test environment for now and issue comes every time we try to start the JBoss service.
Resolution
In EAP 7.x and EAP 6.3.0 or later, you can configure jboss.as.management.blocking.timeout system property to tune timeout (seconds) waiting for service container stability.
For standalone mode :
Use following CLI command to set
jboss.as.management.blocking.timeout. For example:/system-property=jboss.as.management.blocking.timeout:add(value=600)
the above will set
jboss.as.management.blocking.timeoutsystem property in configuration file (i.estandalone-*.xml) like :...
</extensions>
<system-properties>
<property name="jboss.as.management.blocking.timeout" value="600"/>
</system-properties>
<management>
...
or
Add
-Djboss.as.management.blocking.timeout=600to jvm argument ofstandalone.shor add the following JAVA_OPTS instandalone.conf:JAVA_OPTS="$JAVA_OPTS -Djboss.as.management.blocking.timeout=600"
For domain mode :
- Edit the $JBOSS_HOME/bin/domain.conf and set it via this line
-Djboss.as.management.blocking.timeout=600after the if block:
...
#
# Specify options to pass to the Java VM.
#
if [ "x$JAVA_OPTS" = "x" ]; then
JAVA_OPTS="-Xms64m -Xmx512m -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true"
JAVA_OPTS="$JAVA_OPTS -Djboss.modules.system.pkgs=$JBOSS_MODULES_SYSTEM_PKGS -Djava.awt.headless=true"
else
echo "JAVA_OPTS already set in environment; overriding default settings with values: $JAVA_OPTS"
fi
JAVA_OPTS="$JAVA_OPTS -Djboss.as.management.blocking.timeout=600"
...
Note: The only use case for setting a property at the server-group or individual domain server level would be if you wanted a lower timeout than what you configure on the host controllers.
Root Cause
- In EAP 6.3.0.ER8 there is a new class in
jboss.as.controller: BlockingTimeout. This class loads the value of system propertyjboss.as.management.blocking.timeoutor defaults to 300 (seconds). Note: This property is not a timeout per deployment but a timeout on container stability and ifjboss.as.management.blocking.timeoutis reached during startup then all applications will be undeployed and the container shutdown. The reasoning behind this is that having a half-working server is potentially dangerous as you may not notice major failures.
Diagnostic Steps
- Confirm whether a virus scanner is installed to the server
- If the issue was caused after making changes in application, check what exactly has changed since it was working previously? Was something upgraded? Added? Pointing to a new database or other external system?
- Collect a series of thread dumps during your startup period so we can see what it might be getting stuck on.
- Make sure to add the setting to the domain.conf on the Domain controller and Slave Host controller
Once you collect we can analyse them and to see whether there is some sort of deadlock or resource that your threads are waiting on that's preventing them from completing the deployment etc.
Symptoms
When starting JBoss, the following error is printed in application server log:
ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS013412: Timeout after [300] seconds waiting for service container stability. Operation will roll back. Step that first updated the service container was 'add' at address '[
("core-service" => "management"),
("management-interface" => "native-interface")
]'
JBoss then fails to deploy.
Cause
This error message is printed out when the management-native socket defined in standalone.xml located in <JBOSS_HOME>/standalone/configuration takes longer than the configured timeout value to load. By default, this value is set to 300 seconds.
Action
Open standalone.conf (Unix) or standalone.conf.bat (Windows) located in
<JBOSS_HOME>/binand verify the following timeout value is large enough:JAVA_OPTS="$JAVA_OPTS -Djboss.as.management.blocking.timeout=3600"
Open standalone.xml and modify the
default-timeoutproperty in thecoordinator-environmentelement to a larger value (e.g., 1000):<coordinator-environment default-timeout="..."/>
Note: In case the changes are not applied, clear the JBoss cache by deleting the following folders:
<JBOSS_HOME>/standalone/data<JBOSS_HOME>/standalone/tmp
Affected Versions
This article applies to all versions of Appian using JBoss as an application server.
Last Reviewed: February 2017
配置jboss EAP 6.4 数据库连接超时时间的更多相关文章
- 动态配置 JBOSS ( eap 6.2 ) 数据源
操作环境 windows + jboss eap 6.2 + MyEclipse 10.0 项目用的是jboss eap 6.2,作为Red公司升级后的eap稳定版. 相比之前的 AS 系列,不管是安 ...
- 使用mod_cluster进行apache httpd server和jboss eap 6.1集群配置
本文简单介绍,使用mod_cluster进行apache httpd server和jboss eap 6.1集群配置.本配置在windows上测试通过,linux下应该是一样的.可能要稍作调整.后面 ...
- CAS (8) —— Mac下配置CAS到JBoss EAP 6.4(6.x)的Standalone模式(服务端)
CAS (8) -- Mac下配置CAS到JBoss EAP 6.4(6.x)的Standalone模式(服务端) jboss版本: jboss-eap-6.4-CVE-2015-7501 jdk版本 ...
- 【Spring Cloud 源码解读】之 【如何配置好OpenFeign的各种超时时间!】
关于Feign的超时详解: 在Spring Cloud微服务架构中,大部分公司都是利用Open Feign进行服务间的调用,而比较简单的业务使用默认配置是不会有多大问题的,但是如果是业务比较复杂,服务 ...
- springcloud之Feign、ribbon设置超时时间和重试机制的总结
一 超时时间配置 如果在一个微服务当中对同一个接口同时配置了Hystrix与ribbon两个超时时间,则在接口调用的时候,两个计时器会同时读秒. 比如,访问一个接口需要2秒,你的ribbon配置的超时 ...
- config文件中可以配置查询超时时间
web.config配置数据库连接 第一种:获取连接字符串 首先要定义命名空间 system.configuration 1. string connstr= string constr = Con ...
- jboss eap 6.3 集群(cluster)配置
接上一篇继续,Domain模式解决了统一管理多台jboss的问题,今天我们来学习如何利用mod_cluster来实现负载均衡.容错. mod_cluster是jboss的一个开源集群模块(基于apac ...
- jboss eap 6.3 域(Domain)模式配置
jboss提供了二种运行模式:standalone(独立运行模式).domain(域模式),日常开发中,使用standalone模式足已:但生产部署时,一个app,往往是部署在jboss集群环境中的, ...
- GRUB2配置详解:默认启动项,超时时间,隐藏引导菜单,配置文件详解,图形化配置
配置文件详解: /etc/default/grub # 设定默认启动项,推荐使用数字 GRUB_DEFAULT=0 # 注释掉下面这行将会显示引导菜单 #GRUB_HIDDEN_TIMEOUT=0 # ...
随机推荐
- tsung压力测试——安装
在安装之前确保安装了以下工具: erlang 必须要有安装java环境,要不然不成功 yum install gcc yum install gcc-c++ yum install libtool y ...
- WebMagic之爬虫监控
访问我的博客 前言 年前闲着无聊,研究了一阵子爬虫技术,接触到爬虫框架 WebMagic,感觉很好用. 在之后的工作中,接手了新站与第三方接口对接的工作,主要的工作是去抓取对方接口的内容:初始的时候, ...
- [机器学习] 训练集(train set) 验证集(validation set) 测试集(test set)
在有监督(supervise)的机器学习中,数据集常被分成2~3个即: 训练集(train set) 验证集(validation set) 测试集(test set) 一般需要将样本分成独立的三部分 ...
- Spring事务内方法调用自身事务 增强的三种方式
ServiceA.java文件: 查看Spring Tx的相关日志: 可以看到只创建了一个事物ServiceA.service方法的事务,但是callSelf方法却没有被事务增强; 分析原因:Spr ...
- SpringMVC融合Swagger UI使用
相信大家都很熟悉springmvc,在用其进行开发工作的时候,有没有遇到几个小问题?比如: 1.前后端分离的模式下,前端开发人员如何得知后端的开发进度,有哪些接口可用? 2.后端开发人员在测试自己的接 ...
- Java中异常发生时代码执行流程
异常与错误: 异常: 在Java中程序的错误主要是语法错误和语义错误,一个程序在编译和运行时出现的错误我们统一称之为异常,它是VM(虚拟机)通知你的一种方式,通过这种方式,VM让你知道,你(开发人员) ...
- vue实用组件——表格
之前用了一下vue-bootstrap,感觉里面的表格组件特别好用,但是如果仅仅为了使用表格就引入bootstrap,似乎有点不划算.所以自己就试着实现了一下bootstrap里面表格的部分功能,目前 ...
- 亲身实践 yui-compressor压缩js和css
最近很懒散,个人感情.家庭原因,没有动力去学东西,老是发誓要搞好前端工程化,老中断,唉!没有魄力! 最近老觉得这前端工程化有什么好的,东西那么多,还得学!直到前几天产品提了个优化,说搜索结果页跳商品详 ...
- MFC函数—CWinApp::LoadStdProfileSettings
从 InitInstance 成员函数内调用该函数,启用和加载最近使用的(MRU)文件和最后浏览状态的列表.void LoadStdProfileSettings( UINT nMaxMRU = ...
- SSH:Hibernate框架(七种关联关系映射及配置详解)
概念 基本映射是对一个实体进行映射,关联映射就是处理多个实体之间的关系,将关联关系映射到数据库中,所谓的关联关系在对象模型中有一个或多个引用. 分类 关联关系分为上述七种,但是由于相互之间有各种关系, ...