Network
Network Management CLI
Available since
- HAProxy ALOHA 16.5
The HAProxy ALOHA Network Management CLI provides a way to manage connection profiles via the command line. Connection profiles are collections of network interface settings. You can use the Network Management CLI to manage physical and virtual network interfaces on the command line.
Common use cases for the Network Management CLI include managing VLAN interfaces, managing link bonding, and configuring VRRP.
This section describes how to install the HAProxy ALOHA management package which includes the Network Management CLI.
Install the HAProxy ALOHA network management package Jump to heading
Network Management CLI may already be installed
If you installed the Data Plane API on HAProxy ALOHA using the HAProxy ALOHA management package version 16.5 or greater, the Network Managment CLI is already installed. If you installed the Data Plane API using the HAProxy ALOHA management package version 16.0 or earlier, you may need to update to a newer version of the API.
To install the Network Management CLI, follow the instructions to install the Data Plane API on HAProxy ALOHA. Both the Network Management CLI and Data Plane API belong to the same HAProxy ALOHA management package. You must install version 16.5 or later of the management package to enable the Network Management CLI.
To verify the Network Management CLI is ready for use, navigate to the File Manager in the Tools tab, and check that the netctl
binary exists in /app/management/usr/bin
. This means that the Network Management CLI is succesfully installed. The netctl
utility is what you will use when calling Network Management CLI commands.
Use the Network Management CLI Jump to heading
You can use the Network Management CLI to view your devices and your connection profiles. A device is either a physical network interface on the host, for example eth0
, or a virtual network interface, for example eth1.1
for VLAN, that is created when its connection profile is activated. A connection profile is a collection of network interface settings.
List devices Jump to heading
To list devices use the following command:
nix
sudo netctl device
nix
sudo netctl device
outputtext
eth0 ethernet connected 724c15e7-b28c-496b-97f9-c55be72973eceth1 ethernet connected 957fd9a2-90ee-4f6e-b8a9-3b8b1aa3b45deth2 ethernet connected d2113eaf-ed24-44d2-85c8-c26d2336bb16eth3 ethernet connected 8ebb39e8-6dcd-4009-abab-aa787cdec405eth4 ethernet connected cc47d1af-f0b9-4368-a9cf-4d4525d4037alo loopback unmanaged --
outputtext
eth0 ethernet connected 724c15e7-b28c-496b-97f9-c55be72973eceth1 ethernet connected 957fd9a2-90ee-4f6e-b8a9-3b8b1aa3b45deth2 ethernet connected d2113eaf-ed24-44d2-85c8-c26d2336bb16eth3 ethernet connected 8ebb39e8-6dcd-4009-abab-aa787cdec405eth4 ethernet connected cc47d1af-f0b9-4368-a9cf-4d4525d4037alo loopback unmanaged --
Each device will show a status. If the connection is activated for the device it will show as connected
. If its connection is not activated, it will show as unavailable
. Devices showing as unmanaged
cannot have a connection activated on them.
List connection profiles Jump to heading
To list all connection profiles use the following command:
sudo netctl connection
sudo netctl connection
outputtext
ID UUID TYPE DEVICEethernet-eth0 724c15e7-b28c-496b-97f9-c55be72973ec ethernet eth0ethernet-eth1 957fd9a2-90ee-4f6e-b8a9-3b8b1aa3b45d ethernet eth1ethernet-eth2 d2113eaf-ed24-44d2-85c8-c26d2336bb16 ethernet eth2ethernet-eth3 8ebb39e8-6dcd-4009-abab-aa787cdec405 ethernet eth3ethernet-eth4 cc47d1af-f0b9-4368-a9cf-4d4525d4037a ethernet eth4
outputtext
ID UUID TYPE DEVICEethernet-eth0 724c15e7-b28c-496b-97f9-c55be72973ec ethernet eth0ethernet-eth1 957fd9a2-90ee-4f6e-b8a9-3b8b1aa3b45d ethernet eth1ethernet-eth2 d2113eaf-ed24-44d2-85c8-c26d2336bb16 ethernet eth2ethernet-eth3 8ebb39e8-6dcd-4009-abab-aa787cdec405 ethernet eth3ethernet-eth4 cc47d1af-f0b9-4368-a9cf-4d4525d4037a ethernet eth4
The output includes the list of all connection profiles and their settings. These settings include:
- the
ID
for the connection profile or its name - the
UUID
which is a unique identifier for the connection profile - the
type
of connection, for examplebond
,ethernet
, andvlan
- the
interface-name
or the name of the device associated with the connection profile
Show connection profile Jump to heading
You can view all of the attributes associated with a connection profile using the netctl connection show
command:
nix
sudo netctl connection show ethernet-eth0
nix
sudo netctl connection show ethernet-eth0
outputtext
connection.id ethernet-eth0connection.interface-name eth0connection.master ---connection.slave-type ---connection.type 802-3-ethernetconnection.uuid d6180bf1-6e06-486e-bc74-dda587cd9145802-3-ethernet.auto-negotiate false802-3-ethernet.duplex ---802-3-ethernet.mtu ---802-3-ethernet.speed ---ipv4.addresses 192.168.0.200/24ipv4.gateway 192.168.0.1ipv4.method autoipv4.routes ---ipv6.addresses ---ipv6.gateway ---ipv6.method disabledipv6.routes ---vrrp.instances ---
outputtext
connection.id ethernet-eth0connection.interface-name eth0connection.master ---connection.slave-type ---connection.type 802-3-ethernetconnection.uuid d6180bf1-6e06-486e-bc74-dda587cd9145802-3-ethernet.auto-negotiate false802-3-ethernet.duplex ---802-3-ethernet.mtu ---802-3-ethernet.speed ---ipv4.addresses 192.168.0.200/24ipv4.gateway 192.168.0.1ipv4.method autoipv4.routes ---ipv6.addresses ---ipv6.gateway ---ipv6.method disabledipv6.routes ---vrrp.instances ---
Hit tab twice after the command
Enter TAB
twice after your netctl
command to see available parameters. Here are some examples:
nix
admin@ALOHA1:~$ netctl <TAB> <TAB>connection device
nix
admin@ALOHA1:~$ netctl <TAB> <TAB>connection device
nix
admin@ALOHA1:~$ netctl connection <TAB> <TAB>add delete down modify show up
nix
admin@ALOHA1:~$ netctl connection <TAB> <TAB>add delete down modify show up
nix
admin@ALOHA1:~$ netctl connection add802-3-ethernet.auto-negotiate connection.interface-name ethernet.mtu ipv4.routes type802-3-ethernet.duplex connection.master ethernet.speed ipv6.addresses vlan.id802-3-ethernet.mtu connection.slave-type id ipv6.gateway vlan.parent802-3-ethernet.speed connection.type ifname ipv6.method vrrp.instancesbond.options dev ipv4.addresses ipv6.routescon-name ethernet.auto-negotiate ipv4.gateway masterconnection.id ethernet.duplex ipv4.method slave-type
nix
admin@ALOHA1:~$ netctl connection add802-3-ethernet.auto-negotiate connection.interface-name ethernet.mtu ipv4.routes type802-3-ethernet.duplex connection.master ethernet.speed ipv6.addresses vlan.id802-3-ethernet.mtu connection.slave-type id ipv6.gateway vlan.parent802-3-ethernet.speed connection.type ifname ipv6.method vrrp.instancesbond.options dev ipv4.addresses ipv6.routescon-name ethernet.auto-negotiate ipv4.gateway masterconnection.id ethernet.duplex ipv4.method slave-type
nix
admin@ALOHA1:~$ netctl connection modify.config.rc2760958571: .config.rc3922829236: denied id open permission uuid
nix
admin@ALOHA1:~$ netctl connection modify.config.rc2760958571: .config.rc3922829236: denied id open permission uuid
Do you have any suggestions on how we can improve the content of this page?