Thursday, March 3, 2011

Ap Bio Lab 6 No Answers

Renaming Microsoft SQL 2005 instances

Well today we will learn how to rename a server instance and database using the Microsoft SQL 2005 platform. It's something that maybe has already done many other versions and that the staff, I had never made me any problems. Except perhaps for this case Sql Server 2000.

The scenario is as follows: You have a database server that will be called colloquially Guarro-DB during the installation phase, obviously once you go to a productive environment and should have a less fancy name. The point is that once we have made the name change say our server NoTanGuarro-DB will be a brothel and that all Internally the old name will still appear causing applications to fail. You can verify this by accessing the query analizer and running the following: exec

sp_helpserver

Cuyo result, in our case would be the following:



is likely to be free from defects trying to access this server from any application that extracts data directly or through a link ( Linked Server ). To avoid having to reinstall the SQL from scratch and leave everything set up correctly you can run the following workaround: Go to the server

and found that all SQL services are operating. This is essential because otherwise we can not access our information. Later in a query window analizer run these sentences.

sp_dropserver 'Piggy-DB'

This command will remove the reference to the name 'Piggy-DB' in the table of known servers, which is basically our problem.

sp_addserver 'NoTanGuarro-DB', local

This statement will add the new name of the instance as the local server and the next thing is to hope that everything goes well because we know as the Microsoft spends in these cases.

If you now rerun the exec statement sp_helpserver or Select @ @ servername and perhaps see the correct name but our applications will not work until we restart the server.

can review a similar case here published by Azimut , who really deserves the credit for the solution and can also review the documentation sp_addserver and sp_dropserver
Finally
so I have seen reviewing services and logins are still some that refer to the previous instance name. Applications and run without problems but it is certain that when you least expect will have problems so the best solution, if they have a window of time and the necessary endorsements, is reinstalling SQL Server and the name of the final instance .

Paz.

0 comments:

Post a Comment