I have noticed that during a Site Deployment import, there are HTTP 500 errors being thrown on the site. Once the import was complete, the site was back to normal.
We think that some of our templates were expecting certain objects (i.e. channels, resources, etc.) to be available, but during import the expected objects may not have been present; this results in ASP scripting errors (HTTP 500) (unless there is template code checking wherever an object is available).
What kind of prescriptive guidance is there for doing imports? Until now I had always assumed that it should be fairly safe to perform an import on a live site. If this is not true – and we should assume that a site is taken offline during the import – this creates a fairly significant availability issue for shops that want to create a Development - Staging – Production scenario.
In MCMS 2002, this problem has been greatly minimized. Site Deployment is faster and therefore these types of issues are not as much of a concern.
For large site updates, a long import can cause these problems by locking objects. A workaround would be to import into another MCMS server running from a different database and then flipping the database connection through the Site Configuration API. Microsoft Internet Information Server (IIS) will need to be stopped and started.
So pages that are not in the cache will not be rendered, and any page that makes calls to the database (specifically the searches like custom prop searches and approval searches) will fail as well.
Site deployment does not import files at all. So if your templates have references to things on the file system (.GIFs, .INCs, etc) and you are changing your templates, there may be some errors thrown while import is going on. The problems would start when you changed the include files and continue until the new templates were in place. Or they would start when the new templates arrived and continue until the new include files were available. Unfortunately, the only way around this is to update your site offline so that you can be sure the include files and the templates arrive at the same time.
This would apply whenever you are changing code assets of the site - which is probably a pretty major revision. In those cases, consider doing rolling updates of your site using App Center.
For smaller updates to the site, site deployment should work well. Updates to content and anything else that is in the MCMS repository are handled just fine while the site is live. The availability of resources, channels, etc is managed so that objects with dependencies are there when asked for. Odds are it was code assets that caused the problems.
[Back to Top]
Topic: Content not deployed to destination site
When deploying content from an authoring environment to a production (live) environment, some pages are not updated properly. What can cause this?
Answer
The most probable reason for the updates not to be seen on the destination server (production/live system) is that new content was not exported from the authoring server.
When updating content an author will do one of the below action that will set the page back to a Waiting for Moderator approval status:
- Set the expiry date or set any property of the page
- Modify page content, any placeholder and save the page
As with MCMS 2002 only approved items will be exported, the updated content will not be exported unless it is submitted again for approval and approved. Failing to approve again the content, the export package will not include any change done on the item and thus will leave the content unchanged from its previous state on the destination server.
See also in the MCMS docucumentation:
\Troubleshooting MCMS 2002
\Troubleshooting MCMS Site Authoring Tools
\Content Revisions Do Not Appear on Live Site
If an author adds some information to a page that was previously published and then saves the page, the new content will appear in the edit site only. The live site will not display the new content until it has been approved.
\Managing Site Structure and Workflow
\Deploying web Site Content
\About Exporting and Importing Objects
Make sure that all objects to be exported have been approved by your assigned approver before exporting them. Any object that is submitted but not approved will not be exported. Objects on the destination server with dependencies to objects being imported will be affected by the import operation. For example, if a template is replaced during import, all of the pages using the template will automatically use the new template.
\Deploying MCMS 2002
\Types of Site Deployment
\Incremental Site Deployment
You perform an incremental site deployment to export only MCMS-managed objects that have changed since the last deployment. MCMS managed objects include channels and approved pages, as well as the resources that they depend on.
[Back to Top]
Topic: Deleted items are not deployed
We are using incremental deployment scripts to deploy the content of our Web site to our production server. Usually we limit the deployment by specifying a channel start GUID. When using such a script items deleted in Site Manager do not get deployed to the production server. How can we solve this problem?
Answer
The reason for this is that deletion in Site Manager is not really a delete. It is actually a move to the Deleted Items folder. If you purge this folder then the item gets deleted.
Regardless of whether the item is still in the Deleted Items folder or already purged it no longer has an association with your start channel. To ensure that the items deleted in Site Manager really get deleted on the production server you have to manually deploy the Deleted Items folder.
Use the script below to export the Deleted Items folder to an SDO file:
set pCmsDeployExport = CreateObject("CmsDeployServer.CmsDeployExport.1")
pCmsDeployExport.AuthenticateAsCurrentUser()
strPackageFileName = "your-filename"
strReportUrl = pCmsDeployExport.Export(strPackageFileName, 0,"{E4D1911E-9DD3-11D1-B44E-006097071264}")
set ie = CreateObject("InternetExplorer.Application")
ie.Visible = True
ie.Navigate("http://localhost" & strReportURL)
[Back to Top]
Topic: Error message: "ASP 104 - Operation not allowed"
I am using MCMS 2002 SP1 on Windows Server 2003. I am getting the following error when trying to import an SDO Package (I can export fine):
Error: 0
Description: 007~ASP 0104~Operation not Allowed~
Severity: 5
Source: NRXMLMarshaler.NRFileUploadResponse.1
Debug info: N/A
Extra info: N/A
Client Source: CImProgress::ProcessPackage
Recommended Action: N/A
Answer
This is caused by a new feature in Windows 2003. In Windows Server 2003, you can now configure the maximum amount of data for resource uploading within IIS, but the default limit is too low for MCMS site deployment.
To resolve this problem follow the instructions in the MCMS 2002 SP1 Readme and in the following KB article:
824471 - You may receive an error message when you try to run Site Deployment against an SDO package that is larger than 200 KB
[Back to Top]
Topic: Error message: "Fatal Execution Engine Error" when running SDAPI script in a Terminal Server Window
I have created a VBS script to do site deployment. This script works fine when being executed in a command window on the console of the server machine. But executing it in a Terminal Server session a message box with the following message comes up: “Fatal Execution Engine Error (0x7927c038)”.
Answer
The .NET policy through Terminal Server restricts access to the Microsoft.ContentManagement.Common assembly. To resolve the issue, CSCRIPT.EXE needs to be correctly configured to allow it to use the MCMS assembly from within a Terminal Server session:
- Open Programs\Administrative Tools\Microsoft .Net Framework 1.1 Configuration
- Right click "Application"
- select "Add"
- Click the "Other" button
- Type %systemroot%\system32\cscript.exe in the File name box and press "OK"
- Right click "Configured Assemblies" and click the "Add" button
- Click "Choose Assembly" and select "Microsoft.ContentManagement.Common" assembly and click on the "Select" button
- Click on the Finish button
[Back to Top]
Topic: Error message: "File or assembly name .dll, or one of its dependencies, was not found."
I am seeing this error message "File or assembly name <name>.dll, or one of its dependencies, was not found. (<name> is random)".
Error ID: -2147352567
Source File:
Source Method: NRSiteDeployServer
Description: File or assembly name ifdy1rnx.dll, or one of its dependencies, was not found.
What could be wrong?
Answer
Here are some things to consider:
- This error can occur if the ASPNET account doesn't have permission to write to the WinNT\Temp (system temporary) directory.
- This error can also happen if you run an MCMS application compiled for .NET framework 1.1 on .NET framework 1.0
[Back to Top]
Topic: Error message: "Overflow: 'CDate'"
On one of our MCMS machines, we always get an error upon export and import from Site Manager. The import seems to work, but the report fails.
The report generates the following error:
------------------------------------------
Generated on: Microsoft VBScript runtime error '800a0006'
Overflow: 'CDate'
/NR/System/ClientUI/Report/SDReportInfo.INC, line 47
------------------------------------------
What is making the date conversion fail?
Answer
This can happen when the locale on used by the ASP engine is not the US-English locale. Use the following steps to resolve the problem.
For Windows 2000:
- Add the following regkey according to KB306044
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\OLEAUT\
VarConversionLocaleSetting = 2 (DWORD)
(you might need to create the OLEAUT key if it does not already exist)
- Control Panel => Regional Options
- On the General tab select "Set default..." and change the language to "English (United States)"
- Restart machine
For Windows Server 2003:
- Add the following regkey according to KB306044
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\OLEAUT\
VarConversionLocaleSetting = 2 (DWORD)
(you might need to create the OLEAUT key if it does not already exist)
- Control Panel => Regional and Language Options
- under the "Regional Options" tab change "Standards and Formats" to "English (United States)"
under the "Advanced" tab change "Language for non-Unicode programs" to "English (United States)" and click the apply to "default users and account settings" in advanced tab.
- Restart machine
[Back to Top]
Topic: Error message: "The underlying connection was closed."
Side Deployment fails on my box. In the Event log I see the following message: "The underlying connection was closed." How can I solve this?
Answer
If this problem occurs on Windows Server 2003 with II6 then the problem is most likely a restrictive configuration of IIS. Check out KB 826210 to resolve the issue.
If this does not solve the issue or the problem happens on Windows 2000 then the problem might be a problem in the network connection (e.g. a failure on the network card, a misconfiugred firewall, ...)
[Back to Top]
Topic: Error message: "There is an error in XML document"
I get the following error during a Site Deployment import:
Error Information
An error has occurred that has interfered with the generation of this report. Please try the operation again, and contact your system administrator should this error persist.
Error ID: -2147352567
Source File:
Source Method: NRSiteDeployServer
Source Line: 0
Description: There is an error in XML document (10, 30).
Recommended Action:
Answer
The XML Parser is complaining about an invalid character from the source Server. Check your application log to find the precise location of the System.Xml.XmlException and then search the XML file (open it in Internet Explorer). This will help you find out what the error is and clean the posting.
[Back to Top]
Topic: Error Message: "This request requires buffering data to succeed"
When running Site Deployment import using Site Manager or client-side SDAPI I receive the following error message: "This request requires buffering data to succeed".
What can I do to resolve this problem?
Answer
This problem can occur if anonymous access has been removed from the /NR/System/SdUpload virtual directory in Internet Information Server (IIS).
Please ensure that anonymous access is enabled on /NR and all included subdirectories and also on /MCMS and all included sub directories to allow Site Manager and Site Deployment work correct.
[Back to Top]
Topic: Error when non-administrator executes SDAPI script
When a user that is not a local administrator trys to execute a server-side SDAPI script on the MCMS server machine he gets the following error message:
C:\export-server.vbs(8, 5) AEServerObject.dll: Extended error: [What=''] [LCID='1033'] [SourceFile='nrmetadatakey.cpp'] [SourceFileLine='279'] [DebugInfo=''] [RecommendedAction=''] [ExtraInfo=''] [UniqueErrorId='10004'] [Severity='5'] [Source='AEServerObject.dll'] [CategoryId='0']
Is it required to be a local administrator to do the export?
Answer
No it is not required to be a local administrator. But in order to execute the Authenticate... method in the script it is required that the user running the script has the SeImpersonatePriviledge.
To assign impersonation privileges
- Click Start, click Control Panel, click Administrative Tools, and then click Local Security Policies.
- In the Local Security Settings window, expand Local Policies, click User Rights Assignment.
- In the User Rights Assignment folder, right-click Impersonate a client after authentication, and then click Properties.
- In the Properties dialog box, click Add User or Group.
- In the Select Users, Computers, or Groups dialog box, add the appropriate user or group, and then click OK.
- In the Properties dialog box, click OK.
[Back to Top]
Topic: Exception when using C# SDAPI application in a Terminal server session
When using server side site deployment in my C# application to import an SDO file from inside a Terminal Server session then I get the following result:
Fatal Execution Engine Error (0x7927bb38)
when calling into the CmsDeployImport object.
This works fine when logging on locally to the machine. What's wrong?
Answer
This can be caused by the following reasons:
- The account used had no write access to the %temp% directory
- The .net policy didn't allow the assembly to be used in the TS context.
You have to add the application in the in 'Microsoft .NET Framework 1.1 Configuration' to the trusted applications list.
[Back to Top]
Topic: Export to Object Package filename.sdo failed
I see this Error when I export using Site Deployment: "Export to Object Package <filename>.sdo failed"
Answer
There are multiple reasons for this problem:
- If SQL server and MCMS server are installed on the same box, then ensure that the "shared memory protocol" is disabled in the "SQL client network utility".
- The amount of data or the time required for the export exceeds the limitations set in the ..cmsroot$\server\mcms\web.config:
<httpRuntime executionTimeout="3600"
maxRequestLength="1024000"
useFullyQualifiedRedirectUrl="false"
minFreeThreads="8"
minLocalRequestFreeThreads="4"
appRequestQueueLimit="100"/>
(the settings here are for a one hour timeout and 1 GB data)
[Back to Top]
Topic: How is the node cache affected by database import?
How is the node cache refreshed? For example, if I have all my nodes in the cache, then I make a change (e.g. an import). Is the node cache actively managed? Will MCMS mark the affected nodes as changed?
Answer
The MCMS node cache is a map of node GUIDs to nodes. The nodes at this level are totally independent of each other. A change to one does not impact any others. When a change to a particular node is detected (i.e. an entry in the database change table), the node is tossed out of the cache and is re-read when it is next requested.
When a change to any node is detected, the upper level (output, fragment, etc.) caches are cleared, because we don't know the dependencies involved. For example, what URLs are invalid because of a name or state change, what additional channels have to be added to navigation, etc.
The MCMS server checks for updates in the database once every 6 seconds during normal runtime - and on the start of each session in design time. This way, we can make sure that edits are always occurring with the current data and also prevent production database stress.
[Back to Top]
Topic: Is it possible to export a resource gallery or a template gallery using Site Deployment API?
Is it possible to export a resource gallery or a template gallery using the Site Deployment API?
Answer
The Site Deployment API only can export channels and postings and resources associated to these postings. Images inside a Placeholder on an exported page will be exported but it is not possible to export resources or templates directly.
This can be done using the Site Manager.
[Back to Top]
Topic: Problems with client-side Site Deployment API within ASP.NET
I'm using the client-side Site Deployment API from within an ASP.NET application. When I do this, Internet Information Server (IIS) hangs on me. What could be wrong?
Answer
This has been fixed in MCMS 2002 Service Pack1. You should not experience this problem when MCMS 2002 SP1 is installed.
The issue was that the MCMS 2002 client-side Site Deployment API was not allowed within a service (including IIS or Scheduler Service). The reason for this was that the client-side Site Deployment API used WININET.DLL. This DLL cannot be used within a service.
[Back to Top]
Topic: SDAPI access denied
When using the Site Deployment API (SDAPI) in an ASP.NET application, I cannot import the SDO file. I get an access denied error. The same code works in a console application. What's wrong?
Answer
Here are some things to consider:
- You may be using AuthenticateAsCurrentUser. This will not work in an ASP.NET environment. Instead use the following code:
WindowsIdentity ident = HttpContext.Current.User.Identity as WindowsIdentity;
cmsDeployImport.AuthenticateUsingUserHandle(ident);
- The ASPNET_WP account may not have read access to the SDO file.
[Back to Top]
Topic: Site Deployment created an invalid SDO file
Site Deployment Export does not create a valid SDO file. Instead the file contains HTML code. What could be wrong?
Answer
Here are some things to investigate:
- This will happen if the /NR and /MCMS virtual directories do not have anonymous access enabled or if the phyiscal files and directories behind the /NR and /MCMS directories do not have "everyone read" ACL permissions set.
- Open the "SQL Client Network Utility" and disable "shared memory protocol". Also move "named pipe" to the top of the list of supported protocols.
- Increase the node cache size in SCA. It has been reported that a small Node Cache size can cause this.
- Check that the "rdonlyres" directory within /NR virtual directory is a virtual directory and not a physical folder (the icon needs to be a folder with a small globe in the lower right edge). If it is a physical folder create a new virtual directory below /NR with name "rdonlyres" which points to "\program files\microsoft content management server\server\rdonlyres"
- Check that the /MCMS virtual directory is a web application (the icon needs to be a box with a globe in it)
- Check that the "SiteDeployment" folder in /MCMS is a web application and not a physical folder (the icon needs to be a box with a globe in it).
- Check that a virtual directory named "CMS" exists in the /MCMS web application. Ensure that it points to "\program files\microsoft content management server\server\IIS_CMS" and is a virtual directory (the icon needs to be a folder with a small globe in the lower right edge)
- ensure that the ASPNET account has full control permissions on the TEMP directory and the "rdonlyres" directory within /NR virtual directory.
[Back to Top]
Topic: Site Deployment does not export correctly. No postings are included, only Folders/Channels.
Site Deployment does not export correctly. No postings are included, only folders and channels. What could be wrong?
Answer
Open the "SQL Client Network Utility" and disable "shared memory protocol". Also move "named pipe" to the top of the list of supported protocols.
[Back to Top]
Topic: Site Deployment report does not list the exported items on large exports
When I create a large SDO file with many thousand items the export report does not list the exported content.
How can I correct this problem?
Answer
This is caused by a design limitation in the product. Site Deployment will not list the exported items if the total number of exported items is higher than 10.000.
A workaround would be to ensure that less than 10.000 items are being exported.
[Back to Top]
Topic: The handle is invalid.
I'm receiving the following error message during Site Deployment in Site Manager:
Error: 6001
Description: The handle is invalid.
Severity: 5
Source: aesecurityclient.dll reposturl.cpp 323
Debug info:
Extra info:
Client source: ClmProgress::DoReport
Recommended Action:
What is the solution for this problem.
Answer
- Please check if this problem only occurs to one specific user. Try to logon to your machine with a different user and check if the problem is gone. If yes, then this can be caused by a corruption in the user profile. Please remove the old profile and check if the problem is gone.
- This can also be caused by a timeout happening while doing Site Deployment. Please check out the article discussing Timeouts in this section.
[Back to Top]
Topic: The XML parser could not parse the tag it was given
I see this error message during an SDO Import: "The XML parser could not parse the tag it was given". What could be wrong?
Answer
There are multiple different possible reasons and solutions for this error. Some issues are fixed in CMS 2002 Service Pack 1 - so it is highly recommended to install SP1.
The Site Manager application expects to receive XML messages from the MCMS server. This error generally occurs when the Site Manager receives an HTML error message from the MCMS server. In recent versions of MCMS, this error message was enhanced so that the HTML is included in the error message. Make sure you read this entire error message, it can be your best clue for resolving this issue.
Other things to consider:
- The SDO file being imported may be invalid. This can be checked with WinZip. If Winzip is able to open the SDO file the SDO file should be ok. If the SDO file is invalid check on the exporting machine if the /NR and /MCMS virtual directory has anonymous access enabled (required) and that the physical file behind the /NR and /MCMS directory have "everyone read" ACL rights.
- Memory problems. Increase the virtual memory of the MCMS server.
- Internet Explorer caching issues. Clear the Internet Explorer browser cache, especially the content of the Content.IE5 hidden directory: Delete all files and folders in the \documents and settings\<UserName<\Local Settings\Temporary Internet Files\Content.IE5 directory (including hidden files).
- Clearing the MCMS memory cache often solves this problem.
- Check for permission problems. Check the permissions on the TEMP directory and on the physical files behind the /NR and /MCMS virtual directories on the importing server. Also ensure that anonymous access is enabled on the /NR and /MCMS virtual directory.
- The Microsoft Internet Explorer Webcontrols may not be installed correctly or the wrong version of the Webcontrols are installed. Uninstall the webcontrols and install the version shipped on the MCMS 2002 server CD.
- Ensure that the user doing the import is a MCMS administrator.
- If the MCMS server and SQL server are installed on the same box ensure that shared memory protocol is disabled in the "SQL Client Network Utility". In addition move "named pipe" communication to the top.
- Ensure that the user listed in the ProcessModel section of the Machine.Config file has adequate rights (also read access to the SDO file).
- Ensure that the SQL Server machine has enough per seat licenses configured.
- Check if a web.config and/or global.asax file exist in the root of your web site. Invalid entries in these files might cause this error. Please remove them and test if this solves the problem. If you need these files for other applications, please check all entries and correct the errors.
[Back to Top]
Topic: Timeout when importing or exporting an SDO file.
I'm seeing a timeout when importing or exporting SDO files. Other error messages I have seen in this context are "The handle is invalid.", "General network error" and "The Underlying Connection Was Closed".
Answer
- It is better to use the server side APIs instead of client-side API because you are not subjected to problems associated with going through a web server. The server-side API is a COM API that directly talks to the MCMS server COM object.
- When importing large SDOs through Site Manager or the client-side API, you may run into the problem of the ASP.NET process timing out before the process is complete. To extend the various timeout parameters:
- On the MCMS server, open the machine.config file located in %windir%\Microsoft.Net\Framework\v1.0.3705\CONFIG.
In the <processModel> tag set responseDeadlockInterval from "00:03:00" to "12:00:00" (12 hours timeout for any aspnet_wp process).
- On the MCMS server, open the web.config file located in <MCMS Dir>\server\mcms\sitedeployment.
In the <httpRuntime> tag:
set executionTimeout to "43200" (12 hours timeout for this application)
- If you plan to import a big SDO file, using the Site Manager or the client-side API, configure the following, on the MCMS server machine. This web.config setting controls upload size:
In the tag:
set maxRequestLength = "...", 1024 = 1 Mb, 102400 = 100 Mb. If the SDO is 3Mb in size then use 4096 as the value (4096k > 3 Mb, 4096 = 4 x 1024).
- You may run into the error that the aspnet_wp process uses more than 60% (default) of the system memory at which ASPNET kills the process. This default can be changed by editing the machine.config file at %windir%\Microsoft.Net\Framework\v1.0.3705\CONFIG.
In the <processModel> tag:
set memoryLimit="" “80” = 80% and is a good figure for me.
- If the MCMS server is running on the same system as the SQL server (i.e. the MCMS server is a local “client” of Microsoft SQL Server™):
Adjust the SQL Client Network settings as follows (this is accessible through the “Microsoft SQL Server\Client Network Utility” Start Menu item:
- turn off: “Enable shared memory protocol”
- switch the order of the “Enabled protocols by order” so that “Named Pipes” comes before “TCP/IP”
- restart Microsoft Internet Information Server (IIS)
This cures some “General network error” problems that some have been seeing and some problems with imports failing right when the merge happens.
This also cures problems of the form:
Description = "Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding."
Source = ".Net SqlClient Data Provider"
Note: This error occurs regardless of the size of the DB.
- The export initially produces a huge folder in the \server\temp that gets compressed into a smaller SDO file.
Make sure that this temp directory has enough space to contain this folder and the two copies of the file that will be produced (this is explained later). This is hard to estimate but a 500,000 posting MCMS db generates a 253 Mb file which, when uncompressed, consumes about 2Gb. After the file is produced in the temp directory it is moved to the rdonlyres directory where it gets downloaded to the client that performed the export. Make sure that there is room on the server for the copy to succeed (from temp to rdonlyres) and there is room for the client to hold the downloaded SDO file.
A rule of thumb for exporting/importing a huge SDO file would be: = 20 x + 2 x = 22 x . I’ve seen cases where 50x the size of the SDO file must be allocated.
- Sometimes during a large export the Site Manager will timeout, reporting some error in reposturl.cpp. The export is still happening on the server side and eventually the SDO file will be produced in the /nr/rdonlyres directory.
- In IIS the virtual /NR directory must have anonymous access enabled. The physical file folder (located at MCMS install dir\Server\IIS_NR) requires read permissions for 'Everyone'.
[Back to Top]
The information contained in this document represents the current view of
Microsoft Corporation on the issues discussed as of the date of publication.
Because Microsoft must respond to changing market conditions, it should not be
interpreted to be a commitment on the part of Microsoft, and Microsoft cannot
guarantee the accuracy of any information presented after the date of
publication.
This White Paper is for informational purposes only. MICROSOFT MAKES NO
WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS
DOCUMENT.
Complying with all applicable copyright laws is the responsibility of the user.
Without limiting the rights under copyright, no part of this document may be
reproduced, stored in or introduced into a retrieval system, or transmitted in
any form or by any means (electronic, mechanical, photocopying, recording, or
otherwise), or for any purpose, without the express written permission of
Microsoft Corporation.
Microsoft may have patents, patent applications, trademarks, copyrights, or
other intellectual property rights covering subject matter in this document.
Except as expressly provided in any written license agreement from Microsoft,
the furnishing of this document does not give you any license to these patents,
trademarks, copyrights, or other intellectual property.
© 2004 Microsoft Corporation. All rights reserved.
Microsoft, ActiveX, Visual Studio, Windows, and Windows Server are either
registered trademarks or trademarks of Microsoft Corporation in the United
States and/or other countries.
The names of actual companies and products mentioned herein may be the
trademarks of their respective owners.
© 2004 Microsoft Corporation. All rights
reserved. |