Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

server propeties and @@ servername have different server name!!! Expand / Collapse
Author
Message
Posted Wednesday, October 17, 2012 10:27 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Friday, December 12, 2014 6:58 AM
Points: 35, Visits: 123
There is different name in server properties and @@server name !!! can somebody explain how and why this happened and how to fix it??
server Properties name: abcdef
@@servername : abcxyz
Post #1373937
Posted Wednesday, October 17, 2012 11:41 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 2:36 PM
Points: 6,759, Visits: 14,408
Have you renamed the Windows server since sql server was installed?

To remove the current servername entry use

exec sp_dropserver 'abcxyz'

Then run this to correct it

exec sp_addserver 'abcdef', 'local'



-----------------------------------------------------------------------------------------------------------

"Ya can't make an omelette without breaking just a few eggs"
Post #1373972
Posted Wednesday, October 17, 2012 2:13 PM
Say Hey Kid

Say Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey Kid

Group: General Forum Members
Last Login: Today @ 2:17 PM
Points: 710, Visits: 1,455
Is this on a cluster? When you say "server property" what are you selecting exactly?

@@servername will give the local machine name, except in a failover cluster, where it will give you the virtual server name

serverproperty('computernamephysicalnetbios') should give you the local machine name. In a failover cluster this is the machine name of the active node


Joie Andrew
"Since 1982"
Post #1374043
Posted Thursday, October 18, 2012 7:01 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Friday, December 12, 2014 6:58 AM
Points: 35, Visits: 123
when u right click on server's name in SSMS. i see different name and when i run select @@servername find different name.
Post #1374316
Posted Thursday, October 18, 2012 7:15 AM
Say Hey Kid

Say Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey Kid

Group: General Forum Members
Last Login: Today @ 2:17 PM
Points: 710, Visits: 1,455
Was the server renamed at some point? Can you post the results of the following:

SELECT SERVERPROPERTY(InstanceName), SERVERPROPERTY('MachineName'), SERVERPROPERTY('ComputerNamePhysicalNetbios'), SERVERPROPERTY('IsClustered')


Joie Andrew
"Since 1982"
Post #1374333
Posted Thursday, October 18, 2012 8:19 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 2:36 PM
Points: 6,759, Visits: 14,408
dinsab11 (10/18/2012)
when u right click on server's name in SSMS. i see different name and when i run select @@servername find different name.

Please see my post above


-----------------------------------------------------------------------------------------------------------

"Ya can't make an omelette without breaking just a few eggs"
Post #1374401
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse