6

The wifi connection I use on my laptop keeps disconnecting randomly and it happens many times during a day. First, wifi signal starts to flash then it asks for wifi password even though it's been already saved. I need to turn off wireless network, turn it back on and connect to the wireless network back again to reconnect.

My network adapter is:

02:00.0 Network controller: Intel Corporation Wireless 3160 (rev cb)

I don't think if it is a hardware related issue as it wasn't happening when I was using Windows and it's also not a router issue as other devices connecting to the network are ok.

I have Ubuntu 20.04.4 LTS installed and there is no additional drivers available. Is there any solution you can offer to me?

iwlwifi commands are here: https://pastebin.ubuntu.com/p/tjwzKRXZ6F/

$ uname -a
Linux SATELLITE-Radius-14-L40W-C-102 5.13.0-37-generic #42~20.04.1-Ubuntu SMP Tue Mar 15 15:44:28 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
$ sudo lshw -class network
*-network                 
       description: Wireless interface
       product: Wireless 3160
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: wlp2s0
       version: cb
       serial: b4:6d:83:ff:02:8f
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=iwlwifi driverversion=5.13.0-37-generic firmware=17.3216344376.0 3160-17.ucode ip=192.168.1.242 latency=0 link=yes multicast=yes wireless=IEEE 802.11
       resources: irq:49 memory:b1100000-b1101fff

$ lspci -knn | grep Net -A2 02:00.0 Network controller [0280]: Intel Corporation Wireless 3160 [8086:08b3] (rev cb) Subsystem: Intel Corporation Dual Band Wireless AC 3160 [8086:8170] Kernel driver in use: iwlwifi

$ls -al /etc/pm/config.d/ ls: cannot access '/etc/pm/config.d/': No such file or directory $ ls -al /etc/modprobe.d/ total 56 drwxr-xr-x 2 root root 4096 Şub 7 12:50 . drwxr-xr-x 130 root root 12288 Mar 23 12:34 .. -rw-r--r-- 1 root root 2507 Tem 31 2015 alsa-base.conf -rw-r--r-- 1 root root 154 Şub 16 2020 amd64-microcode-blacklist.conf -rw-r--r-- 1 root root 325 Mar 12 2020 blacklist-ath_pci.conf -rw-r--r-- 1 root root 1518 Mar 12 2020 blacklist.conf -rw-r--r-- 1 root root 210 Mar 12 2020 blacklist-firewire.conf -rw-r--r-- 1 root root 677 Mar 12 2020 blacklist-framebuffer.conf -rw-r--r-- 1 root root 156 Tem 31 2015 blacklist-modem.conf lrwxrwxrwx 1 root root 41 Şub 7 12:28 blacklist-oss.conf -> /lib/linux-sound-base/noOSS.modprobe.conf -rw-r--r-- 1 root root 583 Mar 12 2020 blacklist-rare-network.conf -rw-r--r-- 1 root root 154 Haz 10 2020 intel-microcode-blacklist.conf -rw-r--r-- 1 root root 347 Mar 12 2020 iwlwifi.conf $ sudo iwlist freq lo no frequency information.

wlp2s0 32 channels in total; available frequencies : Channel 01 : 2.412 GHz Channel 02 : 2.417 GHz Channel 03 : 2.422 GHz Channel 04 : 2.427 GHz Channel 05 : 2.432 GHz Channel 06 : 2.437 GHz Channel 07 : 2.442 GHz Channel 08 : 2.447 GHz Channel 09 : 2.452 GHz Channel 10 : 2.457 GHz Channel 11 : 2.462 GHz Channel 12 : 2.467 GHz Channel 13 : 2.472 GHz Channel 36 : 5.18 GHz Channel 40 : 5.2 GHz Channel 44 : 5.22 GHz Channel 48 : 5.24 GHz Channel 52 : 5.26 GHz Channel 56 : 5.28 GHz Channel 60 : 5.3 GHz Channel 64 : 5.32 GHz Channel 100 : 5.5 GHz Channel 104 : 5.52 GHz Channel 108 : 5.54 GHz Channel 112 : 5.56 GHz Channel 116 : 5.58 GHz Channel 120 : 5.6 GHz Channel 124 : 5.62 GHz Channel 128 : 5.64 GHz Channel 132 : 5.66 GHz Channel 136 : 5.68 GHz Channel 140 : 5.7 GHz Current Frequency:2.462 GHz (Channel 11)

