开发者

How to get virtual cluster FQDN from a computer which is a node in a cluster

I have installed a cluster which contains several nodes(computers). the OS is windows 2008 SP1. This cluster is a SQL cluster.

The original requirement is that customer input a FQDN which will be used to install SQL server. but the FQDN may be a real computer's FQDN, or a FQDN of a virtual cluster server. Before install SQL server, I need to verify the FQD开发者_运维百科N is a valid. My current solution is I will create a service on the target machine (according to the FQDN), and run windows API GetComputerNameEx with parameter "ComputerNameDnsFullyQualified". According to the MSDN, it should return the FQDN of the virtual cluster name, but if still return FQDN of local computer.

So, my problem are 1. resolve the problem of win API GetComputerNameEx, why it can't retrieve FQDN of virtual server name. OR 2. think about another way to verify the customer input FQDN is valid.

any comment will be very appreciated.

p.s: I asked the question on MSDN forum, but still can't get good solution. http://social.msdn.microsoft.com/Forums/en-US/sqlsetupandupgrade/thread/ee238e8a-a200-41f4-ae69-272b74864c5b http://msdn.microsoft.com/en-us/library/ms724301(VS.85).aspx


could you just use the given FQDN to connect to the active node of the cluster and then use TSQL ISCLUSTERED and MACHINENAME (name of clustered instance) to get your required information..

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