Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How to detect a virtual network name

Posted on 2008-06-17
8
427 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
Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 37

Accepted Solution

by:
Geert Gruwez earned 500 total points
ID: 21812126
open the registry on that ip address ...
0
 
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

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Delphi Form ownership 4 111
can't find the executable in Simulator 1 100
How to convert memory stream to PDF file 6 108
I want to use librsync in my Delphi backup application. 3 58
The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

856 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