While setting up Ubuntu Server, I discovered that it only had Netplan installed for network configuration β no NetworkManager
or other tools.
π Finding the Configuration File
Netplan configuration was located at:
/etc/netplan/50-cloud-init.yaml
βοΈ Editing the Netplan Config
To set up both a DHCP Ethernet connection and a hidden Wi-Fi network, I edited the YAML file:
sudo nano /etc/netplan/50-cloud-init.yaml
Hereβs what the configuration looked like:
network:
version: 2
renderer: networkd
ethernets:
enp0s31f6:
dhcp4: true
wifis:
wlp0s20f3:
dhcp4: true
access-points:
"My Hidden SSID":
auth:
key-management: "psk"
password: "YourPassword"
hidden: true
π Note: To connect to a hidden WPA/WPA2 Wi-Fi network, both
password
andhidden: true
must be placed inside theauth
block. Placing them outside will cause Netplan to error or silently ignore the Wi-Fi configuration.
πΎ Save and Apply the Configuration
After saving and exiting the file:
sudo netplan apply
Netplan brought up both my Ethernet (enp0s31f6
) and Wi-Fi (wlp0s20f3
) connections successfully, including the hidden SSID.