0

I've recently installed Ubuntu 20.04.1 LTS in my laptop, every time, when I turn on the laptop, the Wifi option is disabled.
In order to enable it, I've had to run the below command and restart my laptop (everytime).

sudo service network-manager restart

Is there any way, to make Ubuntu automatically detect Wifi, without having to restart the network-manager?

I've disabled Secure boot,
I was unable to connect to Wifi, when I was installing Ubuntu.
I'm dual booting Ubuntu with Windows 10

Please let me know, if you guys know, a permanent fix for this problem,

cat /etc/network/interfaces
output:

cat: /etc/network/interfaces: No such file or directory

cat /etc/netplan/*.yaml
output:

network:
  renderer: NetworkManager
# Let NetworkManager manage all devices on this system
network:
  version: 2
  renderer: NetworkManage

sudo lshw -C network
output:

*-network                 
       description: Ethernet interface
       product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: enp2s0
       version: 15
       serial: b0:6e:bf:ab:d5:4e
       capacity: 1Gbit/s
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=r8169 firmware=rtl8168h-2_0.0.2 02/26/15 latency=0 link=no multicast=yes port=MII
       resources: irq:16 ioport:d000(size=256) memory:df304000-df304fff memory:df300000-df303fff
  *-network
       description: Wireless interface
       product: Wireless 8265 / 8275
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:04:00.0
       logical name: wlp4s0
       version: 78
       serial: 00:e1:8c:42:0f:18
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=iwlwifi driverversion=5.4.0-42-generic firmware=36.77d01142.0 ip=192.168.1.4 latency=0 link=yes multicast=yes wireless=IEEE 802.11
       resources: irq:132 memory:df100000-df101fff

lshw
output:

  *-network                 
       description: Ethernet interface
       product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: enp2s0
       version: 15
       serial: b0:6e:bf:ab:d5:4e
       capacity: 1Gbit/s
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=r8169 firmware=rtl8168h-2_0.0.2 02/26/15 latency=0 link=no multicast=yes port=MII
       resources: irq:16 ioport:d000(size=256) memory:df304000-df304fff memory:df300000-df303fff
  *-network UNCLAIMED
       description: Network controller
       product: Wireless 8265 / 8275
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:04:00.0
       version: 78
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress cap_list
       configuration: latency=0
       resources: memory:df100000-df101fff
chqdrian
  • 125

1 Answers1

1

Edit your /etc/netplan/*.yaml... keeping the exact same indentation, spacing, and no tabs...

sudo -H gedit /etc/netplan/*.yaml # use the correct .yaml file name

# Let NetworkManager manage all devices on this system
#
network:
  version: 2
  renderer: NetworkManager

sudo netplan generate

sudo netplan apply

reboot

Then go to the NetworkManager applet at the right side of the top panel and select your wifi network.

Update #1:

  • boot into Windows
  • open the Power control panel
  • choose change what the power buttons do
  • choose change options that are unavailable
  • uncheck fast startup
  • close the Power control panel
  • open an administrative command prompt window
  • type powercfg /h off
  • type chkdsk /f c:
  • approve to run chkdsk at next reboot
  • type chkdsk /f x: (replacing "x" with drive letters of other visible NTFS partitions)
  • reboot into Windows to let chkdsk run on drive C:
heynnema
  • 70,711
  • I updated the .yaml file, and restarted the laptop, I was able to use the wifi in the applet, but when I switch to Windows and switch back to Ubuntu, the wifi option is gone again. – chqdrian Aug 06 '20 at 16:30
  • You did the sudo netplan commands, yes? Boot to the GRUB menu, choose Advanced Options, and boot to the oldest kernel that's showing. You have -42 now. Show me the lshw command again, when the wifi is not working. – heynnema Aug 06 '20 at 18:00
  • I did sudo netplan command, I've added the lshw command output (when the wifi option is not visible) in the question. – chqdrian Aug 06 '20 at 18:33
  • Did you boot to the older kernel? If so, is the wifi showing there? Rather than use the lshw command by itself, please show me sudo lshw -C network again when the wifi is not working. – heynnema Aug 06 '20 at 18:53
  • the system fails to load when I run older kernel (-26), it stops at Starting modem manager ...
    and I've updated the question, with latest ```sudo lshw -C network`` command output for 42 kernel.
    – chqdrian Aug 06 '20 at 19:25
  • @chqdrian Very strange. Show me sudo dmidecode -s bios-version and tell me the exact make/model # of your laptop. – heynnema Aug 06 '20 at 20:10
  • Intel® Core™ i7-7700HQ CPU @ 2.80GHz × 8 GeForce GTX 1050/PCIe/SSE2 / GeForce GTX 1050/P OS type - 64-bit``` – chqdrian Aug 07 '20 at 03:56
  • I installed Ubuntu 20.04 before (without dual booting Windows) few days back, there was no issues. But, for personal reasons, I had to install again Windows(dual boot), that's when I started facing issues. If I used only Ubuntu continuously (without booting Windows), the Wifi is working fine, only when I login into Windows and login into Ubuntu, the wifi issue occurs, it's like it's reverting back to previous state. I've created 4 partitions of my 1TB hard disk, 1 partition for Windows, 1 partition for Ubuntu and 2 common drives – chqdrian Aug 07 '20 at 04:04
  • @chqdrian Your BIOS is current. Please see Update #1 in my answer. Report back. – heynnema Aug 07 '20 at 13:29
  • I followed your instructions, now I'm able to access my wifi, (even after switching to windows.) If I could double upvote your answer, I would. Thanks @heynnema – chqdrian Aug 07 '20 at 14:35
  • @chqdrian Great news! Thanks for the feedback. – heynnema Aug 07 '20 at 14:40