![]() |
|
|
|||||||
![]() |
ASP Net - Compiler Error Message: CS0006 |
|
|
Thread Tools | Search this Thread |
|
|
#1 |
|
We suddenly got a mysterious error message on our Windows Server 2003 (SP1) after rolling out a bug fix on a web services application this morning. The application compiles and runs fine on the development workstation (from vs 2005 on Windows XP Pro), but when I run "Copy Web Site..." to move the app out from VS to the server, then all accesses to the web service via a browser show this error message: "Compiler Error Message: CS0006: Metadata file" .... "System.EnterpriseServices.dll' could not be found". (Full error is pasted below.) I cannot find any references to this error on MS websites or knowledgebase. I have found several newsgroup references elsewhere stating that you need to place the DLL into the GAC. But from what I can tell, this EnterpriseServices DLL is a .NET assembly that is inherently already in the GAC. (And I looked on the server, and it is present in /windows/assembly.) Also, several posting say to remove "<identity impersonate="true" />" from web.config, but we have no such line in ours. Any recommendations? It's urgent for us. Thanks, Bruce ------------------------------------------------------------ Server Error in '/ws0200' Application. Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately. Compiler Error Message: CS0006: Metadata file 'C:\WINDOWS\assembly\GAC_32\System.EnterpriseServi ces\2.0.0.0__b03f5f7f11d50a3a\System.EnterpriseSer vices.dll' could not be found Source Error: [No relevant source lines] Source File: Line: 0 Show Detailed Compiler Output: c:\windows\system32\inetsrv> "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\csc .exe" /t:library /utf8output /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Mobile\ 2.0.0.0__b03f5f7f11d50a3a\System.Web.Mobile.dll" /R:"C:\WINDOWS\assembly\GAC_32\System.Data\2.0.0.0_ _b77a5c561934e089\System.Data.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Drawing\2.0 .0.0__b03f5f7f11d50a3a\System.Drawing.dll" /R:"C:\WINDOWS\assembly\GAC_32\System.Web\2.0.0.0__ b03f5f7f11d50a3a\System.Web.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System\2.0.0.0__b7 7a5c561934e089\System.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\m scorlib.dll" /R:"C:\WINDOWS\assembly\GAC_32\System.EnterpriseSer vices\2.0.0.0__b03f5f7f11d50a3a\System.EnterpriseS ervices.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Configurati on\2.0.0.0__b03f5f7f11d50a3a\System.Configuration. dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Service s\2.0.0.0__b03f5f7f11d50a3a\System.Web.Services.dl l" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Xml\2.0.0.0 __b77a5c561934e089\System.Xml.dll" /out:"C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 \Temporary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.d ll" /D /optimize- /w:4 /nowarn:1659;1699 "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.1 0.cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.3 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.2 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.1 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.0 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.7 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.6 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.9 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.5 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.8 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.4 .cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.1 1.cs" "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\ws0200\ea7bc2bc\ba7084cf\App_Code.kdys5pgv.1 2.cs" Microsoft (R) Visual C# 2005 Compiler version 8.00.50727.42 for Microsoft (R) Windows (R) 2005 Framework version 2.0.50727 Copyright (C) Microsoft Corporation 2001-2005. All rights reserved. error CS0006: Metadata file 'C:\WINDOWS\assembly\GAC_32\System.EnterpriseServi ces\2.0.0.0__b03f5f7f11d50a3a\System.EnterpriseSer vices.dll' could not be found Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42 Bruce |
|
|
|
|
#2 |
|
Posts: n/a
|
Hello Bruce,
Nice to see you again and how are you doing? Regarding on the error message you mentioned, it seems the ASP.NET runtime failed to locate the System.EnterpriseServices.dll metadata assembly from the following loatino: "C:\WINDOWS\assembly\GAC_32\System.EnterpriseServi ces\2.0.0.0__b03f5f7f11d50 a3a\" Based on my experience, this is likely a machine specific issue. Have you tried deploying the web application on other webserver machine to see whether it also suffers this issue? I've done some research in our internal database and found some former cases that have the similar symptom as yours. In those cases, the problem machine's GAC_32 seems has been corrupted(or not installed well) and the System.EnterpriseServices.dll assembly is not in the expected location(as above). To verify this, you can start the commandline prompt(cmd.exe) on the problem server machine and navigate to the following directory: C:\WINDOWS\assembly\GAC_32\System.EnterpriseServic es\2.0.0.0__b03f5f7f11d50a 3a\ After that use "dir" command to see whether the System.EnterpriseServices.dll assembly is in it. If the assembly does be missing, you can manually copy a valid copy into it. You can find a copy of the "System.EnterpriseServices.dll" in the following location: C:\Windows\Microsoft.NET\Framework\v2.0.50727 After you have copied the assembly, you can test the web application again to see whether it works. Hope this helps. Sincerely, Steven Cheng Microsoft MSDN Online Support Lead ================================================== Get notification to my posts through email? Please refer to http://msdn.microsoft.com/subscripti...ult.aspx#notif ications. Note: The MSDN Managed Newsgroup support offering is for non-urgent issues where an initial response from the community or a Microsoft Support Engineer within 1 business day is acceptable. Please note that each follow up response may take approximately 2 business days as the support professional working with you may need further investigation to reach the most efficient resolution. The offering is not appropriate for situations that require urgent, real-time or phone-based interactions or complex project analysis and dump analysis issues. Issues of this nature are best handled working with a dedicated Microsoft Support Engineer by contacting Microsoft Customer Support Services (CSS) at http://msdn.microsoft.com/subscripti...t/default.aspx. ================================================== This posting is provided "AS IS" with no warranties, and confers no rights. |
|
|
|
#3 |
|
Junior Member
Join Date: Aug 2007
Posts: 1
|
I had this same issue...
I simply ran the "Microsoft .NET Framework Version 2.0 Redistributable Package" again, and selected the repair option. Once I rebooted the machine, everything worked again. |
|
|
|