[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

404 IIS 7 ASP.NET Big File Upload Problem

Posted on 2011-02-22
3
Medium Priority
?
2,053 Views
Last Modified: 2012-05-11
I have the script at the bottom to upload files. If I upload files les than 20 mb around no problem upload perfect but if I put a 179 mb file or higher the IIS7 give me this error:
(404) Not Found. I made a trace of the error and found tell this:

MODULE_SET_RESPONSE_ERROR_STATUS
ModuleName RequestFilteringModule
Notification 1
HttpStatus 404
HttpReason Not Found
HttpSubStatus 13
ErrorCode 0
ConfigExceptionInfo  
Notification BEGIN_REQUEST
ErrorCode The operation completed successfully. (0x0)

Could you tell me what can I do to solve the problem?
Thank you here is the code

        String savePath = @"C:\inetpub\wwwroot\esp\alianza\actividades\nutricionIII\videostemp0\";



        if (FileUpload0.HasFile)
        {

            string FileExtention = System.IO.Path.GetExtension(FileUpload0.FileName);
            if (FileExtention == ".flv")
            {
         
                String fileName = FileUpload0.FileName;


                savePath += fileName;



 
                FileUpload0.SaveAs(savePath);

                UploadVideo0StatusLabel.Text = "Todo se subió correctamente";

               
            }

            else
            {
                UploadVideo0StatusLabel.Text = "is not flv";

            }



        }

    }
0
Comment
Question by:coerrace
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Author Comment

by:coerrace
ID: 34952557
HEre is my web.config. file I read somewhere to change  maxAllowedContentLength look:
<configuration>




      
      <system.web>
    <customErrors mode="Off"/>
            
            <authentication mode="Forms">
                  <forms name="TestAuthCookie" loginUrl="login.aspx" timeout="1000">
                        <credentials passwordFormat="Clear">
                              <user name="test" password="test"/>
                              <user name="test" password="test"/>
                        </credentials>
                  </forms>
            </authentication>
            <authorization>
                  <deny users="?"/>
            </authorization>
            <compilation targetFramework="4.0">
                  <assemblies>
                        <add assembly="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/></assemblies></compilation>
            <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID"/>
      </system.web>

    <system.webServer>
        <security>
            <requestFiltering>
                <!-- maxAllowedContentLength: bytes -->
                <requestLimits maxAllowedContentLength="3000000000"/>
            </requestFiltering>
        </security>
     
     </system.webServer>

</configuration>

But now give me this error with my web.config an I want 2 upload a file of 200 mb that´s it.

Maximum request length exceeded.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: Maximum request length exceeded.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[HttpException (0x80004005): Maximum request length exceeded.]
   System.Web.HttpRequest.GetEntireRawContent() +11314919
   System.Web.HttpRequest.GetMultipartContent() +221
   System.Web.HttpRequest.FillInFormCollection() +345
   System.Web.HttpRequest.get_Form() +137
   System.Web.HttpRequest.get_HasForm() +11317092
   System.Web.UI.Page.GetCollectionBasedOnMethod(Boolean dontReturnNull) +141
   System.Web.UI.Page.DeterminePostBackMode() +163
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +249
0
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 2000 total points
ID: 34953779
Open IIS 7 SnapIn
Select the website you want enable to accept large file uploads.
In the main window double click 'Request filtering'
once the window is opened you may see on top a list of tabs eg: file name extensions, rules, hidden segments and so on...
regardless the tab you select, in the main window rightclick and select "Edit Feature Settings" and modify the "Maximum allowed content length (bytes)"

0
 

Author Closing Comment

by:coerrace
ID: 34954747
Works Thank you
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
This course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Suggested Courses

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question