none
Errors pointing at old DB server after moving Config DB RRS feed

  • Question

  • Hi all

    I recently moved my config and content DBs to a new SQL server (the hard way without using DB aliases). It all works just fine except that I have a few errors a second in my event log pointing to a config DB on the old server which doesn’t exist anymore. Also, if I look at "Configuration database server:" in Central Admin it’s still pointing at my old server. I’m pretty sure that SharePoint is actually using the new server because the old one is powered down.

    I found a good article here: http://www.benstegink.com/2008/03/17/moving-sharepoint-databases-to-a-new-sql-server-%E2%80%93-part-2/

    ...which seems to help with my exact problem, but the author is a bit vague on how to obtain the new SQL server instance GUIDs and I’m having problems following the instructions.

     

    Any help would be greatly appreciated!

     

    Thanks

    John

    • Edited by John Sc Wednesday, July 1, 2009 3:12 PM
    Wednesday, July 1, 2009 11:32 AM

Answers

  • All

    I’m certainly no SharePoint expert (not even close) but this is what I did to fix this problem. I researched a lot and I believe that you have to create a new farm to fix this issue. This is pretty easy though. Heres what I did:

     

    -On the old farm, go to central admin, application Management, Web application list. Make a note of all these applications and the URLs associated with them

    -Go back to Application management, click Site Collection List. Make a note of each site collection you have including the URL. Make sure to check each web app by selecting it on the right hand drop down and check the site collections in each app.

    -Now you have a list of all the things you need to back up. Yay!

    -use STSADM to back these up with the following command. You will run stsadm once for each entry you have noted in the steps above. I put my backup files in a folder called “Backup” on my servers C drive so my backup commands look like this:

     

                    Stsadm –o backup –url http://mywebapp –filename c:\backup\mywebapp.dat

     

    -You will run this again for each webapp or site collection in your list. The command you use when backing up Site collections should contain the full URL including the host web app, even if you have already backed up the host webapp before. (I’m not sure why the backup doesn’t include site collections). So in my example, if I had a site collection at  ”/sites/projects” under http://mywebapp then I would need to run stsadm again like this:

     

                    Stsadm –o backup –url http://mywebapp/sites/projects  –filename c:\backup\projects.dat

     

    -After you have a backup of all your webapps/site collections, move onto building your new farm.

    -On a new server, install SharePoint following whatever docs you need to make a good vanilla SharePoint install. I installed mine following the numerous TechNet articles available. It’s not a big deal. Took about an hour or 2. Pay attention to the persmisions sections!

    -Choose to create a new farm.

    -Once your new server is up and running, you will need to create all your webapps again. I don’t believe that you need to re-create your site collections – just the webapps. That’s what I did anyway.

    -Go to central Admin, application Management, Create or extend Web application.

    -Create a new web application for each of your old applications (not site collections) based on the list you created at the beginning. Again follow the M$ literature to do this properly (creating app pools, permissions etc – it’s not hard at all)

    -At this point its worth noting that I am creating my content DBs on the same DB server that my old content DBs are on. I’m calling them sensible names though so that I can distinguish between new DBs and Old ones and go back and delete old ones later.

    -copy all your backup files from your old server to your new one. In my example I’m copying them to “C:\backups” again

    -Now  change your DNS so that your old web app names now point to your new sharepoint server. This is important for the restore command to find your new server instead of the old one!

    -We use stsadm again to import the data from the backup files into the new web applications by running the following command from the new server:

                   

    Stsadm –o restore –url http://mywebapp –filename c:\backups\mywebapp.dat

     

    -You run this command for each of your webapps that you backed up.  Once you have done all your webapps, restore your site collections by running stsadm again. You don’t have to recreate anything first (other than the host webapp which is hopefully already done)

     

                    Stsadm –o restore -url http://mywebapp/sites/projects –filename c:\backup\projects.dat

     

    -You should now be at the point that I am which is that everything is working again, all your data is back. Yay!

    =-Good luck

    • Marked as answer by John Sc Tuesday, August 18, 2009 4:16 PM
    Tuesday, August 18, 2009 4:16 PM

