• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 5010
  • Last Modified:

Maximum Request Length Exceeded when Deploying a Model to SSRS

Hi,

I have a fairly common problem that has been answer before here, but the answer does not work. The problem is that when I try to deploy a model from Visual Studio 2008 to our SQL Reporting Server, part of the model which is 13MB comes back with the error "...Maximum request length exceeded..." and will not transfer to the Reporting Server.

Now the common solution to this is to edit the httpRuntime maxRequestLength, and executionTimeout in either the we.config or the machine.config and change the limits to allow the files greater then 4MB to pass.

I changed the limits in both of them just to be sure. Did a restart on IIS. Tried to deploy the model again and came back with the same error. I also tried various sizes and am currently using 102400 (100MB) and 1200 seconds. Nothing seems to change anything.

My question would be, is there a work around for this problem if editing web.config and machine.config accomplish nothing?

Any help is appreciated and attached is the error code, cleaned up a little.
Error   1       

System.Web.Services.Protocols.SoapException: There was an exception running the extensions specified in the config file. ---> 

System.Web.HttpException: Maximum request length exceeded.    

at System.Web.HttpRequest.GetEntireRawContent()    
at System.Web.HttpRequest.get_InputStream()    
at System.Web.Services.Protocols.SoapServerProtocol.Initialize()    

--- End of inner exception stack trace ---    

at System.Web.Services.Protocols.SoapServerProtocol.Initialize()    
at System.Web.Services.Protocols.ServerProtocol.SetContext(Type type, HttpContext context, HttpRequest request, HttpResponse response)    
at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)     

D:\Data\Sql\ReportServices\Kronos Model Project\Kronos Model Project\Kronos - Tkcsdb.smdl       0       0

Open in new window

0
Kyle Lambert
Asked:
Kyle Lambert
  • 4
  • 2
1 Solution
 
Raja Jegan RSQL Server DBA & ArchitectCommented:
When you upload files greater than 4 MB ( 13 MB in your case) you might get this error..
And the fix given below:

http://www.element-it.com/system.web.httpexception-maximum-request-length-exceeded.aspx
0
 
Kyle LambertIT ManagerAuthor Commented:
I am aware that the standard fix for this problem is that the limit in web.config or machine.config is set to 4 MB.

However, if you go back and read my problem, the fix does not work. Even when the parameters are changed, the problem persists.

Is there a workaround for the problem if standard fix does not work?
0
 
Raja Jegan RSQL Server DBA & ArchitectCommented:
So, you have set it to 1024000(100 MB) now..
Have you restarted your IIS after doing this configuration to get it updated..
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
sureshchsahuCommented:
Go  to the following location
C:\Program Files\Microsoft SQL Server\MSSQL.3\Reporting Services\ReportManager\Web.config

Just add the maxRequestLength property here and set a size appropriate to you

The example below is 10mb
<httpRuntime executionTimeout="9000"  maxRequestLength="10240"/>
Hope this will help you.
1
 
Kyle LambertIT ManagerAuthor Commented:
rrjegan17,

After saving the config files, I have done a service level restart on IIS as well as a full server restart with no effect.

sureshchsahu,

The web.config file you mentioned has already been changed, and here is what it was change to:

<httpRuntime executionTimeout="9000" maxRequestLength="102400" />

That would be 100 MB if I'm not mistaken. But despite it being set to 100 MB in both machine.config and web.config, I still get the error trying to deploy a 13 MB file.
0
 
Kyle LambertIT ManagerAuthor Commented:
Alright,

The problem has been solved.

The root of the problem here was .NET. Nothing changed when editing the web.config files. However, there were two machine.config files on the server in the following locations:

C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\CONFIG

and

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG

The machine.config in the v1.1.4322 folder had exactly what I was looking for with comments on what to replace. But changes these settings will not affect anything. Changing the machine.config for v2.0.50727 will have an affect. The reason why this is, is because IIS was using ASP.net v2.0.50727 (but changing IIS to use 1.1 did not accomplish anything). Now the strange thing about the 2.0.5 version was that it did not have any of the parameters already in it that I needed, so I skipped over it when my search didn't find maxRequestLength (my mistake there).

HERE IS THE FIX

1. Go to C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG
2. Open machine.config
3. Search for <system.web>
4. Add in <httpRuntime executionTimeout="9000" maxRequestLength="102400" /> under the <system.web> (I added it right before the end)
5. Save
6. Restart IIS

That should fix the problem. I attached the code that I edited so you know what to look for. The first part is from the file that doesn't affect anything but tells you what everything does. The second part is the part that I edited and fix everything with.
--v1.1.4322

httpRuntime Attributes:
          executionTimeout="[seconds]" - time in seconds before request is automatically timed out
          maxRequestLength="[KBytes]" - KBytes size of maximum request length to accept
          useFullyQualifiedRedirectUrl="[true|false]" - Fully qualifiy the URL for client redirects
          minFreeThreads="[count]" - minimum number of free thread to allow execution of new requests
          minLocalRequestFreeThreads="[count]" - minimum number of free thread to allow execution of new local requests
          appRequestQueueLimit="[count]" - maximum number of requests queued for the application
          enableKernelOutputCache="[true|false]" - enable the http.sys cache on IIS6 and higher - default is true
          enableVersionHeader="[true|false]" - outputs X-AspNet-Version header with each request
        -->
        <httpRuntime 
            executionTimeout="1200"
            maxRequestLength="102400"
            useFullyQualifiedRedirectUrl="false"
            minFreeThreads="8"
            minLocalRequestFreeThreads="4"
            appRequestQueueLimit="100"
            enableVersionHeader="true"
        />

--v2.0.50727

	<system.web>
		<processModel autoConfig="true"/>
		<httpHandlers/>
		<membership>
			<providers>
				<add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="LocalSqlServer" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="true" applicationName="/" requiresUniqueEmail="false" passwordFormat="Hashed" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="7" minRequiredNonalphanumericCharacters="1" passwordAttemptWindow="10" passwordStrengthRegularExpression=""/>
			</providers>
		</membership>
		<profile>
			<providers>
				<add name="AspNetSqlProfileProvider" connectionStringName="LocalSqlServer" applicationName="/" type="System.Web.Profile.SqlProfileProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
			</providers>
		</profile>
		<roleManager>
			<providers>
				<add name="AspNetSqlRoleProvider" connectionStringName="LocalSqlServer" applicationName="/" type="System.Web.Security.SqlRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
				<add name="AspNetWindowsTokenRoleProvider" applicationName="/" type="System.Web.Security.WindowsTokenRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
			</providers>
		</roleManager>
		<httpRuntime executionTimeout="9000" maxRequestLength="102400" />
	</system.web>

Open in new window

0
 
Kyle LambertIT ManagerAuthor Commented:
This put me on the right path by letting me know that I can add in the lines when the parameters don't already exist
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now