Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 SERVERPROPERTY('servername') is Win2003 cluster

Author  Topic 

walterburke
Starting Member

7 Posts

Posted - 2006-10-25 : 10:52:31
Hi,

We need to change the value of SERVERPROPERTY('servername') in a Windows 2003 MSCS two node cluster that runs SQL Server 2000.

Has anyone done this before? If so, how did you do it?

Thanks, Wally

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2006-10-25 : 14:23:27
What would you like it to return?


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2006-10-25 : 14:39:57
Do not change this value! You will probably completely mess things up. On a cluster, the value will return the virtual name, which is what it should do.

Why do you even want to change the value? What purpose will it serve besdies screwing things up?


Tara Kizer
Go to Top of Page

walterburke
Starting Member

7 Posts

Posted - 2006-10-25 : 15:20:00
Hi,
We get a virtual name back, but not the virtual name that we want. We need to change it to a different virtual name. Both virtual Network Names and IP addresses are defined in the MS SQL cluster group.

Thanks, Wally
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2006-10-25 : 15:37:26
But why do you want to change it? What purpose will it serve?

Tara Kizer
Go to Top of Page

mcrowley
Aged Yak Warrior

771 Posts

Posted - 2006-10-25 : 16:33:31
[code]
create function ourServerProperty(@input nvarchar(100))
returns nvarchar(100)
as
begin
declare @retval nvarchar(100)
if lower(@input) = 'servername'
select @retval = N'The name we want'
else
select @retval = convert(nvarchar(100), serverproperty(@input))
return @retval
end
go
select dbo.ourServerProperty('Servername')
[/code]
Go to Top of Page

walterburke
Starting Member

7 Posts

Posted - 2006-10-25 : 17:06:19
Hi,

We have different network names in the cluster. GSPDB and GDPDB. The server was originally built using the GSPDB name. We are running into some issues with implementing a backup product name LiteSpeed. The product does the below check and gets a mismatch.

select convert(char(20), serverproperty('servername')) returns GDPDB

but

SELECT @@SERVERNAME AS 'Server Name' returns GSPDB

When we look at the registry of the cluster nodes in the Environment value name under the below key it has the value data "COMPUTERNAME=GDPDB"

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSSQLSERVER

We need to figure out how to get everything pointing back to GSPDB without hosing the cluster.

Any help would be greatly appreciated. Thanks, Wally


Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2006-10-25 : 17:17:59
When you rebuilt the server, did you also reinstall SQL Server?

I don't think we'll be able to solve the problem for you as it'll require in depth knowledge of the system tables in order not to completely screw up your server. You should call Microsoft to get this straightened out.

Tara Kizer
Go to Top of Page

walterburke
Starting Member

7 Posts

Posted - 2006-10-26 : 10:22:55
Hi,
We never rebuilt the server or reinstalled SQL Server.
Thanks, Wally
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2006-10-26 : 14:04:38
I guess I was confused by "We have different network names in the cluster. GSPDB and GDPDB. The server was originally built using the GSPDB name."

How do they have different names then? Was the server renamed at some point? If so, did you run the commands to switch SQL Server as Books Online shows:

sp_dropserver <old_name>
go
sp_addserver <new_name>
go

Tara Kizer
Go to Top of Page

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 2006-10-26 : 14:32:22
I usually do it this way.

use master
go
-- Remove old Server Name
exec sp_dropserver 'OLDNAME'
GO
-- Add New Server Name
exec sp_addserver 'NEWNAME','LOCAL'


You may also want to run this to update SQL Agent jobs.

update msdb.dbo.sysjobs
set
-- New Server Name
originating_server = 'NEWNAME'



CODO ERGO SUM
Go to Top of Page

walterburke
Starting Member

7 Posts

Posted - 2006-10-26 : 18:55:32
Hi,

I am not sure how SERVERPROPERTY('servername') got set to GDPDB. Our DBA swears that he installed it as GSPDB. The environment was installed one year ago, and hasn't been reinstalled, rebuilt or moved to new hardware etc.

What else could possibly cause that to change?

The below MS article says to rename a virtual server you have to "uninstall and then reinstall the virtual server".

http://support.microsoft.com/default.aspx?scid=kb%3Ben-us%3B303774

