Home

Problem Migrating a WSP file from One Site Collection to Another

%3CLINGO-SUB%20id%3D%22lingo-sub-549188%22%20slang%3D%22en-US%22%3EProblem%20Migrating%20a%20WSP%20file%20from%20One%20Site%20Collection%20to%20Another%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-549188%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20recently%20moved%20our%20SharePoint%20capabilities%20from%20an%20on-premise%20SharePoint%202016%20environment%20to%20SharePoint%20Online.%26nbsp%3B%20As%20part%20of%20our%20build%2C%20we%20create%20subsites%20from%20a%20custom%20template.%20The%20template%20has%20lists%2C%20libraries%2C%20and%20web%20parts%20but%20does%20not%20have%20documents%20or%20contents.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIn%20order%20to%20create%20our%20test%20environment%20we%20set%20up%20new%20%22test%20site%20collections%22%20and%20we%20downloaded%20the%20WSP%20file%20from%20our%20new%20production%20environment.%20The%20idea%20is%20to%20use%20WSP%20file%20in%20the%20test%20environment%20so%20that%20we%20do%20not%20have%20to%20manually%20recreate%20a%20site%20that%20we%20would%20later%20use%20to%20create%20a%20template%20in%20TEST.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20first%20problem%20occurred%20when%20we%20uploaded%20the%20WSP%20to%20the%20solution%20gallery.%20We%20received%20the%20message%2Ferror%20below.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThis%20web%20template%20requires%20that%20certain%20features%20be%20installed%2C%20activated%2C%20and%20licensed.%20The%20following%20are%20blocking%20the%20application%20of%20the%20template%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EEnhancedTheming%20Feature%3C%2FP%3E%3CP%3ESharePointHomeCache%20Feature%3C%2FP%3E%3CP%3EMobileExcelWebAccess%20Feature%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThis%20template%20can't%20be%20used%20for%20this%20site%20collection%20until%20the%20issues%20above%20are%20resolved.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EJust%20as%20a%20note%2C%26nbsp%3Bwe%20do%20not%20enable%20any%20publishing%20features%20in%20our%20site%20collections%20to%20avoid%20the%20template%20save%20problem.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EOur%20IT%20team%20suggested%20that%20we%20run%20a%20PowerShell%20script%20to%20address%20the%20issue.%20We%20did%20NOT%20have%20to%20run%20this%20same%20PowerShell%20in%20the%20production%20environment%2C%20however%2C%20in%20production%2C%20we%20created%20the%20SharePoint%20site%20from%20scratch%20and%20saved%20it%20as%20a%20template%20(different%20process%3B%20we%20were%20not%20uploading%20the%20WSP).%26nbsp%3B%20After%20running%20the%20Powershell%20script%20we%20could%20then%20save%20the%20WSP%20file%20to%20the%20solution%20gallery%20and%20create%20a%20site%20using%20the%20uploaded%20template.%26nbsp%3B%20Our%20next%20step%20was%20to%20update%20a%20reference%20to%20a%20JavaScript%20file%20in%20the%20newly%20created%20site.%26nbsp%3B%20We%20then%20saved%20the%20site%20again%20as%20a%20template%2C%20but%20this%20time%20we%20encountered%20a%20new%20error%20--%20essentially%20it%20told%20us%20that%20a%20content%20type%20was%20duplicated.%26nbsp%3B%20We%20then%20went%20into%20the%20site%20that%20we%20are%20using%20for%20the%20template%20and%20noticed%20that%20even%20though%20we%20have%20a%20%22site%22%20level%20content%20type%2C%20the%20site%20also%20has%20the%20same%20content%20type%20repeated%20but%20this%20time%20the%20duplicated%20content%20type%20lists%20a%20different%20parent%20--%20the%20subsite%20name.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWe%20also%20tried%20to%20remove%20the%20content%20type%20from%20the%20site%20and%20resave%20as%20a%20template%2C%20but%20that%20did%20not%20solve%20the%20problem%20--%20we%20continued%20to%20see%20duplicate%20content%20types%20in%20any%20site%20we%20created%20from%20the%20template%20that%20originated%20from%20the%20migration.%26nbsp%3B%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EQUESTION%3A%20Why%20does%20SharePoint%20apply%20the%20content%20type%20at%20the%20subsite%20rather%20than%20using%20the%20parent%20level%20content%20type%20(which%20led%20to%20the%20duplication).%26nbsp%3B%20We%20have%20followed%20a%20similar%20process%20in%20the%20on-premise%20SharePoint%20(we%20downloaded%20and%20uploaded%20the%20WSP%20file)%20and%20did%20not%20have%20to%20run%20the%20Powershell%20script%2C%20nor%20did%20we%20encounter%20the%20duplicate%20content%20type%20error.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-549188%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EDeveloper%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EExtensibility%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-549246%22%20slang%3D%22en-US%22%3ERe%3A%20Problem%20Migrating%20a%20WSP%20file%20from%20One%20Site%20Collection%20to%20Another%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-549246%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F338290%22%20target%3D%22_blank%22%3E%40JulieBeaver%3C%2FA%3E%26nbsp%3BI%20would%20recommend%20using%20the%20approach%20described%20at%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fsharepoint%2Fdev%2Fsolution-guidance%2Fpnp-remote-provisioning%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fsharepoint%2Fdev%2Fsolution-guidance%2Fpnp-remote-provisioning%3C%2FA%3E.%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-714160%22%20slang%3D%22en-US%22%3ERe%3A%20Problem%20Migrating%20a%20WSP%20file%20from%20One%20Site%20Collection%20to%20Another%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-714160%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1096%22%20target%3D%22_blank%22%3E%40Dean%20Gross%3C%2FA%3E%26nbsp%3Bthank%20you%20for%20the%20tip.%20I%20am%20new%20to%20the%20correspondence%20through%20Microsoft%20and%20the%20reason%20for%20my%20delay.%26nbsp%3B%20We%20will%20take%20a%20look%20at%20the%20link%20you%20sent.%20Many%20Thanks!%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
JulieBeaver
New Contributor

