Introduction to NetBIOS Name Resolution


Some clients still rely on NetBIOS names to communicate with other hosts on a network. A NetBIOS name is a 16-character name where the first 15 characters identify a unique host and the 16th character identifies a service or application running on the host such as the Workstation or Server service. Table 3.1 outlines common hexadecimal values used to identify services running on a computer.

Table 3.1. Node Types

Node Type

Description

<OOH>

Registered by the Workstation service

<1CH>

Indicates a domain name that can be used to locate domain controllers

<O6H>

Registered by a computer running Routing and Remote Access

<1BH>

Registered by each domain controller functioning as the domain master browser

<20H>

Registered by a WINS client running the Server service

<21H>

Registered by the RAS client running on a WINS client


As with domain names, NetBIOS names must be resolved to an IP address before two hosts can communicate. There are a number of different methods available for name resolution and the method employed will depend on the environment.

Name Resolution Methods

The three standard ways of resolving NetBIOS names to IP addresses are through a local broadcast, using the local cache, or by using a NetBIOS name server.

With a local broadcast, a broadcast is sent out on the network requesting the IP address of a specific host. The obvious disadvantage to this method is the increase in traffic.

All hosts maintain a local cache that can be used for name resolution. Each time a host resolves a NetBIOS name to an IP address, the record is added to the local cache and remains valid for 10 minutes. By default, all clients will check their local cache before using any of the other resolution methods available.

The third option is to use a NetBIOS name server (such as a WINS server) to resolve names to IP addresses.

In a Microsoft environment, several other methods for resolving names are also available such as DNS servers, HOSTS files, and LMHOSTS files.

Depending on the requirements of an environment, clients can be configured to use a single method for name resolution or they can use a combination of methods. The exact method a client uses to resolve NetBIOS names is determined by their node type. For example, if a client is configured as an M-Node, it will attempt to resolve a NetBIOS name by first performing a local broadcast. If this is unsuccessful, it will then try to resolve the name using a NetBIOS name server. You can check the node type a client is configured for by typing ipconfig/all at the command prompt. The node type can be changed within the local Registry. Table 3.2 summarizes the four different node types.

Table 3.2. Node Types

Node Type

Description

B-Node

A broadcast is used for NetBIOS name registration and resolution.

P-Node

A NetBIOS name server is used for name registration and resolution.

M-Node

A broadcast is attempted first for name resolution. If this method fails, a NetBIOS name server is contacted.

H-Node

A NetBIOS name server is attempted first for name resolution. If this fails a broadcast is used.


Tip

Remember that before performing a broadcast or contacting a WINS server, the host will attempt to resolve a NetBIOS name using its local cache.


Exam Alert

Be prepared to encounter exam questions pertaining to the NetBIOS node types. Make sure you are familiar with what methods of resolution are used for each type and in what order.


Exam Alert

A Windows Server 2003 or Windows XP client that is configured as a DHCP client automatically uses H-Node for NetBIOS name resolution. This means the client will attempt to resolve NetBIOS names using a WINS server first before using a local broadcast (after checking the local cache). The client will resolve names in the following order: local cache, WINS, broadcast, LMHOSTS, HOSTS, DNS.


LMHOSTS Files

As already mentioned, one of the ways in which NetBIOS names can be resolved is through the use of a text file known as an LMHOSTS file. One of the benefits of using an LMHOSTS file is that entries from the file can be preloaded into the local cache to facilitate name resolution (because this is the method a client will use to resolve a NetBIOS name). So if a client cannot resolve a NetBIOS name using any of the methods described previously, it can parse the LMHOSTS file to see whether a record exists.

Tip

Remember that in order for clients to resolve names using an LMHOSTS file, they must be configured to do so (refer to the section "Configuring WINS Clients" for more information).


The LMHOSTS file can be found in the %systemroot%\system32\drivers\etc directory. When configuring records within the file, there are several directives that can be used which are outlined in Table 3.3.

Table 3.3. Predefined Directives That Can Be Used Within an LMHOSTS File

Predefined Keyword

Description

#Pre

Defines which entries within the file should be loaded into the local cache.

#DOM:domain_name

Indicates the record is for a domain controller.

#Begin_Alternate

Specifies a list of other locations for an LMHOSTS file.

#End_Alternate

#inlcude

Loads entries from a separate LMHOSTS file separate from the default file on the local computer. This option is most often used to specify a centrally located LMHOSTS file.

#MH

Adds multiple entries for a multihomed computer.


Exam Alert

Be sure you are familiar with the different directives that can be used within an LMHOSTS file and what their purposes are.




Exam Cram(c) 70-291 Implementing, Managing, and Maintaining a Windows Server 2003 Network Infrastructure
Exam Cram(c) 70-291 Implementing, Managing, and Maintaining a Windows Server 2003 Network Infrastructure
ISBN: 131516345
EAN: N/A
Year: 2006
Pages: 126

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net