I'm trying to set up a file share in EPiServer CMS 5 release version in the FileManager but I'm unsuccessful. This works:
This does NOT work:
Actually the E:\Share and the Z:\ is the same folder on my local harddrive. I've set full rights to both Everyone and the ASP.NET account but it doesn't seem to be a accessright problem. The error I get with Z:\ is:
System.IO.DirectoryNotFoundException: Could not find a part of the path 'Z:\'.
[DirectoryNotFoundException: Could not find a part of the path 'Z:\'.]
System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +1971376
System.IO.Directory.InternalCreateDirectory(String fullPath, String path, DirectorySecurity dirSecurity) +2679222
System.IO.DirectoryInfo.Create() +15
EPiServer.Web.Hosting.VirtualPathUnifiedProvider.GetAndValidatePhysicalPathBase(String physicalPath) +119
EPiServer.Web.Hosting.VirtualPathNativeProvider..ctor(String name, NameValueCollection configParameters) +283
Should this work? If not, how do I set up a file share so that it is accessible from the EPiServer FileManager?
Without testing anything at all regarding this I think you probably should understand that the Z-drive is not mapped for all users and as such you should never refer to non-physical harddrives without using UNC-paths: \\computername\sharepath\ should then work fine if the webapplicationpool etc. has the correct rights to that share/physical-path.
Use:
I would guess this would work straight ahead.
Was it an error when writing the path here or did you configure it with //computer/share? \\computer\share should be the correct one, and it might have some significance.
\\computer\share in web.config result in the same error as above, as do //computer/share. When I write a path on an local harddrive and set the wrong accessrights I get accessright errors.
Then it probably boils down to access-rights again. Depending on what identity your application pool are having and if you are impersonating.
I took the trouble of testing this and I got no problem whatsoever after the rights had been set correct.
Have you set the rights only on the filessytem and not on the share? What OS are you running? What identity are the web app finally getting? Have you set the user/rights it "right" in machine.config etc.?
Hmm... I was rather confident I had impersonation turned on. But that was not the case. I use WinXP so putting ASPNET user on both share and files made it work fine! Thanks for your help!
This does NOT work:
Actually the E:\Share and the Z:\ is the same folder on my local harddrive. I've set full rights to both Everyone and the ASP.NET account but it doesn't seem to be a accessright problem. The error I get with Z:\ is: System.IO.DirectoryNotFoundException: Could not find a part of the path 'Z:\'. [DirectoryNotFoundException: Could not find a part of the path 'Z:\'.] System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +1971376 System.IO.Directory.InternalCreateDirectory(String fullPath, String path, DirectorySecurity dirSecurity) +2679222 System.IO.DirectoryInfo.Create() +15 EPiServer.Web.Hosting.VirtualPathUnifiedProvider.GetAndValidatePhysicalPathBase(String physicalPath) +119 EPiServer.Web.Hosting.VirtualPathNativeProvider..ctor(String name, NameValueCollection configParameters) +283 Should this work? If not, how do I set up a file share so that it is accessible from the EPiServer FileManager?