The problem is that the WSUS failed to be started, even after reinstalling it.
In the application event log, it records 1310 error as below when the issue reproduce.
Event Type: Warning
Event Source: ASP.NET 2.0.50727.0
Event Category: Web Event
Event ID: 1310
Time: 9:17:48 AM
Event code: 3007
Event message: A compilation error has occurred.
Event time: 15/07/2009 11:17:48 AM
Event time (UTC): 15/07/2009 1:17:48 AM
Event ID: 6873d1bc3a674f9f8eef61cbefd474a9
Event sequence: 3
Event occurrence: 1
Event detail code: 0
Application domain: /LM/W3SVC/1/ROOT/SimpleAuthWebService-5532-128920942679978360
Trust level: Full
Application Virtual Path: /SimpleAuthWebService
Application Path: C:\Program Files\Update Services\WebServices\SimpleAuthWebService\
Machine name: YourMachine
Process ID: 2032
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE
Exception type: HttpCompileException
Exception message: (0): error CS0016: Could not write to output file 'c:\WINNT\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\simpleauthwebservice\98115b04\11eb47d4\App_global.asax.alwtdj4m.dll' -- 'The directory name is invalid. '
Request URL: http://yourWebSite/SimpleAuthWebService/SimpleAuth.asmx
Request path: /SimpleAuthWebService/SimpleAuth.asmx
User host address: nnn.nn.nn.nn
Is authenticated: False
Thread account name: NT AUTHORITY\NETWORK SERVICE
Thread ID: 6
Is impersonating: False
Stack trace: at System.Web.Compilation.AssemblyBuilder.Compile()
at System.Web.Compilation.ApplicationBuildProvider.GetGlobalAsaxBuildResult(Boolean isPrecompiledApp)
at System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters)
From the error message, it indicates some folder is missing. The ideal way to find out which directory was invalid is to use Process Monitor tool that records the real time file system activity in this case.
Based on our experience, we first checked what the TEMP and TEM folder were pointing to
1. Right-click My Computer -> Properties -> Advanced tab -> Environment Variables -> Select the TEMP variable under System variables -> Edit
It may be pointing to "%Windir%\Temp”.
2. Check if the location %Windir%\Temp is present there.
If not, create the Temp folder on C: drive.
3. Reset IIS
Then, it still failed to start on. We checked the Application Event log. Although it was still the Event 1310, the detail was different. Now it is “Access is denied”.
Exception message: (0): error CS0016: Could not write to output file 'c:\WINNT\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\simpleauthwebservice\98115b04\11eb47d4\App_global.asax.wk7vn4hi.dll' -- 'Access is denied. '
Use Process Monitor tool to find out which directory was invalid.
Create the %Windir%\Temp that TEMP and TEM variable under System variables are pointing to.
Add the Full control permission for Network Service account to the folders:
· %Windir%\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files
The solution worked like a charm! I deleted a partition that I thought wasn't being used and the Temp and TMP folders were there. I changed to the %Windir% locations and everything started flowing! THANK YOU SO MUCH!!!