$ iwlist scan | egrep -i 'ssid|quality' lo Interface doesn't support scanning.

                Quality=70/70  Signal level=-36 dBm  
                ESSID:"ardic"

$ sudo iwconfig lo no wireless extensions.

wlp2s0 IEEE 802.11 ESSID:"ardic"
Mode:Managed Frequency:2.462 GHz Access Point: 60:31:97:F0:0D:4D
Bit Rate=72.2 Mb/s Tx-Power=20 dBm
Retry short limit:7 RTS thr:off Fragment thr:off Encryption key:off Power Management:off Link Quality=57/70 Signal level=-53 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0 Tx excessive retries:0 Invalid misc:137 Missed beacon:0

$ inxi -Fxz System: Kernel: 5.13.0-37-generic x86_64 bits: 64 compiler: N/A Desktop: Gnome 3.36.9 Distro: Ubuntu 20.04.4 LTS (Focal Fossa) Machine: Type: Laptop System: TOSHIBA product: SATELLITE Radius 14 L40W-C-102 v: PSLZAE-00R00STE serial: <filter> Mobo: FF40 model: 06A0 v: 2.0 serial: <filter> UEFI: INSYDE v: 5.00 date: 07/01/2015 Battery: ID-1: BAT0 charge: 13.1 Wh condition: 22.7/46.3 Wh (49%) model: TKBSS G71C000JV110 status: Discharging CPU: Topology: Dual Core model: Intel Core i3-5005U bits: 64 type: MT MCP arch: Broadwell rev: 4 L2 cache: 3072 KiB flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx bogomips: 15999 Speed: 883 MHz min/max: 500/1900 MHz Core speeds (MHz): 1: 1026 2: 969 3: 800 4: 927 Graphics: Device-1: Intel HD Graphics 5500 vendor: Toshiba driver: i915 v: kernel bus ID: 00:02.0 Display: x11 server: X.Org 1.20.13 driver: i915 resolution: 1366x768~60Hz OpenGL: renderer: Mesa Intel HD Graphics 5500 (BDW GT2) v: 4.6 Mesa 21.2.6 direct render: Yes Audio: Device-1: Intel Broadwell-U Audio vendor: Toshiba driver: snd_hda_intel v: kernel bus ID: 00:03.0 Device-2: Intel Wildcat Point-LP High Definition Audio vendor: Toshiba driver: snd_hda_intel v: kernel bus ID: 00:1b.0 Sound Server: ALSA v: k5.13.0-37-generic Network: Device-1: Intel Wireless 3160 driver: iwlwifi v: kernel port: 3040 bus ID: 02:00.0 IF: wlp2s0 state: up mac: <filter> Drives: Local Storage: total: 111.79 GiB used: 14.19 GiB (12.7%) ID-1: /dev/sda vendor: Gigabyte model: GP-GSTFS31120GNTD size: 111.79 GiB temp: 33 C Partition: ID-1: / size: 109.04 GiB used: 14.18 GiB (13.0%) fs: ext4 dev: /dev/sda2 Sensors: System Temperatures: cpu: 54.0 C mobo: 27.8 C Fan Speeds (RPM): N/A Info: Processes: 235 Uptime: 7h 36m Memory: 7.68 GiB used: 2.14 GiB (27.9%) Init: systemd runlevel: 5 Compilers: gcc: N/A Shell: bash v: 5.0.17 inxi: 3.0.38

