Workaround for IIS to upload file size limits in windows2003

Source: Internet
Author: User
Tags metabase

Analysis:

you can tell from the error of the hint that the data sent by the Request is wrong.

suddenly think of Win2003 IIS6 the default received data is 200KB may be post data over 200KB

Workaround:

One, open IIS to view the properties on the local computer such as:

check allow direct edit configuration Database

Second, the C:\Windows\System32\Inetsrv open the metabase in the book. XML

find aspmaxrequestentityallowed= "204800"

change the back 204800 to a larger value.

and then save.

2.

issue: When uploading images, a single file upload is not a problem (picture size is not more than 200K), but choose Bulk upload (5 files, certainly more than 200K) when the following problems arise,

"Request object error \ ' ASP 0104:80004005\ '

Operation not allowed

upload.inc. "

Online Find the reason, found a solution, combined with several posts of the content of the following:

symptoms:
encountered the following error while uploading a file to the Windows 2003 Server + IIS 6.0 server:
Request object error \ ' ASP 0104:80004005\ '  
Action Forbidden
/upload.asp, line

Reason:
When using Windows2003 as a Web server, when you commit more content or upload large files, the following error occurs: Request object error \ \ ' ASP 0104:800,040 05\\ '    does not allow operation. That is what we call the ASP "0104:0x80004005" error, in fact, this is Microsoft in the 2003 system, accurately said to be a security IIS6 inside, it limits the size of the request, the maximum is 204800 bytes, that is, 200K, This minimizes attacks caused by previously too loose timeouts and limitations.


Technical background:
in IIS 6.0, the AspMaxRequestEntityAllowed property specifies the maximum number of bytes that can be used by an ASP request (request). If the Content-length header information Contains a request that is longer than the value of aspmaxrequestentityallowed, IIS returns a 403 error message.
This property value is similar to maxrequestentityallowed, but is requested for ASP. If you know your ASP application only needs to process very little request data, you can Wide the Web publishing Service The (WWW Publishing Service) level sets the global maxrequestentityallowed attribute to 1MB and sets the aspmaxrequestentityallowed to a smaller value individually.
   

Workaround:
Method One:
1. Open Internet Information Services (IIS) Manager first;
(local computer)----properties----allow direct editing of the metabase (N)
 
Be sure to tick "allow direct editing of configuration database (N)"

2. Then shut down the IIS Admin service in the service;
 
3, find the windows\\system32\\inesrv\\ under the MetaBase.xml, MetaBase.xml Open the book, find aspmaxrequestentityallowed to change him to the required value, the default is 204800, modify it to 51200000 (50M);

4. Then restart the IIS Admin service.


Method Two:
1, create a new text file;
Set Providerobj=getobject ("Winmgmts:/root/microsoftiisv2")
Set vdirObj=providerObj.get ("Iiswebvirtualdirsetting= ' W3svc/1/root '")
Ws Cript. Echo "Before:" & vdirobj.aspmaxrequestentityallowed
vdirobj.aspmaxrequestentityallowed=51200000
Vdirobj.put_ ()
Ws Cript. Echo "Now:" & vdirobj.aspmaxrequestentityallowed
2, save the above content as change.vbs;
3. Execute under CMD command line interface
CS Cript [Path]change.vbs

Method Three:
1. Download the tool Internet Information Services (IIS) 6.0 Resource Kit Tools, and install, remember to customize, there are some not used, here only use the metabase Explorer;

2. Start-Program Menu-iis resources-metabase Explorer, run Metabase Explorer;

3, modify the (local) \\LM\\W3SVC\\AspMaxRequestEntityAllowed property, modify to a larger value, such as 51200000 (50M).

If you do not stop the IIS service before you edit the file, you cannot save the modified file.

If you want to modify its configuration file while IIS is running, open IIS Manager, open the Internet Information Services Properties panel, check the Allow direct edit configuration Database to allow the IIS configuration to be edited while IIS is running Database configuration file.

Workaround for IIS to upload file size limits in windows2003

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.