I need help, and it is quite urgent. I had connections issues (my Wi-Fi connection kept disconnecting)
So I followed what a member of this community recommended, in a similar post written by a fellow member
I entered these commands in a shell
sudo apt-get purge network-manager
sudo apt-get update
sudo apt-get autoremove
sudo apt-get upgrade
sudo apt-get install network-manager
sudo apt install ubuntu-desktopAnd now... I don't see any wifi parameters. I can't connect to the internet...
How can I fix this?
Here is what I get when i type sudo dmesg | grep wlo1
101 Answer
In the absense of Network Manager, I suggest that you use netplan. From the terminal, do:
ls /etc/netplanFind out the name of the file. Make a backup as you will need it after reinstalling NM:
sudo mv /etc/netplan/<file_you_found>.yaml /etc/netplan/<file_you_found>.bakNow, let’s create a new file:
sudo nano /etc/netplan/config.yamlWrite the file to read:
network: version: 2 renderer: networkd wifis: wlo1: dhcp4: yes dhcp6: yes access-points: "network_ssid_name": password: "**********"Of course, substitute your details here. Note that the network name and password are enclosed in quotes “.
Netplan is very specific about spacing, indentation, etc., so proofread carefully twice. Save (Ctrrl+o followed by Enter) and exit nano (Ctrl+x followed by Enter).
Follow with:
sudo netplan generate
sudo netplan applyDid you connect?
iwconfig
ping -c3 It might take a reboot.
If you are connected, reinstall NM:
sudo apt update
sudo apt install –reinstall network-manager ubuntu-desktopReboot and tell us if there is any improvement. If so, I will edit this answer to revert netplan.
EDIT: Now that you are connected and have reinstalled Network Manager, we should revert the netplan file to again refer to NM.
Please do:
ls /etc/netplanI assume that the file you backed up is /etc/netplan/01-network-manager-all.bak
If so, first back up the file you just created above:
sudo mv /etc/netplan/config.yaml /etc/netplan/config.bakAnd restore the previous file:
sudo mv /etc/netplan/01-network-manager-all.bak /etc/netplan/01-network-manager-all.yamlFollow with:
sudo netplan generate
sudo netplan applyYou should be all set.
15