Table of Contents
13.3 Commands for DNSv4/v6
13.3.1 clear dynamic-host
Function: Delete the domain entry of a specified address or all addresses in the dynamic cache.
Parameters:
-
<ip-address>: IP address in dotted decimal notation.
-
<ipv6-address>: IPv6 address.
-
all: will delete the domain entry of all addresses in the dynamic cache.
Command mode: Admin Mode
Default: Disabled.
Usage guide: This command is used to manually delete the domain name and address entry in the dynamic cache. This command is most useful when domain names have spent a long time in the cache.
Example: Delete the address 202.108.22.5.
active500EM#clear dynamic-host 202.108.22.5
13.3.2 debug dns
no debug dns {all | packet [send | recv] | events | relay}
Function: Display the application debug information of the DNS domain name resolution. The no command disables the debug display.
Parameters: None.
Command mode: Admin Mode
Default: None.
Usage guide: Display the application debug information of the DNS domain name resolution.
Example: Display the application debug information of the DNS domain name resolution.
active500EM#debug dns all active500EM#ping host www.sina.com.cn %Jan 01 00:03:13 2006 domain name www.sina.com.cn is to be parsed! %Jan 01 00:03:13 2006 Dns query type is A! %Jan 01 00:03:13 2006 Connect dns server 10.1.120.241 ...... ping www.sina.com.cn [202.108.33.32] Type ^c to abort. Sending 5 56-byte ICMP Echos to 202.108.33.32, timeout is 2 seconds. %Jan 01 00:03:15 2006 Host:www.sina.com.cn Address:202.108.33.32 ..... Success rate is 0 percent (0/5), round-trip min/avg/max = 0/0/0 ms
13.3.3 dns-server
Function: Configure or delete the DNS server.
Parameters:
-
<ip-address>: IP address in dotted decimal notation.
-
<ipv6-address>: IPv6 address.
-
<value>: priority of the DNS server. The valid range is from 0 to 255 and set at 0 by default.
Command mode: Global Mode
Default: None.
Usage guide: This command is used to configure or delete the DNS server when needed to enable dynamic domain name mapping. The switch will send a domain name search request packet to a configured DNS server. The DNS server can be configured to no more than 6. Priority is an optional parameter. If priority is configured, the DNS server must be organized according in order of priority from high to low. This configures the switch to send a domain name search request to the server which has the highest priority. It is recommended to set a DNS server which is used frequently and has a quick search speed to the highest priority. If priority is not configured, a DNS server will be searched according to the configuration order. When the switch serves as a DNS server, the queries to the DNS server won?t follow the above privilege rule. Instead, the requests will be sent to all configured servers at the same time.
Example: Configure the priority of DNS server as 200. The server?s address is 10.1.120.241.
active500EM(config)#dns-server 10.1.120.241 priority 200
13.3.4 dns lookup
Function: Enable DNS dynamic domain name resolution.
Parameters:
-
ipv4 | ipv6: represents the IPv4 or IPv6 address lookup.
-
<hostname>: resolute dynamic host name, should be less than 63 characters.
Command mode: Global Mode
Default: Disabled.
Usage guide: This command is used to look up corresponding addresses based on an entered client name (both IPv4 and IPv6 addresses). This command is only used for domain name mapping. There are no other application functions. When the command is running, it cannot be interrupted. If there are many configured servers and domain name suffixes, domain name mapping will take longer.
Example: Look up the IPv4 address of www.att.com.
active500EM(config)#dns lookup ipv4 www.att.com
13.3.5 show dns name-server
Function: Display the information of a configured DNS server.
Parameters: None.
Command mode: Admin and Configuration Mode
Default: None.
Usage guide: Display the information of a configured DNS server.
Example: Display the information of a configured DNS server.
active500EM#show dns name-server DNS NAME SERVER: Address Priority 10.1.120.231 100 10.1.180.85 80 2001::1 20
13.3.6 show dns domain-list
Function: Display the suffix information of a configured DNS domain name.
Parameters: None.
Command mode: Admin and Configuration Mode
Default: None.
Usage guide: Display the suffix information of a configured DNS domain name.
Example: Display the suffix information of a configured DNS domain name.
active500EM#show dns domain-list DNS DOMAIN LIST: com.cn edu.cn
13.3.7 show dns hosts
Function: Display the dynamic domain name information of a resolved host by controller.
Parameters: None.
Command mode: Admin and Configuration Mode
Default: None.
Usage guide: Display the dynamic domain name information of a resolved host by the switch.
Example: Display the dynamic domain name information of a resolved host by the switch.
active500EM#show dns hosts Total number of dynamic host is 2 DNS HOST LIST? Hostname Address Time to live Type www.sina.com.cn 202.108.33.32 168000 dynamic www.ipv6.org 2001:6b0:1: 168060 dynamic
13.3.8 show dns config
Function: Display the configured global DNS information on the switch.
Parameters: None.
Command mode: Admin and Configuration Mode
Default: None.
Usage guide: Display the configured global DNS information on the switch.
Example: Display the configured global DNS information on the switch.
active500EM(config)#show dns config ip dns server enable ip domain-lookup enable the maximum of dns client in cache is 3000, timeout is 5 dns client number in cache is 0 dns dynamic host in cache is 0 dns name server number is 1 dns domain-list number is 0
13.3.9 show dns client
Function: Display the DNS Client information maintained by the switch.
Parameters: None.
Command mode: Admin and Configuration Mode
Default: None.
Usage guide: Display the DNS Client information maintained by the switch.
Example: Display the DNS Client information maintained by the switch.
active500EM(config)#show dns client DNS REQUEST LIST: Total number of dns request is 2 Address Request Id 192.168.11.141 1 192.168.11.138 2
13.3.10ip domain-lookup
no ip domain-lookup
Function: Enable or disable DNS regardless of whether the switch will send dynamic DNS domain queries to the real DNS server.
Parameters: None.
Command mode: Global Mode
Default: Disabled.
Usage guide: This command is used to enable or disable the switch DNS dynamic query function. If DNS dynamic query is enabled, the DNS server will resolve the host name and domain name to the IPv4 or IPv6 address for requests from the clients. If DNS is disabled, client applications will not be able to send any DNS requests to the DNS server. In this situation, only the static address resolution is available. The address mapping in the resolve cache, which was learned through DNS before, will be invalid after aging.
Example: Enable DNS and resolve the dynamic domain name.
active500EM(config)#ip domain-lookup
13.3.11 ip domain-list
no ip domain-list <WORD>
Function: Configure or delete domain name suffixes.
Parameters:
-
<WORD>: character string of domain name suffixes. The string must contain fewer than 63 characters.
Command mode: Global Mode
Default: Disabled.
Usage guide: This command is used to configure or delete suffixes of domain names. When the entered domain name lacks integrity (such as msn), the switch can add a suffix automatically. After that, address mapping can run, but the domain name suffix can be configured to no more than 6. The first configured domain name suffix will be added first.
Example: Configure the domain name suffix of com.
active500EM(config)#ip domain-list com
13.3.12 ip dns server
no ip dns server
Function: Enable or disable the DNS server function.
Parameters: None.
Command mode: Global Mode
Default: Disabled.
Usage guide: After the DNS server function is enabled, the switch will be able to receive and handle DNS requests from the clients by looking them up locally or forwarding the request to the real DNS server.
Example: Configure to enable the DNS server function of the switch.
active500EM(config)#ip dns server
13.3.13 ip dns server queue maximum
no ip dns server queue maximum
Function: Configure the maximum amount of client information in the switch queue.
Parameters:
-
<1-5000>: max value. The valid range is from 1 to 5000.
Command mode: Global Mode
Default: 3000.
Usage guide: When receiving a DNS request from a client, the switch will cache the client?s information. The amount of client information in the queue should not exceed the configured maximum number or the client?s request won?t be handled.
Example: Set the max number of client information in the switch queue as 2000.
active500EM(config)#ip dns server queue maximum 2000
13.3.14 ip dns server queue timeout
no ip dns server queue timeout
Function: Configure the timeout value of caching the client information on the switch.
Parameters:
-
<1-100>: value. The value is in seconds and the valid range is from1 to 100s.
Command mode: Global Mode
Default: 5s.
Usage guide: When receiving a DNS Request from a client, the switch will cache the client?s information. The time spent maintaining the client information should not exceed the configured maximum timeout value or else the client?s information will be cleared.
Example: Configure the maximum timeout value of caching the client information on the switch as 10s.
active500EM(config)#ip dns server queue timeout 10
Return to Controller Wired CLI Table of Contents