I recently upgraded to ubuntu 19.04 from LTS 18.04, and unable to connect to home wifi.
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 19.04
Release: 19.04
Codename: discoI am using intel Wireless 7260:
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ sudo lshw -class network
[sudo] password for swarna: *-network description: Ethernet interface product: RTL810xE PCI Express Fast Ethernet controller vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:01:00.0 logical name: enp1s0 version: 08 serial: 08:9e:01:ec:56:91 size: 10Mbit/s capacity: 100Mbit/s width: 64 bits clock: 33MHz capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=r8169 duplex=half firmware=rtl8106e-2_0.0.1 04/23/13 latency=0 link=no multicast=yes port=MII speed=10Mbit/s resources: irq:16 ioport:3000(size=256) memory:b0504000-b0504fff memory:b0500000-b0503fff *-network description: Wireless interface product: Wireless 7260 vendor: Intel Corporation physical id: 0 bus info: pci@0000:02:00.0 logical name: wlp2s0 version: 73 serial: 0c:8b:fd:6f:5b:a8 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless configuration: broadcast=yes driver=iwlwifi driverversion=5.0.0-21-generic firmware=17.3216344376.0 ip=192.168.225.78 latency=0 link=yes multicast=yes wireless=IEEE 802.11 resources: irq:46 memory:b0400000-b0401fffI felt that the problem is due to crda, due to the error Process '/sbin/crda' failed with exit code 255. in the log, and added IND to the REGDOMAIN:
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ cat /etc/default/crda
# Set REGDOMAIN to a ISO/IEC 3166-1 alpha2 country code so that iw(8) may set
# the initial regulatory domain setting for IEEE 802.11 devices which operate
# on this system.
#
# Governments assert the right to regulate usage of radio spectrum within
# their respective territories so make sure you select a ISO/IEC 3166-1 alpha2
# country code suitable for your location or you may infringe on local
# legislature. See `/usr/share/zoneinfo/zone.tab' for a table of timezone
# descriptions containing ISO/IEC 3166-1 alpha2 country codes.
REGDOMAIN=INDand rebooted the system. But still got:
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ crda
COUNTRY environment variable not set.Also I changed setregdomain to also have IND as REGDOMAIN
swarna@swarna-Lenovo-Ideapad-Flex-15:/lib/crda$ cat setregdomain
#!/bin/sh
set -e
REGDOMAIN=IND
CRDA_CONF=/etc/default/crda
[ -r "$CRDA_CONF" ] && . "$CRDA_CONF"
[ -z "$REGDOMAIN" ] && exit 0
exec /sbin/iw reg set "$REGDOMAIN"and did a reboot.
Still the same -
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ crda
COUNTRY environment variable not set.I have also tried the following(after going through various suggestions available on internet), but nothing worked:
sudo service network-manager restart; reboot
sudo modprobe iwlwifi 11n_disable=1; reboot
sudo rmmod iwlmvm iwlwifi; reboot I am able to connect to other wi-fis with nothing changed at all. I have dual boot on my system, and windows connects fine with my home wifi.
Also, I am not sure if the crda problem is just a red herring and there is something else that needs to be fixed.
I am unable to proceed after this. Can someone please advise as to what I might be doing wrong and help me fix the problem? Kindly let me know if any other info is required to be attached.
Post the answer, here are the logs:
I have modified /etc/default/crda to hold REGDOMAIN=IN as suggested:
swarna@swarna-Lenovo-Ideapad-Flex-15:/var/log$ cat /etc/default/crda
# Set REGDOMAIN to a ISO/IEC 3166-1 alpha2 country code so that iw(8) may set
# the initial regulatory domain setting for IEEE 802.11 devices which operate
# on this system.
#
# Governments assert the right to regulate usage of radio spectrum within
# their respective territories so make sure you select a ISO/IEC 3166-1 alpha2
# country code suitable for your location or you may infringe on local
# legislature. See `/usr/share/zoneinfo/zone.tab' for a table of timezone
# descriptions containing ISO/IEC 3166-1 alpha2 country codes.
REGDOMAIN=INI have also removed my changes from /lib/crda/setregdomain:
#!/bin/sh
set -e
REGDOMAIN=
CRDA_CONF=/etc/default/crda
[ -r "$CRDA_CONF" ] && . "$CRDA_CONF"
[ -z "$REGDOMAIN" ] && exit 0
exec /sbin/iw reg set "$REGDOMAIN"Now I get
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ iw reg get
global
country IN: DFS-UNSET (2402 - 2482 @ 40), (N/A, 20), (N/A) (5150 - 5350 @ 160), (N/A, 23), (N/A) (5725 - 5875 @ 80), (N/A, 23), (N/A)but:
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ crda
COUNTRY environment variable not set.Also I tried connecting to another wifi, I did not see the crda error in that case, and the connection was successful.
swarna@swarna-Lenovo-Ideapad-Flex-15:~$ nmcli device wifi list
IN-USE SSID MODE CHAN RATE SIGNAL BARS SECURITY
* Lakme Infra 1 270 Mbit/s 87 ▂▄▆█ WPA1 WPA2 JioFi4_0413B0 Infra 6 65 Mbit/s 52 ▂▄__ WPA2 IvanDominic Infra 3 135 Mbit/s 19 ▂___ WPA1 WPA2 Abhi2316@kbroadband Infra 1 270 Mbit/s 9 ▂___ WPA2 1 Answer
While I suspect that crda is not the entire problem, I suggest that we address it first and check the log for any improvement.
The file you reference above says, in part:
Set REGDOMAIN to a ISO/IEC 3166-1 alpha2 country code
If you search for ISO/IEC 3166-1 alpha2, one of the very first hits is: We see that country codes ar all two letters, not three letters. I suspect that you want IN.
Of course, substitute your country code if not India. Set it permanently:
sudo nano /etc/default/crdaChange the last line to read:
REGDOMAIN=INProofread carefully, save (Ctrl+o followed by Enter) and close (Ctrl+x) the text editor. Reboot.
Is there any improvement? Please post the log messages as above if not.
EDIT: First, check the settings in the router. WPA2-AES is preferred; not any WPA and WPA2 mixed mode and certainly not TKIP. Second, if your router is capable of N speeds, you may have better connectivity with a channel width of 20 MHz in the 2.4 GHz band instead of automatic 20/40 MHz, although it is likely to affect N speeds. I recommend a fixed channel, either 1, 6 or 11, rather than automatic channel selection. Also, be certain the router is not set to use N speeds only; auto B, G and N is preferred. After making these changes, reboot the router.
If these changes do not help, please try:
sudo modprobe -r iwlwifi
sudo modprobe iwlwifi 11n_disable=8If it helps, make it permanent:
sudo -i
echo "options iwlwifi 11n_disable=8" >> /etc/modprobe.d/iwlwifi.conf
exit 10