All replies

  • Hey John,

    we also did SQL Server Moving. But have you tryed to just setup the new SQl Server with the same settings and rename the SQL Server which is listet in you sharePoint Server?

    stsadm -o renameserver -oldservername xxx -newservername xxx

    Greetings,
    Andreas
    Wednesday, July 1, 2009 1:55 PM
  • Thanks Andreas

    No I dindt so this at the time of the move and the move was complted about 4 weeks ago. I guess I could give it a try now and see what happens? My only concern is that it might cause duplicate entries for the same server now that the new server is up and running. Ill give it a try though.

    Thanks
    John
    Wednesday, July 1, 2009 2:13 PM
  • Hey John,

    I think you many change the default server from SharePoint Central Administration site. You can find it "Central Administration" --> "Operations" --> "Default Database Server"

    Change the name of the server to your current database server. Supply the login password if you have SQL Server authentication. Thats all.

    Please reply me if this solves your problem.

    Regards,

    Kooki

    Wednesday, July 1, 2009 2:15 PM
  • Thank Kooki:
     I looked at this setting and it is indeed still pointing to my old server. I changed it to the new one but that did not solve the errors. ie: the errors still fail on the old server and central admin still shows the old server as the config DB server.

    Andreas:
    Thanks for your suggestion. This would be a good option although the new server is already registered as a server in the farm. When I run STSADM -o renameserver, it fails with the error: "A server named xxx is already registered in this farm". I can rename the server to something totally random and I then see all my errors (as well as central admin) now looking at the random name. Sharepoijt still works fine though.
    Another thing is that renaming the server doesnt seem to rename the instance. When I changed the server to "randomserver" the errors now had referebnce to "randomserver/old_instance_Name".

    Its all a bit wierd!
    Wednesday, July 1, 2009 2:43 PM
  • All

    I’m certainly no SharePoint expert (not even close) but this is what I did to fix this problem. I researched a lot and I believe that you have to create a new farm to fix this issue. This is pretty easy though. Heres what I did:

     

    -On the old farm, go to central admin, application Management, Web application list. Make a note of all these applications and the URLs associated with them

    -Go back to Application management, click Site Collection List. Make a note of each site collection you have including the URL. Make sure to check each web app by selecting it on the right hand drop down and check the site collections in each app.

    -Now you have a list of all the things you need to back up. Yay!

    -use STSADM to back these up with the following command. You will run stsadm once for each entry you have noted in the steps above. I put my backup files in a folder called “Backup” on my servers C drive so my backup commands look like this:

     

                    Stsadm –o backup –url http://mywebapp –filename c:\backup\mywebapp.dat

     

    -You will run this again for each webapp or site collection in your list. The command you use when backing up Site collections should contain the full URL including the host web app, even if you have already backed up the host webapp before. (I’m not sure why the backup doesn’t include site collections). So in my example, if I had a site collection at  ”/sites/projects” under http://mywebapp then I would need to run stsadm again like this:

     

                    Stsadm –o backup –url http://mywebapp/sites/projects  –filename c:\backup\projects.dat

     

    -After you have a backup of all your webapps/site collections, move onto building your new farm.

    -On a new server, install SharePoint following whatever docs you need to make a good vanilla SharePoint install. I installed mine following the numerous TechNet articles available. It’s not a big deal. Took about an hour or 2. Pay attention to the persmisions sections!

    -Choose to create a new farm.

    -Once your new server is up and running, you will need to create all your webapps again. I don’t believe that you need to re-create your site collections – just the webapps. That’s what I did anyway.

    -Go to central Admin, application Management, Create or extend Web application.

    -Create a new web application for each of your old applications (not site collections) based on the list you created at the beginning. Again follow the M$ literature to do this properly (creating app pools, permissions etc – it’s not hard at all)

    -At this point its worth noting that I am creating my content DBs on the same DB server that my old content DBs are on. I’m calling them sensible names though so that I can distinguish between new DBs and Old ones and go back and delete old ones later.

    -copy all your backup files from your old server to your new one. In my example I’m copying them to “C:\backups” again

    -Now  change your DNS so that your old web app names now point to your new sharepoint server. This is important for the restore command to find your new server instead of the old one!

    -We use stsadm again to import the data from the backup files into the new web applications by running the following command from the new server:

                   

    Stsadm –o restore –url http://mywebapp –filename c:\backups\mywebapp.dat

     

    -You run this command for each of your webapps that you backed up.  Once you have done all your webapps, restore your site collections by running stsadm again. You don’t have to recreate anything first (other than the host webapp which is hopefully already done)

     

                    Stsadm –o restore -url http://mywebapp/sites/projects –filename c:\backup\projects.dat

     

    -You should now be at the point that I am which is that everything is working again, all your data is back. Yay!

    =-Good luck

    • Marked as answer by John Sc Tuesday, August 18, 2009 4:16 PM
    Tuesday, August 18, 2009 4:16 PM