当前位置:文档之家› weblogic压力测试中的性能调试手册

weblogic压力测试中的性能调试手册

1.1.1Oracle数据库设置1.【PGA】24-》602.【SGA】shared_pool_size=48,803.【SGA】高速缓存区:24,404.【SGA】java池:30-》0(8)5.会话150-》1000.6.游标300-》1000.1.1.2Jar包设置:1、Log4j删除日志,加“#”2、DynamicDao删除system.Out SQL1.1.3Weblogic设置1.1.3.1 内存大小setDomainEnv.cmdif "%JAVA_VENDOR%"=="Sun" (set WLS_MEM_ARGS_64BIT=-Xms256m -Xmx512mset WLS_MEM_ARGS_32BIT=-Xms256m -Xmx1524m 1.1.3.2 域JTA 配置超时秒数:360事务超时数1001.1.3.2.1服务器上资源的最大请求数(每个服务器所允许的最大并发资源请求数500)事务超时数100服务器:接受预备连接:6001.1.3.3 域Web应用程序设置1.1.3.4 J DBC连接池域-》服务-》JDBC——》数据源连接池1、语句缓存大小1002、不支持全局事务3、初始容量:54、最大容量:100(已经修改为500)5、容量增长:56、收缩频率:4507、语句超时:10008、非活动连接超时1001.1.3.5 部署监视部署-》监视-》JDBC1.1.3.6 S ervers连接池配置服务-》JDBC-》数据源-》配置-》连接缓冲池1.1.3.7 S erver管理控制服务器-》AdminServer(管理)-》控制服务器-》AdminServer(管理)1.1.3.8 J ava虚拟机内存回收服务器-》AdminServer(管理)-》选中-》监视-》性能-》垃圾回收内存(Java 虚拟机内存利用率统计信息)1.1.3.9 监视JDBC1.1.3.10 监视JTA1.1.3.11 服务器参数调整(接受预备连接:600)服务器-》AdminServer(管理)-》选中-》调整1.1.3.12 最长线程阻塞时间服务器-》AdminServer(管理)-》选中-》超载1.1.3.13 BEA-000449 Closing socket as no data read from it1、Set the parameter -Dweblogic.client.socket.ConnectTimeout=XXX, in the start-up script of the server which you are seeing this issue under JAVA_OPTIONSNote: Where "XXX" is the value in ms.Example:-Dweblogic.client.socket.ConnectTimeout=5002、Server -> Protocols (tab) -> HTTP (sub-tab) -> Duration(持续时间)1.1.3.14 BEA-310003 Free memory in the server... There isdanger of OutOfMemoryErrorThanks for the Hint.I found that changing the "Low Memory Sample Size" from "10" to "120" solved my problem.When WebLogic uses JRockit, it know when the GC runs and cleans up memory. It samples the free heap at this time (because all of the garbage has been collected and memory is as empty as it is going to get) and if the average over the hour is < 5% free, then you get an alert.Unfortunately I'm using the IBM AIX JVM. WebLogic can't tell when IBM's JVM is doing a GC, so it just samples heap free at a regular intervals. Since there are only 10 samples (by default) in a hour, if it gets unlucky a few times you will get an out of memory alert when there is nothing to be worried about.I boosted the samples to 120/hour, so it gets a better picture of the amount of heap that is free on average. Now that a few bad samples can't drag the value over the 5% limit, I am much less likely to get an alert.The navigation path in WebLogic 10.3 to Low Memory Sample Size is:Environment -> Servers -> "the server you wish to change" -> Configuration -> Tuning After making the change you have to restart the server.It also a good idea to check that the change worked (I lost my change during the restart somehow the 1st time I did it).1.1.3.15 [转1]常用weblogic性能调优方法常用weblogic性能调优方法 (2007-05-22 12:23:57)1.设置最大线程(并发)数量myserver|Configuration|Monitoring|performance可以观察整体性能Idle Threads数量少,Queue Length比较大说明存在多并发,而且CPU资源比较空闲需要增加线程数量,具体方法myserver|Configuration|Monitoring|performance|GeneralMonitor all Active Queues... 调整当前Thread Count个数,一般量大得可以设置到100。

【备注版本9.0:weblogic.kernel.default其实是一个weblogic的核心参数,设置的值就是weblogic用来响应客户端请求的线程数量。

也就是说,一个用户登陆应用系统进行某操作,则WebLogic将从weblogic.kernel.default中分配一个线程给该用户。

默认情况下,这个参数值是40。

比如对大的企业应用,同一时间登陆操作系统的用户非常多,则40个线程就显得太少了。

同时,如果你的应用程序设计得不好,造成很多操作速度非常慢,因为WebLogic 要等待你一个操作完成之后,才进行线程的回收处理,如果同一时间有很多线程在执行非常慢的操作,这也会引起线程数量不够的问题。

具体的表现就是在WebLogic的控制台的myserver中的Monitoring页面下的Performance 页面中,Queue Length显示不是等于0,图像可能是一个曲线。

Queue Length这个参数的意义就是“在等待队列里的请求数”。

正常情况下,应该是0,图像是一个水平的横线。

也就是没有客户端的请求会等待,都能及时的得到系统的处理。

如果确认是因为用户过多的原因需要增大weblogic.kernel.default参数的值,我们怎么修改?进入WebLogic控制台——左边窗口的mydomain——servers——点击myserver——Configuration——General——点击Advanced Options的Show链接——最下面的Configure Execute Queues 链接——weblogic.kernel.Default链接——Thread Count参数。

的却是隐藏的比较深。

修改Thread Count的值,然后重启WebLogic就可以生效了。

】【备注版本10.0:根据客户的要求,我们在webblogic10上测试wicket框架的性能。

需要设置并发线程数设置。

根据网上资料,需要在config.xml的server部分配置修改,如下:<server><name>AdminServer</name><execute-queue><name>default</name><thread-count>200</thread-count><threads-maximum>400</threads-maximum></execute-queue><use81-style-execute-queues>true</use81-style-execute-queues><listen-address></listen-address></server>请不要画蛇添足,否则,webapplications跑不起来的,配置execute-queue的基本属性就行了。

我中途也吃过这个亏。

】2.设置内存在启动脚本中 set MEM_ARGS=-Xms512m -Xmx1000m 即最小内存和最大内存.不宜太小也不宜太大3.最大socket连接数(出现connection refused可以增加次数量)myserver|Configuration|Tuning |Accept Backlog一般比Thread Count稍微大一点4.连接池得最大最小格式设置成相同,并且不少于50个(一般和Thread Count差不多).5.x86PcSvr环境下采用jrockit(BEA专门针对x86做了性能优化得JDK)性能有显著提高20%.以下假设d:\bea\jrockit81sp1_141_03是jrockit的路径。

相关主题