H3C S7500 Series Operation Manual(Release 3100 Series)-(V1.04)

HomeSupportSwitchesH3C S7500 Switch SeriesConfigure & DeployConfiguration GuidesH3C S7500 Series Operation Manual(Release 3100 Series)-(V1.04)
36-DNS Configuration
Title Size Download
36-DNS Configuration 70 KB

Chapter 1  DNS Configuration

When configuring DNS, go to these sections for information you are interested in:

l           DNS Overview

l           Configuring Static Domain Name Resolution

l           Configuring Dynamic Domain Name Resolution

l           Displaying and Maintaining DNS Configuration

l           Troubleshooting DNS Configuration

1.1  DNS Overview

A domain name system (DNS) is a distributed database system that provides domain name-to-IP address mappings for TCP/IP applications. With DNS, users using IP applications can directly use meaningful easy-to-remember domain names, which will be resolved and mapped to corresponding IP addresses by DNS servers.

There are two types of DNS resolution, static and dynamic. When a name query is received, static resolution is first performed to check the static DNS list. If the static resolution fails, dynamic resolution is performed to look up the dynamic DNS list. Because dynamic resolution needs the cooperation of a DNS server and may take some time, you can put some commonly used domain names into the static DNS list to improve resolution efficiency.

1.1.1  Static DNS Resolution

With static DNS resolution, you can manually configure some name-to-address mappings in the static DNS list, and the system will search the static list for corresponding IP addresses when users use domain names for some applications (such as telnet).

1.1.2  Dynamic DNS Resolution

I. Resolution procedure

The procedure of dynamic DNS resolution is as follows:

1)         A user program sends a name query to the resolver in the DNS client.

2)         The DNS resolver looks up the local DNS cache for a match. If a match is found, it returns the corresponding IP address to the user program. If not, it sends a query request to the DNS server.

3)         The DNS server looks up its database for a match. If no match is found, it sends the request to its parent DNS server. If the parent DNS server does not have the information, it sends the query to another server. This process continues until a result (either successful or failed) is found. Finally, the resolution result is returned to the DNS client.

4)         The DNS client performs the next operation according to the result.

Figure 1-1 Dynamic DNS resolution

Figure 1-1 shows the relationship between the user program, DNS client and DNS server.

The resolver and cache compose the DNS client. The user program can run on the same device as the DNS client or a different device, while the DNS server and the DNS client must run on different devices.

Dynamic DNS resolution allows the DNS client to store the latest successful name-to-address mappings into the dynamic domain name cache. So there is no need to send a request to the DNS server for query of the same domain next time. The DNS client removes aged mappings from the cache, so as to obtain updated mappings from the DNS server. The setting on the DNS server determines the aging interval, and the DNS client obtains the information from DNS messages.

II. DNS suffix list

The DNS client normally holds a DNS suffix list where you can define some domain name suffixes. It is used when the name to be resolved is not complete. The resolver can use the list to supply the missing part. For example, you can configure a suffix "com" in the list, and users only need to enter "aabbcc" to obtain the IP address of aabbcc.com, because the resolver will automatically add the suffix and delimiter before passing the name to the DNS server.

When a user enters a domain name:

l           If there is no dot in the domain name, such as aabbcc, the resolver will consider this as a host name and add a suffix to the name before performing DNS lookup. If all the suffixes in the DNS suffix list have been tried but no DNS lookup succeeds, the resolver will use the original name (such as aabbcc) for a DNS lookup.

l           If there is a dot in the domain name, such as www.aabbcc or aabbcc., it indicates that no DNS suffix needs to be added and the resolver will use this domain name to do DNS lookup first. If the lookup fails, the resolver adds a DNS suffix for another lookup.

Currently, the S7500 Series Ethernet Switches support both static and dynamic domain name resolution on the DNS client.

1.2  Configuring Static Domain Name Resolution

Follow these steps to configure static domain name resolution:

To do…

Use the command…

Remarks

Enter system view

system-view

Add a hostname-to-address mapping entry

ip host hostname ip-address

Required

There is no entry in the static DNS list by default.

 

&  Note:

l      One hostname can be mapped to only one IP address. When you add multiple hostname-to-address mapping entries with the same hostname, only the last one will be valid.

l      You can add up to 50 entries for static DNS resolution.

 

1.3  Configuring Dynamic Domain Name Resolution

1.3.1  Configuration Procedure

Follow these steps to configure dynamic domain name resolution:

To do…

Use the command…

Remarks

Enter system view

system-view

Enable dynamic DNS resolution

dns resolve

Required

This function is disabled by default.

Configure an IP address for a DNS server

dns server ip-address

Required

No DNS server IP address is configured by default.

Configure a DNS suffix

dns domain domain-name

Optional

No DNS suffix is configured by default.

 

&  Note:

You can configure up to 6 DNS servers and 10 DNS suffixes.

 

1.3.2  DNS Configuration Example

I. Network requirements

As shown in Figure 1-2, a switch is used as a DNS client with dynamic DNS resolution. It allows you to access host with an IP address of 3.1.1.1/16. The DNS server IP address is 2.1.1.2/16. The DNS suffixes "com" and "net" are configured.

II. Network diagram

Figure 1-2 Network diagram for dynamic DNS resolution

III. Configuration procedure

 

&  Note:

First suppose the switch and host 1 are reachable to each other, the DNS server works normally, and a mapping entry from host to IP address 3.1.1.1/16 exists on the DNS server.

 

# Enable dynamic DNS resolution.

<H3C> system-view

[H3C] dns resolve

# Configure the DNS server IP address 2.1.1.2.

[H3C] dns server 2.1.1.2

# Configure net as a DNS suffix.

[H3C] dns domain net

# Configure com as a DNS suffix.

[H3C] dns domain com

Ping host on the switch to verify the configuration and the corresponding IP address (it should be 3.1.1.1).

1.4  Displaying and Maintaining DNS Configuration

To do…

Use the command…

Remarks

Display static DNS list information

display ip host

Available in any view

Display DNS server information

display dns server [ dynamic ]

Display DNS suffix list information

display dns domain

Display dynamic DNS cache information

display dns dynamic-host

Clear the dynamic DNS cache.

reset dns dynamic-host

Available in user view

 

1.5  Troubleshooting DNS Configuration

I. Symptom

Dynamic DNS resolution is enabled, but the user cannot obtain the correct IP address from a domain name.

II. Analysis

To obtain a correct IP address according to a domain name, the DNS client must be used in cooperation with the DNS server.

III. Solution

l           Use the display dns dynamic-host command to check whether the specified domain name is available in the cache.

l           If the specified domain name is available in the cache, but the IP address is wrong, ensure that the DNS client has the correct IP address of the DNS server.

l           If the specified domain name is not available in the cache, ensure that dynamic DNS resolution is enabled, the DNS client can normally communicate with the DNS server, and the DNS server works normally.

l           Check whether the DNS mapping list is correct on the DNS server.

 

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网