dns-server

Use this command to assign one or more DNS servers to DHCP or DHCPv6 clients.

Syntax

dns-server address [address2...address8]
no dns-server address [address2...address8]

Parameters

address Specifies the IPv4 or IPv6 address of a DNS server.
address2...
address8 (Optional) Specifies, in order of preference, up to 7 additional DNS server IPv4 or IPv6 address(es).

Defaults

If address2...address8 is not specified, no additional addresses will be configured.

Mode

DHCP address pool, class, or host configuration command mode for IPv4; DHCPv6 server information options pool configuration command mode for IPv6.

Usage

This command configures either IPv4 DHCP option 6 or DHCPv6 option 23.

The “no” form of this command deletes the DNS servers.

Example

This example shows how to assign an IPv4 DNS server at address 11.12.1.99 to the localpool address pool:

System(rw-config)->ip dhcp pool localpool
System(rw-config-dhcp-pool)->dns-server 11.12.1.99

This example shows how to assign an IPv6 DNS server at addresses 1111::12, 1111::13, and 1111::14 to the docPool DHCPv6 server information options pool:

System(rw-config)->ipv6 dhcp pool docPool
System(rw-config-dhcp-v6-pool)->dns-server 1111::12 1111::13 1111::14