ImageVerifierCode 换一换
格式:DOCX , 页数:7 ,大小:19.31KB ,
资源ID:2417858      下载积分:3 金币
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.bdocx.com/down/2417858.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录   QQ登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(WAS宕机常见问题及参考解决方案.docx)为本站会员(b****1)主动上传,冰豆网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知冰豆网(发送邮件至service@bdocx.com或直接QQ联系客服),我们立即给予删除!

WAS宕机常见问题及参考解决方案.docx

1、WAS宕机常见问题及参考解决方案WAS宕机常见问题及参考解决方案WAS宕机问题总结起来有以下几类: 一、线程挂起导致线程池满(Thread Hang): Hangs refer to the JVM locking up or refusing to respond. A hang can occur when: 1)Your application entered an wait leak 2)Excessive Synchronization cause performance problems 3)A deadlock has occurred 收集日志:生成JAVA CORE 分析工具

2、:IBM Thread and Monitor Dump Analyzer 1、线程等待泄漏(Wait Leaks) 常见的情况就是,有很多线程使用wait()方法,等待被唤醒notify()。但是,存在某一个线程获取到锁并且进行业务处理完成后,忘记去唤醒等待执行的进程。这样导致的等待泄漏,从而线程挂起。 When you use the wait/notify mechanism, you typically have one or more threads blocked in the wait() call, waiting to be notified. The notifying t

3、hread is supposed to call notify() or notifyAll() to signal that waiting threads can wake up and carry on processing. A problmatic situation could occur that the notify() call is invoked before the threads go into the wait() method. In this case, the waiting threads would not be notified anymore and

4、 become stuck. So, do not forget to notify the waiting theads in you application and maks sure that the Notify action is performed after all the waiting threads are started. 应对策略:notify必须发生在所有wait之前。 2、同步过度(Excessive Synchronization) LIS系统FORMULA ONE报表打印就是采用了SYNCHRONIZE思想,如果有某一个大的报表长时间打不出来的话,会导致其它所有

5、的报表打印线程全部挂起。 Synchronization is required for protecting some critical resources, but if large sections of code are synchronized, an application effectively will become single threaded, and the throughput will decrease dramatically. To improve the performance, you should think about: 1) Use other eff

6、icient algorithm to replace the monitor/lock? 2) Try to keep the monitor lock for a short time? 3) Reduce the number of threads using this monitor/lock? 应对策略:改变程序实现算法,避免占用锁时间过长。比如设置多个锁或者提高同步代码块的执行效率。 3、资源抢占死锁(Dead Lock) 线程运行需要获取到两个资源,当线程1获取到资源A,线程2获取到资源B,此时,线程1需要再获取资源B,线程2需要再获取资源A。这就形成了资源循环申请的一个死锁。其

7、它想获取到资源A或者资源B的线程必将都会挂起。 In this case, a thread acquires the lock on lock1, At the same time, another thread acquires the lock on lock2. so the threads are deadlocked: neither thread will give up its lock until it acquires the other lock, but neither will be able to acquire the other lock until the o

8、ther thread gives it up. One of the best ways to prevent the potential for deadlock is to avoid acquiring more than one lock at a time, which is often practical. However, if that is not possible, you need a strategy that ensures you acquire multiple locks in a consistent, defined order. 应对策略:申请资源锁,按

9、顺序申请,或者一次性全部申请。 二、CPU使用率高(High CPU Usage): High CPU usage problem refer to that a system is performing poorly because of lack of CPU resources. A high CPU usage problem can occur when: 1)Some threads consuming a lot of CUP resources 2)A frequent GC probelm occurs 1、程序自身耗用高CPU(比如:Infinite Loop) 收集日志:

10、生成JAVA CORE 分析工具:操作系统监控工具(比如TOPAS PS之类的) IBM Thread and Monitor Dump Analyzer 应对策略:调整程序,改变算法,使得最终耗用较少CPU资源。 2、频繁垃圾回收(Frequent GC) 多次循环,去申请很多的小对象。从而需要垃圾回收器去频繁释放很小的内存空间。 It is recommended that users enable the VerobseGC first and the Pmat or GCVM will be helpful to find out the frequent GC. Heap dump

11、tells you the objects info of java heap when it is triggered. You can use Heap dumps to debug the java heap issues. You can press the Tool - Generate Dump menu to triger a heap dump which will show objects information. 收集日志:打开详细垃圾回收,生成HEAP DUMP 分析工具:(IBM Support Assistant)Memory Dump Diagnostic for

12、Java (MDD4J) 应对策略:调整垃圾回收策略,或者改变算法,调整程序,把很多局部变量(小对象)全局化。 三、内存溢出(Out Of Memory): The JVM maintains two memory areas, the Java heap, and the native (or system) heap. These two heaps have different purposes, are maintained by different mechanisms, and are largely independent of each other. OutOfMemory c

13、ondition that occurs could be due to either running out of Java heap or Native heap. 1、本地内存溢出(Native OOM) 收集日志:生成系统宕机日志(system dump) OS monitor tools, such as Svmon, top,vmstat and so on 分析工具:(IBM Support Assistant)Dump Analyzer 应对策略:暂时无。 2、finalize执行时间过长(Blocked in Finalize) 程序员自己写finalize的处理代码,导致执

14、行时间过长,从而影响JVM的高效垃圾回收处理策略。最终内存被占满。 The Java service team recommends that applications avoid the use of finalizers if possible. The JVM specification states that finalizers are for emergency clear-up of, for example, hardware resources. The service team recommends that you use finalizers for this purp

15、ose only. Do not use them to clean up Java software resources or for closedown processing of transactions. Because it will affect the garbage collection, and may cause a memory problem. Finalizers are an expensive use of computer resources and they are not dependable. The Java service team does not

16、recommend that you use finalizers for process control or for tidying Java resources. In fact, use finalizers as little as possible. For tidying Java resources, consider the use of a cleanup routine. When you have finished with an object, call the routine to null out all references, deregister listeners, clear out hash tables, and other cleanup operat

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1