Solved

How to detect a virtual network name

Posted on 2008-06-17
8
422 Views
Last Modified: 2011-09-20
I'm looking for a way to determine if a host name is actually a virtual name. For example if you have a two node cluster where the following network names and IP addresses are used:

Node1   192.168.10.5
Node2   192.168.10.6
and the cluster name and IP:
Cluster  192.168.10.10

'Cluster' is a virtual name that point to the node where the quorum is located at any given time.
If you browse the network you get back all three names. I'd like to know if there is a way to determine if the host name is a 'real' host name or a virtual name.
Of course you don't have to use clusters to have virtual names. You can have the same thing with exchange on a single node.
0
Comment
Question by:softbreeze
  • 3
  • 3
  • 2
8 Comments
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 21811219
what does this give ?
ping 192.168.10.5 /a
ping 192.168.10.6 /a
ping 192.168.10.10 /a

0
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 21811233
shoud have been
ping -a 192.168.10.5
ping -a 192.168.10.6
ping -a 192.168.10.10
0
 
LVL 1

Author Comment

by:softbreeze
ID: 21811775
'ping -a' resolves address to host name. Since the virtual name is in DNS the ping -a will return the virtual name when it's IP is ping'd. Therefore 'ping -a' will not answer my question. It looks like the virtual ip is added to the network interface along with the hosts ip and the names are added to DNS. I don't believe that programmaticly you can identify virtual names. Currently I can figure this out on a cluster node by examining the registry. It would be easier if the cluster api was ported for Delphi.

Thanks for your suggestion though.
0
 
LVL 37

Accepted Solution

by:
Geert Gruwez earned 500 total points
ID: 21812126
open the registry on that ip address ...
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 18

Expert Comment

by:Johnjces
ID: 21813175
Simply put, you can't.

Using the MS Clustering solution (poor) and also now using Marathon virtual clusters (good) and believing you have a good understanding of clustering, you should understand why.

In a cluster or virtual cluster,  there is of course added software to the OS and added stuff in lan manager which allows a virtual IP to be assigned to a virtual PC name. This name could be resolved through the lmhosts or dns or through NetBeui/NetBIOS and the TCP protocol via standard broadcasts and of course being handled by your master browser and/or WINS.

There is no added packet or signifying bit advising that this broadcast is virtual. It is all standards based. Google NetBIOS protocol as an example. The master browser does not know and the only "thing" that could know would be the human who set it up or administers the cluster.

Another example might be to run a virtualized XP OS on Vista. One can set up a different host name and IP, and both are visible to the LAN.

Simply, there is no difference in how a virtual server, cluster server etc, broadcasts its NetBIOS name.

John
0
 
LVL 1

Author Comment

by:softbreeze
ID: 21813447
I fully understand clusters and understand how it broadcasts it NETBIOS name. Virtual Names and IPs are not limited to clusters, as my initial question stated. Geert's comment got me thinking in a different direction, which is what I needed. I have a little over 100 servers that are all in Active Directory. I have a SQL stored procedure that queries the AD Database and returns all the computer accounts along with some of the properties. Since Cluster virtual name and Exchange virtual name can and do (based on version) show up as computer accounts, I needed a way to distiguish between them and the real computer accounts.

In the registry at
'HKLM\System\CurrentControlSet\Services\tcpip\Parameters\DNSRegisteredAdapters\{GUID}'.
The Key 'HostName' is the host name of the computer, not the virtual name. So you can match the host name from the Active Directory list and determine if the name is a virtual name or a 'real' host name.

If you match the {GUID} at
'HKLM\System\CurrentControlSet\Services\tcpip\Parameters\Interfaces\{GUID}' you can get the IPAddress of the registered adapter as well.

Maybe this is not the best solution but it works for me. Thanks Geert
0
 
LVL 1

Author Closing Comment

by:softbreeze
ID: 31468041
I've worked on this for a long time and never thought to try this. Thanks again for getting my brain directed in a new direction.
Ken
0
 
LVL 18

Expert Comment

by:Johnjces
ID: 21813493
Outstanding! I thought you were after some form of remote "socketized" or IP method for determining such.

Good luck!

John
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Delphi component that can load a DLL in design time? 8 53
Best Firemonkey component pack 1 87
Delphi cmd execution 6 55
How to build JSON File in Delphi 6 3 11
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Hi friends,  in this video  I'll show you how new windows 10 user can learn the using of windows 10. Thank you.

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now