Thanks, Wally
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2006-10-26 : 19:00:41
I've got lots of experience with clusters and SQL Server, but we've never had to rename a node or the virtual names, so I can't help you there, at least from an experience point of view.

Call Microsoft! If there is an easy solution to your problem, they'll know. If there isn't an easy solution, then at least they'll tell you the correct solution. If you don't have a support contract with MS currently, then I believe the call will cost around 250 USD. Here's the phone number I use for them: 800-936-3100.

Tara Kizer
Go to Top of Page

walterburke
Starting Member

7 Posts

Posted - 2006-11-06 : 13:53:33
Our DBA's resolved the issue by uninstalling and re-installing Microsoft SQL Server. We are now trying to figure out the root cause of what changed this so we can prevent it from happening again. Does anyone know what different things can be done to change the default database name: serverproperty('servername')?

Thanks, Wally
Go to Top of Page

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 2006-11-06 : 14:05:52
quote:
Originally posted by walterburke

Our DBA's resolved the issue by uninstalling and re-installing Microsoft SQL Server. We are now trying to figure out the root cause of what changed this so we can prevent it from happening again. Does anyone know what different things can be done to change the default database name: serverproperty('servername')?

Thanks, Wally



Did you try the code I posted?



CODO ERGO SUM
Go to Top of Page

walterburke
Starting Member

7 Posts

Posted - 2006-11-06 : 17:50:45
Hi Michael,
The code you posted isn't supported for virtual server names, which was the case here. That is outlined in the below MS Technet article.

http://support.microsoft.com/default.aspx?scid=kb%3Ben-us%3B303774


Thanks, Wally
Go to Top of Page

drgoni
Starting Member

1 Post

Posted - 2006-11-21 : 21:49:28
Hi guys... wonder if you folks could help or confirm if the following is possible? [I'm not a SQL DBA - he should be asking this but... anyway, I'm involved in our DR environment and know a little about SQL]...

We've got a 2 node SQL2K (enterprise) cluster (running on 2 W2K3 servers). This was recommended by a 3rd party document management reseller/developer. They also recommended a similar installation at our DR site (physically remote but siting on the same NT resource domain). However, we're now trying to work out how the hell this works in practice (yes I know, these questions should've been asked up front but they weren't!).

So, in a DR (test) scenario, we've broken the inter-office WAN link and need to rename the SQL cluster setup, so that the clients and 3rd party apps can see the cluster (as if in a DR situation). Does anyone have any experience of this sort of setup? What do we need to rename (so that this system appears to the clients as the live system)? If it was just the cluster, I guess that would be fine but I suspect that the virtual nodes (and possibly the physical servernames as well) will also need to be renamed. The problem as I understand it, is that SQL2000 virtual server can't be renamed, so do we need to remove or evict and re-install the sql cluster? (I guess this is a rhetorical question). But if this is the case, do we also need to rename the physical servernames? I realise this is all a bit sketchy and would also depend on how the apps communicate - but suddenly, our 3rd party reseller have no idea!!!

Any help or assistance at all would be greatly appreciated... (ultimately, we're trying to provide a warm-standby solution to a mission-critical app but I suspect we might be over-complicating this by not having sat down and designed this properly from the outset... bloody politics!!)

many thanks,
Der
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2007-09-04 : 09:19:40
[code]CREATE VIEW dbo.vwDatabaseInformation
AS

SELECT 'MachineName' AS PropertyName, SERVERPROPERTY('MachineName') AS PropertyValue UNION ALL
SELECT 'ServerName', SERVERPROPERTY('ServerName') UNION ALL
SELECT 'InstanceName', SERVERPROPERTY('InstanceName') UNION ALL
SELECT 'Edition', SERVERPROPERTY('Edition') UNION ALL
SELECT 'ProductVersion', SERVERPROPERTY('ProductVersion') UNION ALL
SELECT 'ProductLevel', SERVERPROPERTY('ProductLevel') UNION ALL
SELECT 'EngineEdition', SERVERPROPERTY('EngineEdition') UNION ALL
SELECT 'ComputerNamePhysicalNetBIOS', SERVERPROPERTY('ComputerNamePhysicalNetBIOS')[/code]


E 12°55'05.25"
N 56°04'39.16"
Go to Top of Page
   

- Advertisement -