search cancel

Error: HTTP Request failed: Maximum request length exceeded – during import of exported XML.

book

Article ID: 163142

calendar_today

Updated On:

Products

IT Management Suite

Issue/Introduction

When attempting to import a Managed Software Delivery policy, previously exported from another SMP, the attempt failed with error “”

The SMP logs showed an error similar to the following error trace (excerpt):

Module: w3wp.exe
Source: WebApplication
Description: HTTP Request failed: /Altiris/NS/Admin/Menu Items/ImportItem.aspx?ParentGuid=122e242f-1469-47c6-b647-764ac3a581d0

Maximum request length exceeded.

   [System.Web.HttpException @ System.Web]
   at System.Web.HttpRequest.GetEntireRawContent()
   at System.Web.HttpRequest.GetMultipartContent()
   at System.Web.HttpRequest.FillInFormCollection()
   at System.Web.HttpRequest.EnsureForm()
   at System.Web.HttpRequest.get_Form()
   at System.Web.HttpRequest.get_HasForm()
   at System.Web.UI.Page.GetCollectionBasedOnMethod(Boolean dontReturnNull)
   at System.Web.UI.Page.DeterminePostBackMode()
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Cause

The XML content was very large. Much larger than IIS was capable of handling, even when adjusting the maximum request length parameters as per the following article:

http://www.smarterasp.net/support/kb/a1544/how-to-resolve-maximum-request-length-exceeded.aspx

Resolution

Instead of attempting to use the Console UI to import the XML content, instead use ImportExportUtil.exe which will import the items in the XML in small groups rather than all at once.

Usage:

  1. Save the xml file to “C:\Temp” or a folder of choice
  1. Open a command prompt on the SMP server, and go to “...\Program Files\Altiris\Notification Server\bin\Tools” (or similar path—depending on where the SMP was installed to)
  1. Run the following command: 
    ImportExportUtil /import "c:\temp\Filename.xml"