cimscims
asked on
401 - Unauthorized: Access is denied due to invalid credentials
I have a web page and i trying to generate an XML file and store in network drive(\\SERVER1\TEST FOLDER1\). I have problem while storing the file. When i change the path to "D:\TEST FOLDER2\" it works fine. But if give the network folder it fails..it gives me the attached error. Find the event log info. I think i'm missing some permissions here..please shed a light on this.. Thanks in advance
************************** ********** ********** ********
Event code: 4011
Event message: An unhandled access exception has occurred.
Event time: 10/7/2013 12:50:25 PM
Event time (UTC): 10/7/2013 4:50:25 PM
Event ID: 9b294618926d4ccb90f591cc9d 414e6a
Event sequence: 14
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/1/ROOT/LibReques t-5-130256 3821769853 45
Trust level: Full
Application Virtual Path: /BookRequest
Application Path: D:\Test\Request\
Machine name: PRODSERV1
Process information:
Process ID: 6500
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE
Request information:
Request URL: http://PRODSERV1/BookRequest/BookRequest.aspx
Request path: /BookRequest/BookRequest.a spx
User host address: 199.167.135.102
User: TDOM\YZ8765
Is authenticated: True
Authentication Type: NTLM
Thread account name: NT AUTHORITY\NETWORK SERVICE
************************** ********** ********** ********
Error.JPG
**************************
Event code: 4011
Event message: An unhandled access exception has occurred.
Event time: 10/7/2013 12:50:25 PM
Event time (UTC): 10/7/2013 4:50:25 PM
Event ID: 9b294618926d4ccb90f591cc9d
Event sequence: 14
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/1/ROOT/LibReques
Trust level: Full
Application Virtual Path: /BookRequest
Application Path: D:\Test\Request\
Machine name: PRODSERV1
Process information:
Process ID: 6500
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE
Request information:
Request URL: http://PRODSERV1/BookRequest/BookRequest.aspx
Request path: /BookRequest/BookRequest.a
User host address: 199.167.135.102
User: TDOM\YZ8765
Is authenticated: True
Authentication Type: NTLM
Thread account name: NT AUTHORITY\NETWORK SERVICE
**************************
Error.JPG
The identity running your application pool does not have access to the location you are writing to
You will need to set up a user that will run your application pool identity and grant that use the Read/Write to that folder you are writing to.
See the link below for more info
http://www.iis.net/learn/manage/configuring-security/application-pool-identities
You will need to set up a user that will run your application pool identity and grant that use the Read/Write to that folder you are writing to.
See the link below for more info
http://www.iis.net/learn/manage/configuring-security/application-pool-identities
ASKER
I'm using the Windows Authentication and Impersonation is True.
Would you guide me sttting up the user that runs the application pool identity.
Would you guide me sttting up the user that runs the application pool identity.
Please check the following links
http://technet.microsoft.com/en-us/library/cc771170%28v=WS.10%29.aspx
http://support.appliedi.net/index.php?/Knowledgebase/Article/View/768/0/how-to-manually-create-a-site--application-pool-identity-in-iis7
I'm leaving the office now and will log on when i get home in 45mins
http://technet.microsoft.com/en-us/library/cc771170%28v=WS.10%29.aspx
http://support.appliedi.net/index.php?/Knowledgebase/Article/View/768/0/how-to-manually-create-a-site--application-pool-identity-in-iis7
I'm leaving the office now and will log on when i get home in 45mins
ASKER
I have created a user "IUSR_BookRequest" and assigned the user to run the application pool. But how should i grant access the new user to the network drive(\\SERVER1\TEST FOLDER1\)?
When i run the application, i got the below error.
************************** ********** ********** ********
Event code: 4011
Event message: An unhandled access exception has occurred.
Event time: 10/7/2013 02:16:25 PM
Event time (UTC): 10/7/2013 6:16:25 PM
Event ID: 9b294618926d4ccb90f591cc9d 414e6a
Event sequence: 14
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/1/ROOT/BookReque st-5-13025 6382176985 345
Trust level: Full
Application Virtual Path: /BookRequest
Application Path: D:\Test\Request\
Machine name: PRODSERV1
Process information:
Process ID: 6500
Process name: w3wp.exe
Account name: PRODSERV1\IUSR_BookRequest
Request information:
Request URL: http://PRODSERV1/BookRequest/BookRequest.aspx
Request path: /BookRequest/BookRequest.a spx
User host address: 199.167.135.102
User: TDOM\YZ8765
Is authenticated: True
Authentication Type: NTLM
Thread account name: PRODSERV1\IUSR_BookRequest
************************** ********** ********** ********
When i run the application, i got the below error.
**************************
Event code: 4011
Event message: An unhandled access exception has occurred.
Event time: 10/7/2013 02:16:25 PM
Event time (UTC): 10/7/2013 6:16:25 PM
Event ID: 9b294618926d4ccb90f591cc9d
Event sequence: 14
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/1/ROOT/BookReque
Trust level: Full
Application Virtual Path: /BookRequest
Application Path: D:\Test\Request\
Machine name: PRODSERV1
Process information:
Process ID: 6500
Process name: w3wp.exe
Account name: PRODSERV1\IUSR_BookRequest
Request information:
Request URL: http://PRODSERV1/BookRequest/BookRequest.aspx
Request path: /BookRequest/BookRequest.a
User host address: 199.167.135.102
User: TDOM\YZ8765
Is authenticated: True
Authentication Type: NTLM
Thread account name: PRODSERV1\IUSR_BookRequest
**************************
Is this user running your application pool?
Have you granted the required permission for the user for \\SERVER1\TEST FOLDER1\?
You grant access to the folder by
Right click \\SERVER1\TEST FOLDER1\ and select Properties
Select the Security Tab
Click on Add to add the user that you created - PRODSERV1\IUSR_BookRequest
Select the appropriate permission
Click ok
Have you granted the required permission for the user for \\SERVER1\TEST FOLDER1\?
You grant access to the folder by
Right click \\SERVER1\TEST FOLDER1\ and select Properties
Select the Security Tab
Click on Add to add the user that you created - PRODSERV1\IUSR_BookRequest
Select the appropriate permission
Click ok
ASKER
I couldn't see the PRODSERV1\IUSR_BookRequest user in the security tab as it is saying the user is not available as it searches in another server not the PRODSERV1. Any idea?
Is PRODSERV1 in your domain or a workgroup server?
ASKER
I think it is a workgroup server. We have two networks one for internal and another for external i.e internet. Usually we develop intranet apps. This time we have a requirement for external app. PRODSERV1 is on the external network and i'm using my Active Directory details to login to that server. I will be at office in another 1 and half hour and can give you more details. Please let me know if you want more info.
ASKER
PRODSERV1 and the server SERVER1 on which the TEST FOLDER1("\\SERVER1\TEST FOLDER1\") are on the same domain. So, how to give access to PRODSERV1's ISUR_BookRequest read/write access to SERVER1?
Hope i'm clear in asking the question. Otherwise let me know.
Hope i'm clear in asking the question. Otherwise let me know.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Close the request
ASKER
It worked with my solution.
Certainly would be a default permission