Ubuntu

How to Restart Bluetooth in Ubuntu 20.04

How to Restart Bluetooth in Ubuntu 20.04

One might wish to use the Bluetooth headset to view Netflix and YouTube clips whilst running Ubuntu Linux. Bluetooth is enabled via the interplay of several packages including Bluez, drivers, the Linux kernel as well as client programs. When terminating the entire system, one could have issues with Bluetooth communication. You might believe that the only way to get the Bluetooth connection to function is to reboot the complete system. You will not be able to use these techniques with Ubuntu. We’ve been discussing a simple way for resuming Bluetooth in Ubuntu following conducting an extensive study.

Install Bluetooth Tools and Packages:

Firstly, make sure that you have Bluetooth service configured within the Ubuntu 20.04 system. If you don’t have it, try to install it with the “bluez” package. So, we have been using the apt package to install Bluetooth all tools in a single command as below. Add the password upon request and press “Enter”.

$ sudo apt-get install bluez*

It asks a question from a user if they want to configure Bluetooth on their machine or not. As we want to install it, hence we will tap “y”, otherwise will proceed with tapping “n” to quit it.

It will start processing the packages of Bluetooth and will end up the installation and configuration within a few seconds. The last steps are given in the image below.

Now the installation of Bluetooth has been done. We have to activate and configure it in our system first. So, you need to apply this command in the terminal as below. Add the sudo user passcode to configure it upon required.

$ sudo modprobe btusb

Enable Bluetooth Service:

Now the Bluetooth has been successfully installed and configured, you need to check the status of the Bluetooth service first within the Ubuntu system. For that purpose, we will be using the very familiar “systemctl” command in shell with sudo rights utilizing the keyword “status” along with the name of service e.g. Bluetooth. We have found that the service is currently disabled and inactive as per the below snap.

$ sudo systemctl status bluetooth.service

To enable the service in our system, we will be replacing the above query with the keyword “enable” instead of “status” and executed in our shell. It will synchronize the configured Bluetooth service on our system with system script files.

$ sudo systemctl enable bluetooth.service

To make the enabled service start in our system, we have been using the same instruction while replacing the keyword “enable” with “restart”. This will restart make it active.

$ sudo systemctl restart bluetooth.service

Whenever we check the status of the Bluetooth service once again, we found that it is now active and running properly without an error as per the below snapshot.

$ sudo systemctl status bluetooth.service

Restart Bluetooth Service:

To make the Bluetooth service restart, we need to first stop this service. For that, we will be using the same syntax of the systemctl command while using the “stop” keyword at the place of “status”.

$ sudo systemctl stop bluetooth.service

To restart the Bluetooth service, we need to enable it first as we did before. Hence, we have been using the same systemctl command with a one word change e.g. enable.

$ sudo systemctl enable bluetooth.service

When you check the status of a Bluetooth service, you will find it inactive because we haven’t restarted the service yet.

$ sudo systemctl status bluetooth.service

So, one needs to restart the Bluetooth service to make it active and running. So we have executed the query below.

$ sudo systemctl restart bluetooth.service

After this command, when we have checked the status of the Bluetooth service, we found it active and running.

$ sudo systemctl status bluetooth.service

Conclusion:

Nonetheless, one could have trouble setting up a Bluetooth connection within Ubuntu. In this guide, we have discussed the way to install, configure, enable and then restart the Bluetooth service in the Ubuntu system.

Similar Posts