Previously one of our (GSA Client) clients file upload application is in ASP. Now we are planning to convert it into .Net. When I convert and upload a large file, I started getting errors, the same file I used to upload easily in ASP??
15 min I pulled my hair to solve this error! After some time I realized maxRequestLength in httpRuntime is causing the problem. Haa… some times brain won’t react early to identify the issues!!
If any one of you are using file upload functionality in your applications and if you ignored maxRequestLength settings, then please be sure to check it once. By default the maxRequestLength will be 4096KB (4 megabytes). After changing of that parameter, application started working well.
If you are more curious on it, here is the explanation:
At runtime the .Net framework checks the maximum size for the request object. This information will be obtained from the application's configuration file. In case, if this limit is not specified in web.config file, then it will be obtained from machine.config file. By default this limit is set to 4096KB. So by default you can upload only 4096KB file only! If you are interested to give a capability to the user to upload a file has greater size (> than 4096KB), then be sure to change 'maxRequestLength' value.
By the way, if you need here is the syntax:
Hope it helps to some one!
Also if any of you are already implemented a functionality of uploading large files, please share your experience on performance etc. Bcz.. in my client case, he is uploading files size ranging from 40MB and we are keeping them in database!
If you have any suggestions.. Please share them!!
Also I found related content on it at support, it's @ support link:
I read some interesting information on rover test on mars @ Bruce Williams [MS] blog.
My analogy would be different on this; probably Garbage Collector (GC) might not be functioning properly to delete unused or unwanted data from flash memory. You know what Software they used for this ; ) it could be that issue, probably next time they have to use .Net, since GC is more power full and robust in .Net.
Haa.. what do you say!! Could be that issue!! Now they are deleting the files by sending the commands since GC is not working efficiently!!!
If any one of you are living in VA or DC, its good news for you to update or share .Net knowledge. There is a new group (DC-ASP-Study) is starting today, link for the group you can get at DC-ASP-Study . I am also planning to be there. Also if any one of you planning to join with us today please join the group and drop an email, so that we will have some estimation on how many people are coming.