OcNOS SP : System Management Guide : DNS Command Reference : Domain Name System Relay Commands
Domain Name System Relay Commands
This chapter describes the DNS relay commands:
ip dns relay (global)
Use this command to globally enable the IPv4 DNS relay agent.
Use the no form of this command to globally disable the IPv4 DNS relay agent.
Command Syntax
ip dns relay
no ip dns relay
Parameters
None
Default
By default, IPv4 DNS relay agent is enabled.
Command Mode
Configure mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#ip dns relay
 
(config)#no ip dns relay
 
ip dns relay (interface)
Use this command to configure an IPv4 interface as a DNS relay client-facing port.
Use the no form of this command to remove an IPv4 interface as a DNS relay client-facing port.
Command Syntax
ip dns relay
no ip dns relay
Parameters
None
Default
N/A
Command Mode
Interface mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#int xe44
(config-if)#ip address 4.4.4.1/24
(config-if)#ip dns relay
 
(config)#int xe44
(config-if)#ip vrf forwarding vrf1
(config-if)#ip address 4.4.4.1/24
(config-if)#ip dns relay
 
ip dns relay address
Use this command to set the IP address of a DNS server.
Use the no form of this command to remove the IP address of a DNS server.
Command Syntax
ip dns relay address A.B.C.D
no ip dns relay address A.B.C.D
Parameters
A.B.C.D
IPv4 address of the DNS server
Default
N/A
Command Mode
Configure mode
VRF mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#ip dns relay address 1.1.1.2
#
(config)#ip vrf vrf1
(config-vrf)#ip dns relay address 1.1.1.2
 
ip dns relay uplink
Use this command to configure an IPv4 interface as a DNS relay server-facing port.
Use the no form of this command to remove an IPv4 interface as a DNS relay server-facing port.
Command Syntax
ip dns relay uplink
no ip dns relay uplink
Parameters
None
Default
N/A
Command Mode
Interface mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#int xe44
(config-if)#ip address 4.4.4.1/24
(config-if)#ip dns relay uplink
ipv6 dns relay (global)
Use this command to globally enable the IPv6 DNS relay agent.
Use the no form of this command to globally disable the IPv6 DNS relay agent.
Command Syntax
ipv6 dns relay
no ipv6 dns relay
Parameters
None
Default
By default, the IPv6 DNS relay agent is enabled.
Command Mode
Configure mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#ipv6 dns relay
 
#(config)#no ipv6 dns relay
 
 
Ipv6 dns relay (interface)
Use this command to configure an IPv6 interface as a DNS relay client-facing port.
Use the no form of this command to remove an IPv6 interface as a DNS relay client-facing port.
Command Syntax
ipv6 dns relay
no ipv6 dns relay
Parameters
None
Default
N/A
Command Mode
Interface mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#int xe44
(config-if)#ipv6 address fd02::1/16
(config-if)#ipv6 dns relay
 
(config)#int xe44
(config-if)#ip vrf forwarding vrf1
(config-if)#ipv6 address fd02::1/16
(config-if)#ipv6 dns relay
 
ipv6 dns relay address
Use this command to set the IPv6 address of a DNS server.
Use the no form of this command to remove the IPv6 address of a DNS server.
Command Syntax
ipv6 dns relay address X:X::X:X
no ipv6 dns relay address X:X::X:X
Parameters
X:X::X:X
IPv6 address of the DNS server
Default
N/A
Command Mode
Configure mode
VRF mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#ipv6 dns relay address 2001:4860:4860::8888
 
(config)#ip vrf vrf1
(config-vrf)#ip dns relay address 2001:4860:4860::8888
 
