This is a migrated thread and some comments may be shown as answers.

problems upload on Windows Server 2008/IIS7

9 Answers 424 Views
Upload (Obsolete)
This is a migrated thread and some comments may be shown as answers.
Charles
Top achievements
Rank 1
Charles asked on 24 Jul 2008, 02:48 PM
Using the RadUpload control, I'm seeing problems uploading on Windows Server 2008/IIS7 -- specifically an "Access to the path... is Denied".

We've set the IUSR account to have "full control" on the upload directory.

The entire error message I'm seeing is:

Error saving 446_8089_150632.gif
System.UnauthorizedAccessException: Access to the path 'D:\inetpub\wwwroot\rmcpapp\uploads\446_8089_150632.gif' is denied. at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite) at Telerik.Web.UI.Upload.RadUploadFile.SaveAs(String fileName, Boolean overwrite) at RMCPWebApp.Upload.Page_Load(Object sender, EventArgs e)


Any thoughts?

9 Answers, 1 is accepted

Sort by
0
Veselin Vasilev
Telerik team
answered on 24 Jul 2008, 02:59 PM
Hello Charles,

Please set the Full Control to the account that the asp.net process is running under (by default this is the Network Service account) to that folder as well.

Regards,
Veskoni
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Charles
Top achievements
Rank 1
answered on 24 Jul 2008, 03:10 PM
Hi, Vaskoni. Thanks for the quick reply. Just tried setting the permissions for the "Network Service" account to "Full Control" to my uploads directory, and then restarted IIS 7. The result was the same (failed) with the same error message.

We are running this web app using compatibility mode on IIS7.

Does it matter, do you think, that I am targeting the ASP.NET 3.5 framework?


0
Veselin Vasilev
Telerik team
answered on 24 Jul 2008, 03:28 PM
Hi Charles,

You could check this article which seems helped on that problem:
http://forums.asp.net/p/1104125/1689208.aspx

Regards,
Veskoni
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Accepted
Brad
Top achievements
Rank 1
answered on 08 Feb 2010, 04:37 AM
Just posting this to help the next guy that has this problem.  In IIS7 you need to make sure that the Application Pool that your website is running under is using the NETWORK SERVICE account.  Per the posts above which make perfect sense for someone coming from IIS6, setting elevated permissions for NETWORK SERVICE won't do anything at all if you're not running under that account. 

So expand the parent node in IIS, click on Application Pools, select your pool, right-click and select Advanced Settings, and then change the Identity setting to NetworkService.

Hope that saves you a few hours of Internet searching.  It's a really simple thing, but so easily to overlooked.

Brad
0
Raj Nemani
Top achievements
Rank 1
answered on 05 Apr 2010, 11:04 PM
Thank you, Thank you!!
0
Albert Shenker
Top achievements
Rank 1
Veteran
Iron
answered on 27 Oct 2010, 01:36 PM
I've run into this same problem. I followed the steps to configure the AppPool to use NetworkService Identity, but the same problem occurs. I get the error:

Access to the path is denied.

In my case RadAsyncUpload is unable to move the uploaded file from the temp directory to my specified TargetFolder. I am able to write files to the specified TargetFolder in codebehind using My.Computer.FileSystem.WriteAllText without any permissions issues, so I'm surprised the Telerik Control would encounter these issues.

0
Genady Sergeev
Telerik team
answered on 02 Nov 2010, 09:40 AM
Hi Albert Shenker,

Is the issue reproducible on a sample project? Could you please open a support ticket and send the sample to us so that we can take a look. Usually, the default account that IIS issues is sufficient in order for RadAsyncUpload to work properly.

All the best,
Genady Sergeev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
sotero
Top achievements
Rank 1
answered on 18 Oct 2015, 05:54 PM

I am having exactly the same problem described by Albert Shenker "Access to the path is denied.
In my case RadAsyncUpload is unable to move the uploaded file from the temp directory to my specified TargetFolder."

Setting the target folder property in RadAsyncUpload or using the saveas method to move the file to target folder throw the same exception but if I use system.io to write a file in target folder it runs fine. I am using IIS7.5 on a WIndows 7 professional and Telerik version 2015.1.225.45.

I tried to give full permission to "everyone" on the target directory but fails. I've already tried to change pool identity from AplicationPoolIdentity to Network Service but I am still getting the same error message (Access denied).

I am stuck with this problem.

 

 

0
sotero
Top achievements
Rank 1
answered on 18 Oct 2015, 06:46 PM

As I wrote above this situation is really bizarre. RadAsyncUpload send the files do tempFolder "~App_Data\RadUploadTemp" but it cant move the file to target directory.

My target folder has full permissions to everyone. So I decided to try a different approach to test. I chaged the property "temporary folder", instead of "~App_Data\RadUploadTemp" I wrote "~/documents/files" which is my target folder. Surprise, It works! RadAsyncUpload is able to upload a file to this target directory so why it throws "access denied" when it moves the file from default temporary folder? It doesnt make any sense!

I decided to put the temporary folder equal to my target folder and now it is woriking as expected.It uploads the file with a random name than it changes the file name to its original name.  The difference here is that It's not moving the file to another directory

I will keep it this way and move on cause I lost almost a day with this issue but I would like to hear from Telerik what they think about this issue.

Tags
Upload (Obsolete)
Asked by
Charles
Top achievements
Rank 1
Answers by
Veselin Vasilev
Telerik team
Charles
Top achievements
Rank 1
Brad
Top achievements
Rank 1
Raj Nemani
Top achievements
Rank 1
Albert Shenker
Top achievements
Rank 1
Veteran
Iron
Genady Sergeev
Telerik team
sotero
Top achievements
Rank 1
Share this question
or