IIS6上的Web服务 - 许多临时文件生成到C:\ WINDOWS \ TEMP中 [英] web service on IIS6 - many temp files are generated into C:\WINDOWS\TEMP

查看:125
本文介绍了IIS6上的Web服务 - 许多临时文件生成到C:\ WINDOWS \ TEMP中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在IIS 6(win 2003服务器)上运行.NET Web服务。问题是IIS(或csc.exe)在"c:\ WINDOWS \ Temp"中生成了大量(!)文件。目录。很多文件意味着成千上万的文件,到目前为止大小超过3G。

I have a .NET web-services running on IIS 6 (win 2003 server). The issue is that IIS (or csc.exe) is generating a lot (!) of files in "c:\WINDOWS\Temp" directory. a lot of files means thousands of files, which get to more than 3G of size so far.

这些文件由以下命令生成:

The files are generated by this command:

C:\WINDOWS\SysWOW64\inetsrv> " C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\csc.exe" / t:library / utf8output /R:"C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\vfagt\113819dd\db0d5802\assembly\ dl3\fedc6ef1\006e24d8_3bc9ca01\VfAgentWService.DLL" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Services\2.0.0.0__b03f5f7f11d50a3a\System.Web.Services.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorlib.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Xml\2.0.0.0__b77a5c561934e089\System.Xml.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll" /out:"C:\WINDOWS\TEMP\9i_i2bmg.dll" / debug- / optimize + / nostdlib / D:_DYNAMIC_XMLSERIALIZER_COMPILATION&qu​​ot; C:\ WINDOWS \ TEMP \ 9i_i2bmg.0.cs"

C:\WINDOWS\SysWOW64\inetsrv> "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\csc.exe" /t:library /utf8output /R:"C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\vfagt\113819dd\db0d5802\assembly\dl3\fedc6ef1\006e24d8_3bc9ca01\VfAgentWService.DLL" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Services\2.0.0.0__b03f5f7f11d50a3a\System.Web.Services.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\mscorlib.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Xml\2.0.0.0__b77a5c561934e089\System.Xml.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll" /out:"C:\WINDOWS\TEMP\9i_i2bmg.dll" /debug- /optimize+ /nostdlib /D:_DYNAMIC_XMLSERIALIZER_COMPILATION "C:\WINDOWS\TEMP\9i_i2bmg.0.cs"

此命令始终具有此类输出:

this command always has this kind of output:

 

Microsoft(R)Visual C#2005编译器版本8.00.50727.3053

Microsoft (R) Visual C# 2005 Compiler version 8.00.50727.3053

for Microsoft(R )Windows(R)2005 Framework版本2.0.50727

for Microsoft (R) Windows (R) 2005 Framework version 2.0.50727

版权所有(C)Microsoft Corporation 2001-2005。保留所有权利。

Copyright (C) Microsoft Corporation 2001-2005. All rights reserved.

 

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1213,39):警告CS0219:变量'a_1'已分配,但其值从未使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1213,39): warning CS0219: The variable 'a_1' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1214,17):警告CS0219:变量'ca_1'已分配但其值永远不会使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1214,17): warning CS0219: The variable 'ca_1' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1215,39):警告CS0219:变量'a_2'已分配但其值永远不会使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1215,39): warning CS0219: The variable 'a_2' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1216,17):警告CS0219:变量'ca_2 '已分配但其值永远不会被使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1216,17): warning CS0219: The variable 'ca_2' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1217,77):警告CS0219:变量'a_4'是已分配,但其值永远不会使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1217,77): warning CS0219: The variable 'a_4' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1218,17):警告CS0219:已分配变量"ca_4"但它的值永远不会被使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1218,17): warning CS0219: The variable 'ca_4' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1219,39):警告CS0219 :变量'a_5'已分配但其值永远不会使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1219,39): warning CS0219: The variable 'a_5' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1220,17):警告CS0219:变量'ca_5'已分配但其值永远不会使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1220,17): warning CS0219: The variable 'ca_5' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1221,62):警告CS0219:变量' a_8'已分配,但其值永远不会被使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1221,62): warning CS0219: The variable 'a_8' is assigned but its value is never used

c:\ WINDOWS \Temp \ 9i_i2bmg.0.cs(1222,17):警告CS0219:变量'ca_8'已分配,但其值永远不会被使用

c:\WINDOWS\Temp\9i_i2bmg.0.cs(1222,17): warning CS0219: The variable 'ca_8' is assigned but its value is never used

 

临时目录中的文件是* .out& * .err,* .err文件的大小为零,* .out文件包含编译输出消息。

The files in the temp directory are pairs of *.out & *.err, where the *.err file is zero size, and the *.out file contains the compilation output messages.

问题是上面的命令被执行多次,引起.out& .err生成了很多次,直到消耗了磁盘空间。

The problem is that the above command is being executed many times, causing the .out & .err to be generated so many times, until it consumes the disk space.

所以 - 我的问题是:是什么导致这个命令运行了这么多次?

So - my question is: what is causing this command to run so many times?

如果它与XmlSerialization输出有关,那么每个xml序列化总会产生如此多的临时文件是否有意义?

If it's related to XmlSerialization output, does it make any sense that every xml serialization will always generate so many temp files?

 

谢谢。

 

推荐答案

我不确定文件为何正在进入该目录。在我的机器上(也运行Windows Server 2003),它们被放入C:\ WINDOWS \ MicroStoswork \ Framework \v2.0.50727 \Temporary ASP.NET Files。

I'm not sure why the files are going into that directory. On my machine (also running Windows Server 2003) they are put into C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files.

您可能正在使用XmlSerializer,以防止它重用它在运行时生成的程序集。参见"动态生成的组件"和"动态生成的组件"。在 XmlSerializer类的文档中。

You may be using the XmlSerializer in a way that prevents it from reusing the assemblies it generates at runtime. See "Dynamically Generated Assemblies" in the documentation for the XmlSerializer class .

 

BTW,只需删除这些文件。

BTW, just delete these files.

 


这篇关于IIS6上的Web服务 - 许多临时文件生成到C:\ WINDOWS \ TEMP中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