$ nmcli device wifi list IN-USE BSSID SSID MODE CHAN RATE >

  •   60:31:97:F0:0D:4D  ardic                      Infra  11    130 Mbit/s  &gt;
      00:31:92:66:37:60  TurkTelekom_TP3760_2.4GHz  Infra  8     270 Mbit/s  &gt;
      00:31:92:66:37:61  TurkTelekom_TP3760_5GHz    Infra  36    270 Mbit/s  &gt;
      74:DA:88:22:03:20  TP-Link_0320               Infra  2     130 Mbit/s  &gt;
      8C:DE:F9:0E:2B:48  TP-Link_0320_plus          Infra  2     130 Mbit/s  &gt;
      8C:15:C7:E9:98:24  VodafoneNet-D7VDST         Infra  11    270 Mbit/s  &gt;
    
    

    $ lsusb

Bus 001 Device 002: ID 8087:8001 Intel Corp. Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 002 Device 004: ID 04f2:b446 Chicony Electronics Co., Ltd TOSHIBA Web Camera - HD Bus 002 Device 003: ID 04f3:20d3 Elan Microelectronics Corp. Touchscreen Bus 002 Device 002: ID 048d:8350 Integrated Technology Express, Inc. ITE Device(8350) Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

$ systemctl status bluetooth ● bluetooth.service - Bluetooth service Loaded: loaded (/lib/systemd/system/bluetooth.service; enabled; vendor pre> Active: active (running) since Tue 2022-03-29 10:17:38 +03; 9min ago Docs: man:bluetoothd(8) Main PID: 920 (bluetoothd) Status: "Running" Tasks: 1 (limit: 9356) Memory: 1.5M CGroup: /system.slice/bluetooth.service └─920 /usr/lib/bluetooth/bluetoothd

Mar 29 10:17:38 SATELLITE-Radius-14-L40W-C-102 systemd[1]: Starting Bluetooth s> Mar 29 10:17:38 SATELLITE-Radius-14-L40W-C-102 bluetoothd[920]: Bluetooth daemo> Mar 29 10:17:38 SATELLITE-Radius-14-L40W-C-102 systemd[1]: Started Bluetooth se> Mar 29 10:17:38 SATELLITE-Radius-14-L40W-C-102 bluetoothd[920]: Starting SDP se> Mar 29 10:17:38 SATELLITE-Radius-14-L40W-C-102 bluetoothd[920]: Bluetooth manag>

6 Answers6

3

Maybe power management issue ? change wifi.powersave value to 2

sudo nano /etc/NetworkManager/conf.d/default-wifi-powersave-on.conf
#edit this line change from whatever to 2
wifi.powersave=2 

If this does not work try passing this parameter in grub

sudo nano /etc/default/grub

Edit the following line and add pcie_aspm=off

GRUB_CMDLINE_LINUX_DEFAULT="splash pcie_aspm=off"

sudo update-grub

  • wifi.powersave value was already "2". For your other suggestion, I don't want to disable all pcie power saving capabilities to fix this issue. – Andrew Harlan Mar 28 '22 at 15:14
3

EDIT:

As per you pastebin, your current driver configuration includes:

bt_coex_active=enable
power_save=enable
power_level=1

so I would say it is worth trying option 1 below.


As per specifications, your Intel® Dual Band Wireless-AC 3160 has WiFi bands 2.4GHz, 5GHz, and Bluetooth Version 4.0. It is quite frequent to see interference between WiFi and Bluetooth in integrated adapters. A solution would have varied difficulty, depending on the configuration options of the driver.

I am listing below a few answers I have posted on this. There you could find useful links. As for your particular case, more info is needed to narrow down the options. On one hand, I will provide a list of commands to get related info from your system. OTOH, I will provide a list of options you could try, assuming you have driver iwlwifi (also this).

Info to post

Please post the following info

  1. Output of commands below. Please copy-paste verbatim, in your terminal, the commands listed. Then copy-paste verbatim, here, both the commands entered and the output obtained. Also add any behaviour you may observe that is worth noting. Enter your results as properly markdown-formatted text, not as screenshots. If needed for very long output, you could use pastebin.

     $ uname -a
     $ sudo lshw -class network
     $ lspci -knn | grep Net -A2
     $ ls -al /etc/pm/config.d/
     $ ls -al /etc/modprobe.d/
     $ sudo iwlist freq
     $ iwlist scan | egrep -i 'ssid|quality'
     $ sudo iwconfig
     $ inxi -Fxz
     $ nmcli device wifi list
     $ lsusb
     $ systemctl status bluetooth
     $ hcitool dev
     $ hciconfig -a
    

    $ modinfo iwlwifi $ sudo lsmod | grep iwlwifi $ cat /etc/modprobe.d/iwlwifi.conf $ grep [[:alnum:]] /sys/module/iwlwifi/parameters/*

    The last series of commands assume you have driver iwlwifi. Replace it with whatever driver you have.

  2. Brand/model of your computer

Things to try

Post the resulting behavior / output. Assuming you have driver iwlwifi, try:

  1. Using driver options (parms): sudo tee /etc/modprobe.d/iwlwifi-opt.conf <<< "options iwlwifi bt_coex_active=N power_save=0 power_level=5". If that doesn't work, you could add 11n_disable=1, disable_11ac=1, disable_11ax=1. Reboot. Note that, from documentation, it is not clear if the highest number (5) gives the maximum power or the maximum power saving, so you could also try the other end (power_level=1). To check the power level, using the PC on battery and running powertop may help.
  2. Disabling bluetooth. You can do this via CLI with systemctl stop bluetooth, via GUI with Settings -> Bluetooth -> Move the slider at the top right, or perhaps via BIOS configuration. Reboot.
  3. Disabling the 5GHz band in the router.
  4. If the problem happens for a specific network, this may be your solution, but check the Details tab instead. I know it happens without your Ubuntu going to sleep, but it still might apply. And it may be the solution even if it happens more widely, although it is less likely in this case.
  5. Change the channel with iw wlp2s0 set channel <no.>.

Some related answers

  1. Bluetooth Adapter slowing Wifi Connection on Ubuntu 18.04.1
  2. Wifi slows down when Bluetooth headset is connected in Ubuntu 20.04
  3. Wifi and Bluetooth not working simultaneously
  4. Killer Wi-Fi 6 AX1650i WiFi Slow Connections on 5.11 Kernel
  5. Errors in make defconfig-ath10k .. Slow wifi with qualcomm Atheros QCA9377
  6. Atheros bluetooth receiver drops out periodically, Dell Inspiron 15
  7. Bluetooth not working in Ubuntu on HP Laptop - 15-di2000tu
  • First of all I don't use bluetooth and it's off by default. 5Ghz band is not available on my router. – Andrew Harlan Mar 28 '22 at 14:34
  • @AndrewHarlan - 1) Please report results for the 3 commands added below lsusb. 2) Please also try item #1. It doesn't hurt, even if it may not be the solution. 3) Does the problem happen when connecting to other routers as well? 4) Do you need to enter the password when you turn off and on wifi? – sancho.s ReinstateMonicaCellio Mar 29 '22 at 01:38
  • I've added bluetooth status command. hcitool and hciconfig commands do not return anything.
  • I'll try item #1 and inform.
  • I have only one router.
  • No, I don't.
  • – Andrew Harlan Mar 29 '22 at 07:31
  • @AndrewHarlan - Did you have a chance of trying #1? I also added #5. – sancho.s ReinstateMonicaCellio Mar 30 '22 at 14:21
  • "iw wlp2s0 set channel <no.>" Which channel do you think I should use? – Andrew Harlan Mar 30 '22 at 20:14
  • @AndrewHarlan - You said your router only has 2.4GHz. So try anything between 1 and 13 (as per your output). You are currently using #11. Make sure the router is set accordingly. – sancho.s ReinstateMonicaCellio Mar 31 '22 at 05:53