I finally powered up again with my newly purchased dual-core laptop, which also enables me to refresh software installations that I’ve been wanting to do for a long time.  As I’m putting things back together, I kept running into this error with my projects:

The current identity (xxx\ASPNET) does not have write access to ‘C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files’.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Here’s a quick fix to the problem (do this only to your dev box):

1. From the framework directory (Usually c:\windows\microsoft.net\framework\v2.0.50727\Config), modify machine.config:

<processModel userName="SYSTEM" password="autoGenerated"/>

2. Execute this command:

> aspnet_regiis -ga “ASPNET"

By applying MS’s Web updates (often times including security patches), or putting you box into domain (which I am), the security constriant of your windows install drive got stricted.  If you read the prompt from aspnet_regiis carefully, switch -ga is granting the daemon user access to the IIS metabsae and other directories used by ASP.NET, which is exactly what I’m looking to do..

Further Reading:
Microsoft’s KB: http://support.microsoft.com/kb/315158/

廣告