Tip

This is the documentation for the 24.06 version. Looking for the documentation of the latest version? Have a look here.

Associating TNSR Interfaces with Shell Interfaces

Interfaces in TNSR will have names such as GigabitEthernet3/0/0 or custom names such as WAN. When working in the shell in the dataplane namespace the interfaces will appear as different names, such as vpp1. To help correlate the relationship between TNSR interfaces and those seen in the shell, TNSR adds its interface names as an alias, visible with the dp-exec ip link command:

$ dp-exec ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: myroutes: <NOARP,MASTER,UP,LOWER_UP> mtu 65536 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether 06:04:b5:50:f7:2c brd ff:ff:ff:ff:ff:ff
41: vpp1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UNKNOWN mode DEFAULT group default qlen 1000
    link/ether 00:90:0b:7d:17:ce brd ff:ff:ff:ff:ff:ff
    alias GigabitEthernet6/0/0
42: vpp2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UNKNOWN mode DEFAULT group default qlen 1000
    link/ether 00:90:0b:7d:17:cf brd ff:ff:ff:ff:ff:ff
    alias GigabitEthernet3/0/0

In the output above, the vpp1 interface alias is GigabitEthernet6/0/0 indicating that it corresponds to the TNSR interface GigabitEthernet6/0/0.

Troubleshooting DHCP Client

When a TNSR interface is acting as a DHCP client, TNSR uses the dhclient systemd service in the dataplane namespace to manage the interface address. This provides additional troubleshooting options such as DHCP client status, logs, and service control.

First determine the exact name of the service instance. The general form of the service name is dhclient-dataplane@<shell interface name>.service. To find the shell interface name which corresponds to a TNSR interface, see Associating TNSR Interfaces with Shell Interfaces. This example assumes vpp1 as the interface resulting in a service name of dhclient-dataplane@vpp1.service.

To view the status of the service and a small portion of the logs, use:

$ dp-exec sudo systemctl status dhclient-dataplane@vpp1.service

To view more of the logs, use:

$ dp-exec sudo journalctl -xeu dhclient-dataplane@vpp1.service

To control the service, use:

$ dp-exec sudo systemctl <command> dhclient-dataplane@vpp1.service

Where <command> is stop, start, or restart. In most cases when troubleshooting, a restart command is ideal as it will stop and start the service which triggers the client to attempt to obtain an address again. If the client still could not obtain an address, check the logs again for more information.