The dns-server command configures a DNS server address.
The undo dns-server command deletes the configuration.
By default, no DNS server address is configured.
Parameter | Description | Value |
---|---|---|
ip-address1 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address2 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address3 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address4 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address5 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address6 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address7 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
ip-address8 |
Specifies the IP address of a DNS server. |
The value is in dotted decimal notation. A maximum of eight DNS server addresses can be configured, separated by space. |
all |
Deletes all DNS server addresses. |
- |
Usage Scenario
Before a host accesses the Internet, the DNS server needs to be used to resolve a domain name to an IP address. To allow a DHCP client to properly access the Internet, run the dns-server command to configure the IP address of a DHCP server so that the DHCP server can send DNS server addresses to DHCP clients through Option 6.
Precautions
A maximum of eight NetBIOS server addresses can be specified for each address pool.
If DNS server addresses have been configured in an address pool, running the dns-server command adds new DNS server addresses but does not delete the configured ones. To delete the configured ones, run the undo dns-server command. An earlier configured ip-address has a higher priority. The IP address with the highest priority is used as the primary address, and the other seven IP addresses are used as secondary addresses.