0

I have a server (Server 2008) with IIS 7.5, an ASP.NET application. This application use an Excel file place on the newtork. When I launch the application on the server http://localhost/MyApplication ... no problem I can use the file via \network\path or via a mapping drive.

From a client now, I try to use the same appliction http://myServer/MyApplication in this case, I get a message "... is not a valid path"

This application is running on an ApplicationPool with identity "NetworkService"

An idea to solve this problem ?

Thanks,

TheBoubou
  • 19,487
  • 54
  • 148
  • 236

1 Answers1

1

Using the NetworkService as ApplicationPool identity is the issue, you need to set it to run with an identity which has access to the shared drive.

Check the following articles:

http://www.simongibson.com/intranet/virdir/

http://support.microsoft.com/kb/207671

  • Of course, I tried other option than "NetworkService" but same .. :( – TheBoubou Oct 06 '11 at 06:17
  • Just to confirm, you are using a network share through a UNC path and not a mapped drive right? because IIS has problems using network share resources when used as a mapped drive than a UNC path. –  Oct 06 '11 at 06:21
  • Ok, since you say when accessing the site through localhost works but not when accessed through server name (outside the server); I am guessing that the problem could be that both Anonymous access and Integrated authentication maybe enabled. Your IE accessed from outside is not sending the impersonated account info and accessing it through anon identity which may not have access to the share. Though this should work fine if the Anonymous identity has appropriate permission configured on the share, maybe disabling anon authentication and explicitly logging on will help in troubleshooting. –  Oct 06 '11 at 06:35
  • In the connectionstring "...ACE.OLEDB ..." is it possible to set the login and password domain ? – TheBoubou Oct 06 '11 at 17:09