The SharePoint Coffee House
I'd like some SharePoint with my coffee please...

Migration Issue: "One or more field types are not installed properly"

Friday, 5 August 2011 18:26 by Michael Mukalian

This was one that was wracking my brain, and then I came across a post that explains the issue and proposes a resolution.

In a nutshell, there's a hidden list at the top-level site of a site collection named Relationships List.  This list is an internal list that stores all of the metadata involved in the creation of Variations.  Apparently during the migration (in this case I was doing a Content DB migration/upgrade) this list wound up not migrating correctly, and it didn't have the necessary GroupGuid column.  The article says that you can download a tool from codeplex to perform the migration of this list, however, given where I was doing this work, external tools weren't an option.  So...

Enter PowerShell!

(I'm really liking PowerShell more and more...granted I'm a devhead at heart, but you're able to quickly address issues that occur in your implementation in a quick manner, with repeatable solutions)

So...how to do this?  Well, deleting/migrating the list wasn't really an option, and given that the field type of the column isn't available through the UI (it's a GUID, as well as being a hidden column), I turned to PowerShell to create it.  So...let's take a look...

Basically, I took a look at the list in a working site collection and grabbed its properties, and used it to create a working script to add the missing field to the site collection with the issues.  It's relatively smiple...grab your web, grab your list, create the field, add it, modify some properties, and you're good to go.  Running the script enabled the site collection that had the above error work right away.  So, take a peek at the below, and enjoy. - M

# load up SP PS Snappin            
Add-PSSnapin Microsoft.SharePoint.Powershell            
# get web            
$web = Get-SPWeb -Identity http://websiteUrl            
# get list            
# note that the code below isn't optimized            
# but just to get the list quick 'n' dirty            
$list = $web.Lists["Relationships List"]            
# create Guid SPFieldType field            
$guidField = [Microsoft.SharePoint.SPFieldType]::Guid            
# add the created field to the list, the name 'GroupGuid' is necessary            
# and it's required            
$list.Fields.Add("GroupGuid", $guidField, $true)            
# once added, let's grab it as a SPField            
$groupGuidField = $list.Fields.GetField("GroupGuid")            
# set its ShowInEditForm property to False            
$groupGuidField.ShowInEditForm = $false            
# add an index on this field            
$list.FieldIndexes.Add($groupGuidField)            
# cleanup            
$web.Dispose()            
# remove SP PS Snappin            
Remove-PSSnapin Microsoft.SharePoint.Powershell

Currently rated 3.6 by 7 people

  • Currently 3.571428/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5
Categories:   2010 | Migration | PowerShell
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

How to Migrate SharePoint From One Server to Another

Monday, 2 February 2009 14:56 by Michael Mukalian

I've been seeing lots of questions around this on the boards, and when I do I refer them to Chris Hernandez' awesome post (see below) on taking MOSS from a standalone setup to a farm one.  The steps apply for both WSS and MOSS, just for WSS you don't have the Shared Services stuff.  In a nutshell...

  1. Set up your target environment farm (remember, Advanced/Complete!)
  2. Use your SQL tools to backup the databases on the source server, and restore them to the target one
  3. Use the STSADM Command Line utility to attach the restored databases to the relevant areas

 

Even though his post is from '07, it's still valid, and has helped out a lot.  Check out his detailed steps in the link below...enjoy! - M

 

Migrating Microsoft Office SharePoint Server (MOSS) from Standalone to Farm Install

Currently rated 4.0 by 1 people

  • Currently 4/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5