The Ubuntu 18.04 version of the Auvik collector includes a new command-line network configuration utility called Netplan. Netplan easily configures networking on a Linux system by creating a description of the required network interfaces, and what each one should be configured to do, in a
In this article, we’ll walk you through how to:
- List all network interfaces
- Configure the network
- Verify the configuration
Access the collector bash shell
- From the virtual machine window for the collector, click onto the console.
- Select option
yto enter the bash shell from the collector menu.
List all network interfaces
Identify which network interfaces you’ll be configuring by executing the following command:
Configure the network
*.yaml file will be used to configure the network. There can be the odd case where a *
.yaml file isn’t automatically created by the Ubuntu installer. To confirm if you have the necessary file, run the following command from the collector console:
*.yaml file doesn’t exist, run the following command to generate one:
Execute the following command:
Now, edit the file with your favorite editor (vi, for example) following the example below.
NOTE: This file is case-sensitive. Any details entered should be entered as shown below. Be sure to update the IP Address in CIDR notation, interface name (
enp0s8), Gateway4 (
192.168.1.0), and Addresses (
220.127.116.11, 18.104.22.168) to best match your configuration needs.
network: version: 2 renderer: networkd Ethernets: nameOfInterface: Dhcp4: no Dhcp6: no Addresses: [IPaddress/netmask, ] Gateway4: 192.168.1.0 Nameservers: Addresses: [22.214.171.124, 126.96.36.199]
Once you’re sure the details are set as expected, exit configuration mode and save your changes.
Apply your changes by executing the following command:
Configure custom routes
Configure for a directly connected gateway
Configuring for a directly connected gateway is the most common configuration. It allows you to set a default route, or any route, using the “on-link” keyword. You can set up a route on an IP address that’s directly connected to the network, even if the address doesn’t match the subnet configured on the interface.
network: version: 2 renderer: networkd Ethernets: enp0s8: addresses: [ "10.10.10.1/24" ] routes: - to: 0.0.0.0/0 via: 188.8.131.52 on-link: true
Verify the configuration
Run the following to confirm the configuration :
You should see the details you configured above. If you don’t, go back and work through the configuration steps again.