operating system Ubuntu is renowned for its stability and convenience, but for beginners, the initial setup of a wireless connection can seem complicated. Unlike Windows, where drivers are often installed automatically from extensive databases, Linux Sometimes manual intervention is required, especially if you're using newer hardware or specialized adapters. Understanding the basic principles of a network manager will help you avoid many connection issues.
Modern versions of the distribution, such as Ubuntu 22.04 LTS or 24.04, use the GNOME graphical shell, which makes the user experience as simple as possible. However, command-line skills remain critical for diagnosing and resolving complex network conflicts. We'll explore both approaches so you can choose the one that best suits your situation.
Before you begin setting up, make sure your Wi-Fi adapter is physically working properly and is not disabled by the hardware switch on the laptop case. In some cases, the problem can be resolved by simply restarting the NetworkManager service rather than complexly reinstalling the drivers. Let's walk through the connection process step by step, from simple steps to advanced configuration.
Checking the adapter status and installing drivers
The first step should always be to diagnose the current hardware status. The system may not recognize the wireless card due to the lack of proprietary drivers that are not included in the standard kernel. LinuxUbuntu has a convenient tool for searching and installing such components.
Open the application menu and find the utility. Programs and updates. Go to the tab Additional driversThe system will scan your hardware and offer available driver options for your Wi-Fi moduleIf a suggestion is found, select it and click the Apply Changes button.
⚠️ Important: After installing proprietary drivers, be sure to perform a full reboot of your computer, not just log out. Otherwise, the new kernel module will not activate, and the adapter will remain inoperable.
If the GUI does not show any results, you can use the terminal for a more detailed check. Command lspci for internal cards or lsusb for external adapters will allow you to identify the device model. The resulting Vendor ID And The Device ID can be used to search for specific instructions on community forums.
Setting up a connection via a graphical interface
For most standard desktop users, the most convenient method remains the built-in network manager. The interface is intuitive and hides complex technical details, allowing you to connect to the network in just a few clicks.
In the upper right corner of the screen, find the network icon (usually two arrows or a fan). Click it to see a list of available wireless networks. Select the one you need from the list. SSID and enter the security password. If the network is hidden, select "Connect to a hidden network" and enter the name manually.
☑️ Check before connection
In the advanced settings, accessible through the menu Settings → Wi-Fi, you can manage network priority. If you have multiple routers or repeaters at home with the same name, the system may try to connect to a weak signal. In such cases, it's useful to temporarily ignore certain access points.
Using the Terminal: Netplan and Network Manager
Server versions Ubuntu or minimalist builds don't have a graphical shell, so network management is handled through configuration files. Modern versions of the distribution use the utility by default. Netplan, which generates a configuration for NetworkManager or systemd-networkd.
Configuration files are located in the directory /etc/netplan/To edit, use a text editor with superuser rights, for example sudo nano /etc/netplan/01-netcfg.yamlYAML syntax requires strict indentation, so be careful when entering data.
network:version: 2
renderer: networkd
ethernets:
enp0s3:
dhcp4: true
wifis:
wlp0s20f3:
dhcp4: true
access-points:
"MyHomeNetwork":
password: "SuperSecretPassword"
After making changes, you need to apply the configuration with the command sudo netplan applyIf the syntax is incorrect, the system will return an error and not apply the settings, which will prevent connection loss. For debugging, use the command sudo netplan try, which will roll back changes after 120 seconds if you lose access to the server.
What to do if Netplan doesn't work?
Older versions of Ubuntu (before 17.10) used the interfaces file. If you're using a legacy system, check for the presence of the /etc/network/interfaces file. However, Netplan is the correct file for current versions.
Troubleshooting connection and driver issues
Even with proper configuration, conflicts can arise, especially if other operating systems have been previously installed on the computer or the hardware has been upgraded. A common issue is the "connected but no internet" state or the inability to obtain an IP address.
One effective method is to reset the network manager. This can be done by stopping the service, clearing the cache, and restarting it. It's also worth checking if a firewall is blocking it. UFW outgoing connection.
- 🔄 Restart the service with the command:
sudo systemctl restart NetworkManager - 📡 Check network scanning:
nmcli dev wifi list - 🔌 Disable and enable the interface:
nmcli radio wifi offthennmcli radio wifi on
⚠️ Note: Interfaces in Linux may change their names after a kernel update or motherboard replacement. Instead of the usual
wlan0you may see a name likewlo1orenp3s0Always check the current device name before entering commands.
If the issue is related to power saving, the card may shut down to conserve battery power, resulting in disconnected connections. This feature can be disabled in the driver configuration file or through the settings. tlp, if this package is installed to optimize battery life.
Setting up a static IP address
In corporate networks or to organize access to a home server, a fixed IP addressDynamic address distribution (DHCP) is convenient for guests, but for permanent devices, it's better to reserve an address so that the path to them doesn't change.
You can configure static IP addresses through the graphical interface by selecting the IPv4 tab in the network settings and switching the method to "Manual." However, for servers, editing the file is preferable. NetplanThis ensures that the settings are preserved after a reboot and are applied early in the system boot process.
| Parameter | Example of meaning | Description |
|---|---|---|
| addresses | 192.168.1.50/24 | Static IP and subnet mask |
| gateway4 | 192.168.1.1 | Gateway (router) address |
| nameservers | 8.8.8.8, 1.1.1.1 | DNS servers for name resolution |
| search | local | Domain name for search |
When specifying DNS servers, it's recommended to use reliable public services like Google or Cloudflare, especially if your ISP is having trouble resolving domains. This often speeds up browser response times when opening websites.
Diagnostics and signal analysis
When a connection is established but unstable, it's necessary to analyze the signal quality and noise level. Linux offers powerful monitoring tools that allow you to get a real picture of the broadcast environment.
Utility iwlist or more modern iw Provides detailed information about the channel, frequency, and signal strength. A low signal strength (less than -75 dBm) may indicate the need to change the channel on the router or install a repeater.
iwlist wlo1 scanning | grep -E 'SSID|Quality'
This command will scan your surroundings and display a list of networks with good signal strength. Pay attention to neighboring networks operating on the same channel—they can cause interference. Switching your router to a less congested channel can significantly improve speed.
How do I find out the MAC address of my adapter?
To view the MAC address, use the command ip link show or ifconfig. Look for the line link/ether next to the name of your wireless interface. This is a 12-digit hexadecimal code unique to your device.
Why can't Ubuntu see 5GHz Wi-Fi networks?
This may be due to regional settings. If the country code is set incorrectly (for example, US instead of RU or DE), some channels may be blocked. You can change the region using the command sudo iw reg set RU.
Is it possible to share Wi-Fi with Ubuntu?
Yes, modern versions of Ubuntu allow you to create an access point directly from the network settings. Select "Use as access point" in the Wi-Fi menu and set a name and password. However, support for AP mode depends on your adapter's driver.