Transferring a site from WSS 3 to MOSS 2007 - Part 1
Last week I was working with a client, on moving their site from a WSS 3.0 server to a MOSS 2007 server.
Usually, this shouldn't be too complicated, or too difficult, but with this one I had all kind of errors and bugs, which made this one quite a challenge.
There're millions of posts out there, explaining how to do an import, so I'm not going to write that kind of a post. Instead, I will write a few of the things I've stumbled upon, as a sort of a reference list, or a one-stop-for-errors-post.
Due to the length of the post, I'll split it into two parts: Migration plan, and Various errors and solutions while exporting.
So this is part one:
Create a migration plan
The WSS site I needed to migrate, was created by the company's employees, which didn't know much about SharePoint when they started. Instead, they used the site to learn, and did many experiments. Due to that fact, I had two problems:
- There were no documentation for what was installed in terms of hot-fixes, templates, etc.
- There were many customizations which wasn't needed, or was not in use.
When I've tried to import an exported site, to the new server, I've started to get all kind of errors, about missing content types, and missing templates.
I didn't think such a move will work, but I wanted to try in anyway, testing my luck :)
Therefor, what I did, and what I think is very important to any migration, is to plan the process.
My basic guidelines, look something like this:
- Make sure you are the site-collection's administrator, on both machine.
- Go over the old site, play with it a bit, make sure you know what content resides in what sub sites, etc.
- Make sure both servers are running the same versions, same hot-fixes are installed, etc.
You can check it by going to "Central Admin -> Operations -> Servers On Farm" the version number should be listed there.
In the above image, you can see that my server version is 12.0.0.4518, that means that I haven't installed SP1 yet. With SP1, I would have 12.0.0.6219. A list of all the hot-fixes and version numbers can be found here:
What version of WSS/MOSS are you running?
- Make a list of custom templates, custom content type, etc.
One method of getting a list of custom content types, is to go to your Site Actions menu -> Site Settings -> Modify all site's settings. Browse to the "Site Content Types" gallery, under "Galleries". If you're lucky, all the content types will be located in a special group.
Also, you might want to check for deployed solutions, to get a list of custom site templates installed, features, and so on. Go to "Central Admin -> Operations -> Solution Management" to check that.
- Make sure all the documents and content are checked in!
Go to "Site Action Menu -> View all site content" and go folder by folder. Ask people to check in their file, or just check in all the files which are checked out using your administrator rights.
You can check-in multiply files, by checking the check box next to them, and clicking the "check-in" action, under the "actions" menu.
- Export all the custom items to a shared folder, accessible by both servers.
You can easily export content types using an STSADM extension: Export Content Types, which is a part of a bigger extension pack, which I will mention in details later.
To export solutions, site templates, features and so on, go to "Central Admin -> Operations -> Solution Management"and export all the deployed solutions (or, if you have them stored somewhere, just take it from there). To export, simply right click each solution, and choose "Save Target As".
- Export the entire site collection, using STSADM. The simple "export" command is like as follows:
stsadm -0 export -url <URL> -filename <Name> -includeusersecurity -versions 4
Where <URL> stands for you site's URL; <Name> is the file name to be saved.
The -includeusersecurity tells STSADM to save the users' permissions as defined. You should only use this one if you're exporting to a server in the same environment.
And lastly,-versions the with value of "4" tells STSADM to export all the version history.
- Make sure your content database is offline. You can do that directly from Central Admin: go to "Application Management -> Content Databases", click the desired content database, and change the "Database status" combo-box to "offline"
Click "OK" on the bottom to confirm.
- Create an empty, blank, site collection on the target server.
Don't worry about the template, it'll be created by the import process.
- Import the custom content types, and install solutions, features, etc.
To install solutions and features, use STSADM with the "addsolution" followed by "deploysolution" for solutions, and "installfeature" and "activatefeature" or features.
- Import the content to the new server.
Again, this is very easy to do, just use the STSADM "import" operation. The basic syntax is:
stsadm -0 import -url <URL> -filename <Name> -includeusersecurity -updateversions 2
URL, Name, and includeusersecurity, are the same as with the export operation.
updateversions with value of 2, tells STSADM to overwrite files and all of their versions, if the file exists.
This is only good if you don't import to an existing site.
Well, here you have it. That was the guidelines. Go to part two, to read the errors I've stumbled upon.