Howto: Migrate a Citrix Datastore from SQL2000 to SQL2005 Print E-mail
Written by Richard Thompson, Friday, 13 April 2007

There have been numerous questions about this on various forums with very few people giving an exact answer. This is how we did it...

Note that in order for your resource manager summary database to run on SQL 2005 you need to enable SQL 2000 Compatibilty.

Datacrash.net nor its members can be held accountable for any damage caused to your datastore or Citrix Farm as a result of performing this migration. This was tested with the assistance of Certified Citrix Professionals and Database administrators and I would not recommend doing so without the above assistance. Datacrash also recommends that you Backup your source database server prior to any database manipulation and that you do this on a test server prior to your production environment.

Preparation work:
Create an empty database on your 2005 SQL Server. You don't need to call your database anything specific but I like to keep the name close to the function of the database. For the purposes of this how to consider the database name CitrixDS.

Once you have created your database I would recommend creating a SQL account on your SQL server or assigning a domain user with required permissions to log on to the database. In order to successfully migrate the database we had to grant the following permissions:
Database - Connect
CitrixDS SQL Account - sysadmin

Now that you have a Database and a configured account you need to create a new File DSN on your Citrix Server. Create a SQL DSN and save this in the same directory as the MF20.dsn file.

You have now completed the preparation work required for the Datastore migration.

Migration:
Still logged onto the Citrix server open a command prompt window and execute the following command:
dsmaint migrate /srcdsn:*Path to dsn* /srcuser:DSUsername /srcpwd:DSPassword /dstdsn:*Path to new dsn* /dstuser:NewDSUsername /dstpwd:NewDSPassword

* Note you can obtain your path to DSN from the following registry key: *
* HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\IMA\DataSourceName *
* The path is usually c:\Program Files\Citrix\Independent Management Architecture\MF20-2005.dsn *

You should now see a warning about migrating the database, click Yes. Following this a MetaFrame XP style progress bar will appear indicating the progress of your migration. This will take 3 to 4 minutes depending on the size of your datastore. Once complete you will see another warning advising you to compare your source and destination datastores. Click Yes to compare these datastores.

You should now have a fully functioning SQL 2005 Datastore.

Now still logged on to your Citrix Server execute the following command:
dsmaint config /user:NewDSUsername /pwd:NewDSPassword /dsn:*Path to new dsn*

This should execute successfully. Once this is complete you need to restart your IMA Service using
the services.msc console. Following a successful restart you should be able to launch the management console on your server and using this make changes to your datastore to confirm functionality.

Now copy your new dsn to all of your existing servers. Once the dsn has been copied to all of your servers open the dsn using a text editor (notepad, etc) and modify the WSID field to match your servers name. This will cause the database connections to have different names and assist you with troubleshooting at a later stage.  Now execute the dsmaint config command on all of your servers followed by restarting the IMA Service.

I would recommend that all commands are executed when little to no people are using your farm.

Possible problems:
During our testing we experienced the following problems initially:
The dsmaint migrate command failed with an unknown error. This was due to the NewDSUsername having insufficient privledges to the CitrixDS database. Modifying the permissions on the database resolved this.

An error message Error Code:c0200002/80000007 occured whilst trying to add a new policy following migration. Stopping the IMA and running dsmaint recreatelhc resolved this error.

Thank you to Clinton, Stuart and Paul for assisting with the Datastore migration.

 

Comments
Add NewSearchRSS
sureshkrishnan - thanks for the great article Unregistered | 2007-04-19 12:34:09
hi thanks for this great article its very userful .. great work
Beaver - I agree, but... Unregistered | 2007-04-23 06:08:19
Yes very usefull and helpfull article. One thing you didnt mention was that if the src DS is the default access MDB the user and password switches in the src should be left out. Cheers.
LCS - I agree, but... Unregistered | 2008-11-13 20:33:13
Umm, Beaver, the name of the article is "Howto: Migrate a Citrix Datastore from SQL2000 to SQL2005." So why would you expect them to include information about the Access MDB?
Sander de Rijk - thnx for the help Unregistered | 2007-05-31 21:29:33
Thnx for this great article man. I have been looking for a way to migrate it to 2005.

A small note though: when creating the DSN for the new 2005 database you must select "SQL Server" and not "SQL Native Client".
Write comment
Name:
Title:
UBBCode:
[b] [i] [u] [url] [quote] [code] [img] 
 

Powered by JoomlaCommentCopyright (C) 2006 Frantisek Hliva. All rights reserved.Homepage: http://cavo.co.nr/

 
< Prev   Next >