None of the answers here worked for me, and after several attempts with
nmcli, I eventually gave up and used the Ubuntu 18.04 network interface to create a connection and the I copied it over to the other computer. Here are the steps I followed:
- Create the network connection within the Ubuntu network connection GUI.
- Copy the new connection from
/etc/NetworkManager/system-connections/ on my local compute over to the headless server.
- Edit the MAC ID of the connection to match the interfaces from
- Update the permissions of the copied file with:
chmod 0600 new_connection
chmod root:root new_connection
- Restart the network manager
systemctl restart NetworkManager
For those of you that don't want to manually create the network connection in the GUI, you can modify the following network connection