Wireless Issues with Ubuntu on the Dell XPS 13
The Dell XPS 13 is a great laptop for running Linux on, however, it has some known issues with the wireless adapter Dell includes on the machine. The two general solutions include changing the wireless adapter, and dealing with the driver hurdles.
Changing the wireless adapter isn't too difficult. For some reason, Dell installed a Killer Wireless card in it, which requires a propriety Broadcom wireless driver to work with Linux. Instead, Dell should have installed the Intel wireless 8265 card which works directly with Linux. Most people claim this card solves nearly all wireless issues with the XPS 13. Here is a nice guide covering how to replace the wireless card in the computer.
Nov 5, 2017: I finally got fed up with dealing with the Broadcom drivers, and swapped out the Killer wireless card with the Intel 8265 wireless card. Even though the process was easy, I had an issue where one of the antenna connectors would not snap into the wireless card due to the new card having a bent connector. However, there is a bracket directly above the wireless antenna connectors which is keeping the connector in place despite not being snapped in. Despite this, the new card has been rock solid since installing it 4 months ago. Definitely worth to $20!
Mar 4, 2018: I recently started using a Bluetooth headset for listening to music, utilizing the Bluetooth radio included on the Intel 8265. However, I've noticed that the audio stream drops a few milliseconds during heavy WiFi traffic. I'm assuming this is due to the two radios interfering with each other. This is slightly annoying, but I still think the dual convenience of using the integrated radio and wireless headphones is worth it.
However, if you don't want to swap out the wireless card, here are some tips for solving wireless issues you may experience.
There are many potential solutions to fixing the wireless driver issue. I'll start with the most likely solutions first, then move to the more obscure solutions.
A good command for testing whether the wireless adapter is working is to run:
This will show all wireless adapters you have enabled on your computer. You will know the adapter is successfully working if you see a logical name under the adapter's features.
Restart the Network Manager
A good starting point is to restart the network manager.
Reinstall Wireless Driver
Another good step is to reinstall the Broadcom wireless driver. This involves removing (or purging) the existing driver and downloading the latest driver from the internet. It is also good to ensure the linux-generic package is installed on your system.
If the driver installs without any issue, then you know the driver is compatible with the current system and kernel.
You can also install the Broadcom drivers from the Additional Drivers (or Proprietary Drivers) tab in Software & Updates, however I think it is good to install the driver via command line because it allows you to monitor it's installation progress. For instance, you will see any issues that arise during the installation process.
Another possible issue may be related to the BIOS having Secure Boot enabled. To check the current status of Secure Boot, check it in the BIOS menu. You can do this by restart the computer, but before the Ubuntu OS loads, press F2 (or the Delete key) to access the BIOS menu. Navigate the BIOS until you find the Secure Boot setting, ensuring that it is disabled. Now you can save the settings and restart the computer.
Once you are logged into the computer, see if the WiFi adapter has reappeared. If not, try reinstalling the driver again.
If none of the solutions above worked, you might be experiencing a kernel incompatibility between the kernel and wireless driver. You will be able to identify if this is the case because the bcmwl-kernel-source installation is unable to install wl. You can test this by checking the output of modprobe:
If modprobe returns an error, you know that wl was not able install.
A possible solution would be to downgrade the kernel you are running. If you recently updated the kernel you are running, you should still have your prior kernel installed. This means that you can boot to the prior kernel by specifying it in the GRUB menu at system startup. For Ubuntu 16.04, I was able to force the GRUB menu to appear at bootup by pressing the Escape key. This may require a few attempts before you are able to time the key press correctly.
You can find the current kernel version you are running on your system by running this command:
Another option is to install a different kernel. This is done by downloading the kernel from the main repository here. I recommend using a kernel version with the latest update date. You should download the .deb files for your system architecture (amd64 for most modern computers). Make sure you download the main linux-headers, the generic linux-headers and the generic linux-image debs; similar to this:
Once you have the kernel files downloaded, install them all using this command (make sure these are the only .deb files in the current folder):
If there are no errors, you can restart your computer. The system will boot directly to the latest kernel installed. If you don't want this, you can specify which kernel the system should boot to by specifying it in the GRUB menu.
Once the system has booted, you can check which kernel you are running using:
Now that you are using a different kernel, try reinstalling the wireless driver as specified above.
If none of these solutions worked for you, you should continue Googling your problem. You will eventually stumble on the solution. I'd also start considering changing the wireless adapter your computer has, too. A wireless adapter with built in Linux support will solve many issues directly.
In any case, good luck with your search!