Site Template Error Importing CMP file using Import-SPWeb PowerShell command-let in SharePoint 2010
CMP files allow you to move, import, and or export site collections across and within SharePoint farms. The tricky is that
you have to have an existing root site collection in order to be able to use the Import-SPWeb commandlet. Additionally this existing site template has to somehow match the site template of the site you are importing. This doesn’t really make sense to me because there is a –Force parameter you can use to overwrite the existing site, but it will not overwrite when the site definitions are different. The following is the error you would when you make that attempt on different site definitions:
“Import-SPWeb : Cannot import site. The exported site is based on the template XXXXX but the destination site is based on the template STS#0. You can import sites only into sites that are based on same template as the exported site”
There you have it!
The fix? Delete the existing site collection create a new one that matches the site definition of the site you are importing. A little annoying if you don’t really care about the site that exists.