JWorld@TW the best professional Java site in Taiwan
      註冊 | 登入 | 全文檢索 | 排行榜  

» JWorld@TW » Application Server » BEA Weblogic  

按列印兼容模式列印這個話題 列印話題    把這個話題寄給朋友 寄給朋友   
reply to topicthreaded modego to previous topicgo to next topic
己加入精華區
by browser at 2007-04-14 01:50
本主題所含的標籤
無標籤
作者 Memory leak detector tools? [精華]
kangkangss





發文: 16
積分: 0
於 2007-04-12 10:17 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
小弟项目中使用WebLogic server 8.1 sp5,用到JRockit1.4.2 系列JDK。

现在想对JVM的memory leak进行追踪,能追到代码的问题。

最先试用了JProbe和JProfiler,但他们都对JRockit支持不好,容易死掉,并且配置烦琐性能消耗比较大。

又研究了一下JRockit Memory Leak Detector,但其只能支持JRockit5.0以上的版本。

大家有什么好的工具和方法可以推荐么?


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
worookie

Small Ship

版主

發文: 2092
積分: 21
於 2007-04-12 10:55 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
kangkangss wrote:
小弟项目中使用WebLogic server 8.1 sp5,用到JRockit1.4.2 系列JDK。

现在想对JVM的memory leak进行追踪,能追到代码的问题。

最先试用了JProbe和JProfiler,但他们都对JRockit支持不好,容易死掉,并且配置烦琐性能消耗比较大。

又研究了一下JRockit Memory Leak Detector,但其只能支持JRockit5.0以上的版本。

大家有什么好的工具和方法可以推荐么?


應該沒有更好的工具了

要找到 java 的 memory leak 是一件不容易的事.
要嘛你必須是高手, 不然你就得要很有耐心.


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
kangkangss





發文: 16
積分: 0
於 2007-04-12 22:57 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
对于如何分析感觉还略知一二,但苦于没有工具辅助。

请教高人啊!


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
worookie

Small Ship

版主

發文: 2092
積分: 21
於 2007-04-12 23:33 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
底下是六年前看過的題目, 還蠻有趣的. 你有看出問題來嗎? 建議先試試看工具可以輔助您什麼.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import java.util.EmptyStackException;
 
class MemoryLeak {
    private Object[] elements;
 
    private int size = 0;
 
    public MemoryLeak(int initialCapacity) {
        this.elements = new Object[initialCapacity];
    }
 
    public void push(Object e) {
        ensureCapacity();
        elements[size++] = e;
    }
 
    public Object pop() {
        if (size == 0)
            throw new EmptyStackException();
        return elements[--size];
    }
 
    private void ensureCapacity() {
        if (elements.length == size) {
            Object[] oldElements = elements;
            elements = new Object[2 * elements.length + 1];
            System.arraycopy(oldElements, 0, elements, 0, size);
        }
    }
}


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
hkdennis2k





發文: 1926
積分: 6
於 2007-04-13 00:39 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
只加不減

沒有設 null


reply to postreply to post
1. Programming is not coding

2. Learning Java is not leaning Java syntax

3. Study, not wait for be taught

4. Answer to yourself, not ask somebody else

5. Code is poetry

---
6. 我跑去寫 C# 了....

---
7. 回到 Java, PHP 還有 servers farm
---
8. 很久沒有寫 Java 了, 倒
作者 Re:Memory leak detector tools? [Re:kangkangss]
kangkangss





發文: 16
積分: 0
於 2007-04-13 00:55 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
呵呵,楼上worookie 兄台

且不说你出题目的用意,也先不讨论你的题目,暂时先说说工具的作用。

[略]


kangkangss edited on 2007-04-13 13:39
reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
LinusTseng





發文: 58
積分: 0
於 2007-04-13 09:33 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
小弟目前也被類似的問題困擾
不過我們的平台用的是Tomcat 架在Linux上沒有圖形介面
但JProbe和JProfiler都必需灌在有X Window的Linux上。

是否有其他的方法or工具可以監控AS Memory的情形呢?


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
worookie

Small Ship

版主

發文: 2092
積分: 21
於 2007-04-13 09:36 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
kangkangss wrote:
呵呵,楼上worookie 兄台

且不说你出题目的用意,也先不讨论你的题目,暂时先说说工具的作用。
(略)


我當然要用工具的. 看你的意思好像是說我不用工具的, 這應該是個誤會.


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:worookie]
kangkangss





發文: 16
積分: 0
於 2007-04-13 13:42 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
worookie wrote:
我當然要用工具的. 看你的意思好像是說我不用工具的, 這應該是個誤會.


呵呵,误会误会,仁兄见谅;


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:LinusTseng]
hkdennis2k





發文: 1926
積分: 6
於 2007-04-13 21:12 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
LinusTseng wrote:
小弟目前也被類似的問題困擾
不過我們的平台用的是Tomcat 架在Linux上沒有圖形介面
但JProbe和JProfiler都必需灌在有X Window的Linux上。

是否有其他的方法or工具可以監控AS Memory的情形呢?


它們是可以做到 remote profiling 的
就像 remote debug 一樣, 設定好參數即可


reply to postreply to post
1. Programming is not coding

2. Learning Java is not leaning Java syntax

3. Study, not wait for be taught

4. Answer to yourself, not ask somebody else

5. Code is poetry

---
6. 我跑去寫 C# 了....

---
7. 回到 Java, PHP 還有 servers farm
---
8. 很久沒有寫 Java 了, 倒
作者 Re:Memory leak detector tools? [Re:LinusTseng]
kangkangss





發文: 16
積分: 0
於 2007-04-14 21:47 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
LinusTseng wrote:
小弟目前也被類似的問題困擾
不過我們的平台用的是Tomcat 架在Linux上沒有圖形介面
但JProbe和JProfiler都必需灌在有X Window的Linux上。

是否有其他的方法or工具可以監控AS Memory的情形呢?


JProbe和JProfiler对SUN的jdk支持还是比较好的;
两者比较,JProfiler感觉有模仿和超越JProbe之趋势。

并且,两者都支持remote session,在这点上JProfiler更容易配置。


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:LinusTseng]
antonypoyu





發文: 64
積分: 0
於 2007-05-17 20:56 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
LinusTseng wrote:
小弟目前也被類似的問題困擾
不過我們的平台用的是Tomcat 架在Linux上沒有圖形介面
但JProbe和JProfiler都必需灌在有X Window的Linux上。

是否有其他的方法or工具可以監控AS Memory的情形呢?


JRockit Mission Control 可以從遠端監控JVM。


reply to postreply to post
作者 Re:Memory leak detector tools? [Re:kangkangss]
kyhuang





發文: 31
積分: 0
於 2007-07-20 18:06 user profilesend a private message to usersend email to kyhuangreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
有此工具, 請來信詢問.
另外CA的Wily Introscope也還不錯.


reply to postreply to post
» JWorld@TW »  Application Server » BEA Weblogic

reply to topicthreaded modego to previous topicgo to next topic
  已讀文章
  新的文章
  被刪除的文章
Jump to the top of page

JWorld@TW 本站商標資訊

Powered by Powerful JuteForum® Version Jute 1.5.8