Maximum Request Length Exceeded for KCN Server Remote Site Synchronization

Question/Problem:


When processing batches from a Remote Site to a Central Site, then an error is shown in the ACIW Logs and the Batch is not uploaded to the KCN Server.


"System.Web.HttpException (0x80004005): Maximum request length exceeded"


The full error is as follows: 

System.Web.HttpException (0x80004005): Maximum request length exceeded.
at System.Web.HttpRequest.GetEntireRawContent()
at System.Web.HttpRequest.get_InputStream()
at Kofax.ACIS.IISForwarder.Post.PostFile(HttpContext oClientContext, String strFilePath, Int32 nACICacheID)
at Kofax.ACIS.IISForwarder.Post.ProcessRequest(HttpContext oClientContext)


Answer/Solution:


The error message indicates there is a limitation for the Maximum Request Length, an IIS configurable setting. 

  • Review the Web.Config file for the ACI web site and effect changes, as follows: 
    1. maxRequestLength executionTimeout IIS Settings: IIS6 and IIS7 are capped at 4MB by default, which can be extended by adding or modifying the value.  Under the system.web section, add the line: 
      <httpRuntime maxRequestLength="204800" executionTimeout="600"/>


      The value of maxRequestLength is in kilbytes; executionTimeout is in seconds.  
       
    2. maxAllowedContentLength IIS Setting: IIS 7 and IIS8 introduces an additional constraint, also configurable in the web.config file by adding a new section (See Tip), or modifying the values: 
      <requestLimits maxAllowedContentLength="209715200"/>


      The value of maxAllowedContentLength is in bytes
<system.webServer>

   <security>

      <requestFiltering>

         <requestLimits maxAllowedContentLength="209715200"></requestLimits>

      </requestFiltering>

   </security>

</system.webServer>
  • NOTE: The value of maxAllowedContentLength is in bytes.
  • Save the Web.Config file and complete an IISRESET from an elevated command prompt or through IIS Manager Console.
  • Retry the Remote Synchronization Agent to confirm the batch is processed to the KCN Server.