0

Every time the ASP.NET application in question throws an error the Global.asax writes to an error file: logs\error.log. The ASP.NET applications works using Windows authentication.

I am able to write to the log file when debugging using Visual Studio, however it does not work when the application is deployed in the live environment. How do I find out what user account I need to give access to: logs/error.log?

The application is deployed on a Windows 2003 Server with IIS6. Microsoft.NET 3.5.

2

4 Answers 4

1

You would have to give the required permissions to the network service account. This link might be able to help you out.

Sign up to request clarification or add additional context in comments.

Comments

0

Windows Server 2003 defaults to the "Network Service" account. This can be verified by opening IIS (expand the computer if needed), expand the "Application Pools" folder, right click on the pool used by your web app, and go to the Identity tab.

FYI: Windows Server 2008 uses the IIS_IUSER instead of Network Services.

1 Comment

Thanks. I have selected this as the answer as you also talked about how to find the identity user in IIS.
0

I hope that logs folder is a virtual directory setup outside the web site directory.

Otherwise every time you deploy the entire solution you will overwrite the logs folder and its content.

1 Comment

No. The XCOPY batch file creates a copy of the error log before overwriting.
0

Microsoft has a tool for monitoring file access that can be useful for troubleshooting permission issues.

Process Monitor - http://technet.microsoft.com/en-us/sysinternals/bb896645

You will also want to check if your application is using windows authentication & identity impersonation since that can change the identity the application is executing with when enabled.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.