Ticket #118 (new 故障) — at Initial Version
jsp编译内存不够问题
| Reported by: | chenchongqi | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Component: | 报价库 | Version: | 报价库5.0 |
| Keywords: | JavaCompileException,Cannot allocate memory | Cc: | |
| Due Date: |
Description
现象
8.27报价库前台更新jsp的时候,237.45这台虚拟报编译错误:
[08-27 15:27:29.812] com.caucho.java.JavaCompileException: Resin can't execute the compiler `/bin/sh'. This usually means that the compiler is not in the op erating system's PATH or the compiler is incorrectly specified in the configuration. You may need to add the full path to <java compiler='/bin/sh'/>. [08-27 15:27:29.812] [08-27 15:27:29.812] java.io.IOException: Cannot run program "/bin/sh": java.io.IOException: error=12, Cannot allocate memory [08-27 15:27:29.812] at com.caucho.java.ExternalCompiler.executeCompiler(ExternalCompiler.java:435) [08-27 15:27:29.812] at com.caucho.java.ExternalCompiler.compileInt(ExternalCompiler.java:151) [08-27 15:27:29.812] at com.caucho.java.AbstractJavaCompiler.run(AbstractJavaCompiler.java:102) [08-27 15:27:29.812] at java.lang.Thread.run(Thread.java:619)
分析
- 老谢之前有过总结: http://bbs.pconline.cn/topic-175.html
- 现象上看是jsp编译的时候,操作系统分配不到内存
- jsp复杂度高导致编译需要的资源多
- 应用的压力大,导致jvm本身占用的内存多,操作系统的内存余量有影响
初步处理
- 237.45增加了1g内存
- 准备dump一次内存看看应用占内存的大头是哪部分,resin是否可以减少内存配置
- 测试环境模拟压力测试,看看能否重现并做动态监控和分析
长期目标
- 报价应用前台拆分:索引服务 + SSI服务
- 报价服务器拆分:静态文件 + mysql + squid
Note: See
TracTickets for help on using
tickets.
![(please configure the [header_logo] section in trac.ini)](http://www1.pconline.com.cn/hr/2009/global/images/logo.gif)