ipv6 dns relay uplink
Use this command to configure an IPv6 interface as a DNS relay server-facing port.
Use the no form of this command to remove an IPv6 interface as a DNS relay server-facing port.
Command Syntax
ipv6 dns relay uplink
no ipv6 dns relay uplink
Parameters
None
Default
N/A
Command Mode
Interface mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#configure terminal
(config)#int xe44
(config-if)#ipv6 address fd02::1/16
(config-if)#ipv6 dns relay uplink
 
 
show ip dns relay
Use this command to display the IPv4 DNS relay configuration including VRF name, DNS servers, and client/user facing interfaces.
Command Syntax
show ip dns relay
Parameters
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#show ip dns relay
DNS feature status: Enabled
DNS relay service status: Enabled
VRF Name: vrf1
Status : Running
DNS Servers: 1.1.1.2
Interfaces :
Name Type State Address
-------------------------------- ----------
xe1 Uplink UP 1.1.1.1
xe32 Downlink UP 2.2.2.1
xe33 Downlink UP 3.3.3.1
xe44 Downlink UP 4.4.4.1
VRF Name: management
Status : Running
DNS Servers: 8.8.8.8
Interfaces :
Name Type State Address
-------------------------------- ----------
eth0 Downlink UP 172.29.4.139
Table 2-2 explains the fields in the output.
Table 2-2: show ip dns relay fields 
Field
Description
DNS feature status
Whether DNS relay is enabled
DNS relay service status
Whether DNS relay is enabled
VRF Name
Name of the VRF
Status
Not-running, Running, or Failed
DNS Servers
IPv4 address of the DNS server
Name
DNS server facing interface
Type
Whether an uplink or a downlink
State
Whether the interface is up of down
Address
IPv4 address of the interface
 
show ip dns relay address
Use this command to display the IPv4 DNS relay configuration including VRF name and DNS servers.
Command Syntax
show ip dns relay address
Parameters
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#show ip dns relay address
DNS feature status: Enabled
DNS relay service status: Enabled
VRF Name: vrf1
Status : Running
DNS Servers: 1.1.1.2
VRF Name: management
Status : Running
DNS Servers: 8.8.8.8
Table 2-3 explains the fields in the output.
Table 2-3: show ip dns relay address fields 
Field
Description
DNS feature status
Whether DNS relay is enabled
DNS relay service status
Whether DNS relay is enabled
VRF Name
Name of the VRF
Status
Not-running, Running, or Failed
DNS Servers
IPv4 address of the DNS server
 
show ipv6 dns relay
Use this command to display IPv6 DNS relay configuration including VRF name, DNS servers, and client/user facing interfaces.
Command Syntax
show ipv6 dns relay
Parameters
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#show ipv6 dns relay
DNS feature status: Enabled
DNS relay IPv6 service status: Enabled
VRF Name: vrf1
Status : Not-running
DNS Servers: fd01::2
Interfaces :
Name Type State Address
-------------------------------- ----------
xe44 Downlink UP fd02::1
Table 2-4 explains the fields in the output.
Table 2-4: show ipv6 dns relay fields 
Field
Description
DNS feature status
Whether DNS relay is enabled
DNS relay IPv6 service status
Whether DNS relay is enabled
VRF Name
Name of the VRF
Status
Not-running, Running, or Failed
DNS Servers
IPv6 address of the DNS server
Name
DNS server facing interface
Type
Whether an uplink or a downlink
State
Whether the interface is up of down
Address
IPv6 address of the interface
show ipv6 dns relay address
Use this command to display the IPv6 DNS relay configuration including the VRF name and DNS servers.
Command Syntax
show ipv6 dns relay address
Parameters
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#show ipv6 dns relay
DNS feature status: Enabled
DNS relay IPv6 service status: Enabled
VRF Name: vrf1
Status : Not-running
DNS Servers: fd01::2
Table 2-5 explains the fields in the output.
Table 2-5: show ipv6 dns relay address fields 
Field
Description
DNS feature status
Whether DNS relay is enabled
DNS relay IPv6 service status
Whether DNS relay is enabled
VRF Name
Name of the VRF
Status
Not-running, Running, or Failed
DNS Servers
IPv6 address of the DNS server
show running-config dns relay
Use this command to display DNS relay settings in the running configuration.
Command Syntax
show running-config dns relay
Parameters
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 5.0.
Example
#show running-config dns relay
no ipv6 dns relay
!
ip vrf vrf1
ip dns relay address 1.1.1.2
ipv6 dns relay address fd01::2
!
ip vrf management
ip dns relay address 8.8.8.8
!
interface eth0
ip dns relay
!
interface xe1
ip dns relay uplink
!
interface xe32
ip dns relay
!
interface xe33
ip dns relay
!
interface xe44
ip dns relay
ipv6 dns relay
!