H3C WX3000 Series Unified Switches Switching Engine Command Reference-6W103

HomeSupportWirelessH3C WX3000 Series Unified SwitchesReference GuidesCommand ReferencesH3C WX3000 Series Unified Switches Switching Engine Command Reference-6W103
34-DNS Command
Title Size Download
34-DNS Command 41.5 KB

DNS Configuration Commands

display dns domain

Syntax

display dns domain [ dynamic ]

View

Any view

Parameters

dynamic: Displays DNS suffixes dynamically assigned through DHCP or other protocols.

Description

Use the display dns domain command to display the DNS suffixes.

Related commands: dns domain.

Examples

# Display DNS suffixes

<device> display dns domain

No         Domain-name

0          aaa.com

Table 1-1 display dns domain command output description

Field

Description

No

Sequence number

Domain-name

DNS suffix

 

display dns dynamic-host

Syntax

display dns dynamic-host

View

Any view

Parameters

None

Description

Use the display dns dynamic-host command to display the information in the dynamic domain name cache.

Examples

# Display the information in the dynamic domain name cache.

<device> display dns dynamic-host

No Domain-name           --->    Ipaddress       TTL     Alias

 

No Domain-name           <---    Ipaddress       TTL     Alias

Table 1-2 display dns dynamic-host command output description

Field

Description

No

Sequence number

Domain-name

Domain name

Ipaddress

IP address of the corresponding domain name

TTL

Time for which an entry is cached in seconds.

Alias

Alias for the domain name. There can be four aliases at most.

--->

<---

DNS has two types:

Forward resolution: domain name--->IP address

Reverse resolution: IP address--->domain name

 

display dns server

Syntax

display dns server [ dynamic ]

View

Any view

Parameters

dynamic: Displays the DNS Server information dynamically obtained through DHCP or other protocols.

Description

Use the display dns server command to display the DNS Server information.

Related commands: dns server.

Examples

# Display the DNS Server information.

<device> display dns server

 Type:

  D:Dynamic    S:Static

 

IPv4 DNS Servers :

Domain-server Type IP Address

     1        S    192.168.0.4

 

IPv6 DNS Servers :

Table 1-3 display dns server command output description

Field

Description

Type

Type of the DNS server. S indicates the DNS server is specified manually, while D indicates the DNS server information is obtained dynamically through DHCP or other protocols.

IPv4 DNS Servers

IPv4 DNS server

IPv6 DNS Servers

IPv6 DNS server

Domain-server

Number of the DNS server, which is assigned automatically by the system and starts from 1. Such numbering for IPv4 DNS servers is independent of that for IPv6 ones.

 

For details about IPv6 DNS, refer to IPv6 Management in H3C WX3000 Series Unified Switches Switching Engine Command Reference.

 

display ip host

Syntax

display ip host

View

Any view

Parameters

None

Description

Use the display ip host command to display mappings between host names and IP addresses in the static DNS database.

Examples

# Display mappings between host names and IP addresses in the static DNS database.

<device> display ip host

Host                           Age        Flags  Address

host.com                       0          static 192.168.0.38

Table 1-4 display ip host command output description

Field

Description

Host

Host name

Age

Time to live. 0 means that a static entry is never outdated.

You can only manually remove the mappings between host names and IP addresses.

Flags

Indicates the type of mappings between host names and IP addresses, static or dynamic

Static indicates static mapping between host names and IP addresses

Address

IP address of a host

 

dns domain

Syntax

dns domain domain-name

undo dns domain [ domain-name ]

View

System view

Parameters

domain-name: DNS suffix, a string of 1 to 60 characters which can be letters, numbers, hyphens (-), underscores (_), and dots (.).

Description

Use the dns domain command to configure a DNS suffix.

Use the undo dns domain command to delete the configured DNS suffix.

No DNS suffix is configured by default.

You can configure a maximum of 10 DNS suffixes. You must enter the DNS suffix before deleting it. Otherwise, all configured DNS suffixes are deleted.

Related commands: display dns domain.

 

The DNS feature supported by the device should be used together with a DNS server. DNS implementations vary with DNS servers. For example, the device supports a domain name containing “_”, while a Windows 2000 Server PC may fail to resolve the domain name.

 

Examples

# Configure com as a DNS suffix.

<device> system-view

System View: return to User View with Ctrl+Z.

[device] dns domain com

dns resolve

Syntax

dns resolve

undo dns resolve

View

System view

Parameters

None

Description

Use the dns resolve command to enable dynamic domain name resolution.

Use the undo dns resolve command to disable dynamic domain name resolution.

Dynamic domain name resolution is disabled by default.

Examples

# Enable dynamic domain name resolution.

<device> system-view

System View: return to User View with Ctrl+Z.

[device] dns resolve

dns server

Syntax

dns server ip-address

undo dns server [ ip-address ]

View

System view

Parameters

ip-address: IP address of the DNS Server.

Description

Use the dns server command to configure an IP address for the DNS Server.

Use the undo dns server to remove the IP address of the DNS server.

No IP address is configured for the DNS Server by default.

You can configure a maximum of 6 DNS Servers.

Related commands: display dns server.

Examples

# Configure 172.16.1.1 for a DNS Server.

<device> system-view

System View: return to User View with Ctrl+Z.

[device] dns server 172.16.1.1

ip host

Syntax

ip host hostname ip-address

undo ip host hostname [ ip-address ]

View

System view

Parameters

hostname: Host name, a string of 1 to 20 characters which can be letters, numbers, hyphens (-), or dots (.). The host name must include at least one letter.

ip-address: IP address of the specified host, in dotted decimal notation.

Description

Use the ip host command to create a mapping between host name and IP address in the static DNS database.

Use the undo ip host command to remove the mapping.

No mappings are created by default.

Each host name can correspond to only one IP address. When IP addresses are configured for the same host for multiple times, only the IP address configured last time is valid.

Related commands: display ip host.

Examples

# Configure the IP address 10.110.0.1 for the host named aaa.

<device> system-view

System View: return to User View with Ctrl+Z.

[device] ip host aaa 10.110.0.1

nslookup type

Syntax

nslookup type { ptr ip-address | a domain-name }

View

Any view

Parameters

ptr ip-address: Resolves the corresponding domain name for an IP address.

a domain-name: Resolves the corresponding IP address for a DNS domain name. A domain name is a string of up to 30 characters. Automatic domain name addition is supported.

Description

Use the nslookup type command to display DNS resolution result, namely, the domain name for a specified IP address or IP address for a specified domain name.

Examples

# Display the corresponding domain name for 192.168.3.2.

<device> nslookup type ptr 192.168.3.2

Trying DNS server (10.72.66.36)

Name:    www.host.com

Address:  192.168.3.2

# Display the corresponding IP address for www.host.com.

<device> nslookup type a www.host.com

Trying DNS server  (10.72.66.36)

Name:    www.host.com

Address:  192.168.3.2

reset dns dynamic-host

Syntax

reset dns dynamic-host

View

User view

Parameters

None

Description

Use the reset dns dynamic-host command to clear information in the dynamic domain name cache.

Related commands: display dns dynamic-host.

Examples

# Clear the information in the dynamic domain name cache.

<device> reset dns dynamic-host

 

  • 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
新华三官网