Showing posts with label SQL. Show all posts
Showing posts with label SQL. Show all posts

Sunday, April 28, 2013

Check SQL Server Installed Components

Once in while i get to a client that performs the TFS installation on his own, generally most of them do a bad installation (maybe i just go to the bad ones....)
the first thing i do is to check the SQL installation.
basically there are 2 ways:
1. Add/Remove Programs (Slow and painfully...)
2. SQL Server features discovery Report (short and informative)

to get to the report, we Open "SQL Server Installation Center"
 

 
Click on "Tools->Installed SQL Server features discovery Report"
 
you'll get an HTML report of all the features installed on the machine with their version.

SQL Server Name Update

once in a while i encounter clients that only after the installation of the SQL rememeber that the server name is not what they wanted.....
 
normally we had to reinstall the whole server again. but luckly we can update the SQL Server name After the machine change (connection to TFS after rename is a different issue...)
 
run the following in SSMS:
  1. run "Select @@servername" to verifiy the current server name
  2. run the following script to update the server name 
  3.          sp_dropserver 'old_name'
             go
             sp_addserver 'new_name','local'
             go
  4. Restart SQL Server service. I prefer the command prompt for this, but you can just as easily do it in Services under the Control Panel
    • net stop mssqlserver
    • net start mssqlserver
  5. Then after that is done run "select @@servername" to check the new name
 
 
 
 
 
 
 

How To: Find the SQL Version that is Installed

I Get to do a lot of TFS upgrades and migrations. there is one critical element in these actions,
that is the SQL Server, installation of a wrong version of SQL or missing some updates will cause problem restoring the databases and a big headache

so first we can use this query to check service pack and product edition (Developer / standard / Enterprise)

SELECT SERVERPROPERTY('productversion'),SERVERPROPERTY('productlevel'),SERVERPROPERTY('edition')

and for a more specific identification we can take the Version that is written in the SSMS
and check it against this site: http://sqlserverbuilds.blogspot.com/
this site contains a list of all patches and their corresponding version