We recently moved our SharePoint capabilities from an on-premise SharePoint 2016 environment to SharePoint Online.  As part of our build, we create subsites from a custom template. The template has lists, libraries, and web parts but does not have documents or contents. 

 

In order to create our test environment we set up new "test site collections" and we downloaded the WSP file from our new production environment. The idea is to use WSP file in the test environment so that we do not have to manually recreate a site that we would later use to create a template in TEST. 

 

The first problem occurred when we uploaded the WSP to the solution gallery. We received the message/error below. 

 

This web template requires that certain features be installed, activated, and licensed. The following are blocking the application of the template:

 

EnhancedTheming Feature

SharePointHomeCache Feature

MobileExcelWebAccess Feature

 

This template can't be used for this site collection until the issues above are resolved.

 

Just as a note, we do not enable any publishing features in our site collections to avoid the template save problem.

 

Our IT team suggested that we run a PowerShell script to address the issue. We did NOT have to run this same PowerShell in the production environment, however, in production, we created the SharePoint site from scratch and saved it as a template (different process; we were not uploading the WSP).  After running the Powershell script we could then save the WSP file to the solution gallery and create a site using the uploaded template.  Our next step was to update a reference to a JavaScript file in the newly created site.  We then saved the site again as a template, but this time we encountered a new error -- essentially it told us that a content type was duplicated.  We then went into the site that we are using for the template and noticed that even though we have a "site" level content type, the site also has the same content type repeated but this time the duplicated content type lists a different parent -- the subsite name.

 

We also tried to remove the content type from the site and resave as a template, but that did not solve the problem -- we continued to see duplicate content types in any site we created from the template that originated from the migration.  

 

QUESTION: Why does SharePoint apply the content type at the subsite rather than using the parent level content type (which led to the duplication).  We have followed a similar process in the on-premise SharePoint (we downloaded and uploaded the WSP file) and did not have to run the Powershell script, nor did we encounter the duplicate content type error.

 

 

 

2 Replies

@Dean Gross thank you for the tip. I am new to the correspondence through Microsoft and the reason for my delay.  We will take a look at the link you sent. Many Thanks! 

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
46 Replies
Extentions Synchronization
Deleted in Discussions on
3 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
flashing a white screen while open new tab
Deleted in Discussions on
14 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
29 Replies
Security Community Webinars
Valon_Kolica in Security, Privacy & Compliance on
13 Replies