惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Blog — PlanetScale
Blog — PlanetScale
博客园_首页
WordPress大学
WordPress大学
博客园 - 聂微东
P
Privacy International News Feed
Forbes - Security
Forbes - Security
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Last Week in AI
Last Week in AI
C
CERT Recently Published Vulnerability Notes
月光博客
月光博客
NISL@THU
NISL@THU
美团技术团队
T
Tailwind CSS Blog
Jina AI
Jina AI
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Apple Machine Learning Research
Apple Machine Learning Research
C
Cisco Blogs
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
The Hacker News
The Hacker News
B
Blog
P
Palo Alto Networks Blog
L
Lohrmann on Cybersecurity
有赞技术团队
有赞技术团队
The Register - Security
The Register - Security
S
Securelist
A
Arctic Wolf
MyScale Blog
MyScale Blog
H
Help Net Security
N
Netflix TechBlog - Medium
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
T
Threatpost
Recent Commits to openclaw:main
Recent Commits to openclaw:main
Security Latest
Security Latest
T
Tor Project blog
V
Vulnerabilities – Threatpost
V
V2EX
AI
AI
Hugging Face - Blog
Hugging Face - Blog
大猫的无限游戏
大猫的无限游戏
博客园 - Franky
Simon Willison's Weblog
Simon Willison's Weblog
小众软件
小众软件
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
H
Hackread – Cybersecurity News, Data Breaches, AI and More
T
Troy Hunt's Blog
Schneier on Security
Schneier on Security
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
H
Heimdal Security Blog
Google Online Security Blog
Google Online Security Blog
Know Your Adversary
Know Your Adversary

博客园 - 鞠强

HBase初探 C#访问Azure的资源 HDInsight - 1,简介 Windows8.1画热度图 - 坑 使用windbg查看DependencyObject的属性 LiveSDK初始化/登录时失败的解决办法 开发WP版本的大菠萝英雄榜 SQL 2014 in-memory中的storage部分 XAML绑定 Kinect 1 Diablo3狗熊榜 微软上海招聘有经验的.NET开发人员 塔防蜀的存档分析 我的HD2手机 和我一起作Tess的windbg lab,结束 和我一起作Tess的windbg lab - Lab7, MemoryLeak 和我一起作Tess的windbg lab - Lab5, Crash 和我一起作Tess的windbg lab - Lab4, High CPU 和我一起作Tess的windbg lab - Lab3, Memory
和我一起作Tess的windbg lab - Lab6, MemoryLeak
鞠强 · 2010-06-27 · via 博客园 - 鞠强

原文地址:http://blogs.msdn.com/b/tess/archive/2008/03/17/net-debugging-demos-lab-6-memory-leak.aspx

操作步骤:

1、产生压力: tinyget -srv:localhost -uri:/BuggyBits/ProductInfo.aspx?ProductName=Bugspray -threads:50 -loop:20

2、这个比较有意思,CPU很高,经常100%,内存很少,几十M而已。如果你仔细看taskmgr,会看到有几个csc诡异的出现,忙了一会,又消失了。

3、抓一个hang的dump,运行!eeheap -gc,看看内存状况:

  GC Heap Size  0x68a0fc(6856956)

  托管内存只用到了6M多,而我的dump是190M,那么,其余的内存被谁用了?

4、联想到步骤2中的诡异的csc进程,我们需要再检查一下,!eeheap -loader,看看有多少dll在loader heap里面?我这里一共看到了2223个

5、随便找一个module看看

  0:000> !dumpmodule -mt 06f0ab78
  Name: oghe0kiv, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
  Attributes: PEFile
  Assembly: 07093808
  LoaderHeap: 00000000
  TypeDefToMethodTableMap: 0702f8c4
  TypeRefToMethodTableMap: 0702f8dc
  MethodDefToDescMap: 0702f93c
  FieldDefToDescMap: 0702f9a8
  MemberRefToDescMap: 0702f9d4
  FileReferencesMap: 0702fac4
  AssemblyReferencesMap: 0702fac8
  MetaData start address: 072e09e4 (4184 bytes)

  Types defined in this module

      MT    TypeDef Name
------------------------------------------------------------------------------
  06f0b7ac 0x02000002 Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationWriterProduct
  06f0b6fc 0x02000006 Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializerContract

  Types referenced in this module

      MT    TypeRef Name
------------------------------------------------------------------------------
  63a28fb0 0x01000001 System.Xml.Serialization.XmlSerializationWriter
  63a295a4 0x01000004 System.Xml.Serialization.XmlSerializerImplementation
  05e60b3c 0x01000005 Product
  05e60bbc 0x01000006 ShippingInfo
  79101fe4 0x01000008 System.Collections.Hashtable
  79106894 0x01000009 System.Type
  790fd0f0 0x0100000f System.Object
  639ff1c4 0x01000013 System.Xml.XmlConvert

6、看到这里基本清楚了,这就是那个著名的XmlSerializer的问题。可以参考我以前写的blog:http://www.cnblogs.com/juqiang/archive/2008/01/15/1039936.html

Over