Ubuntu 18.04では、Wi-Fiがランダムに切断されます。

Ubuntu 18.04では、Wi-Fiがランダムに切断されます。

Ubuntu 18.04では、ThinkPad-L440のWi-Fi接続がランダムに切断されます。多くのトラブルシューティングを行い、提案された解決策をたくさん試しましたが、問題は解決しません。

場合によっては、インターネットを閲覧している間に接続を維持しているサイト(Reddit、Google Driveなど)で数秒間オフラインであることが示され、再び正常に戻ることがあります。また、一部のインスタントメッセージングツールも同じ時間オフラインになります。私のルーターIPをpingし、時間を印刷し、pingが失敗したときにビープ音を鳴らす小さなスクリプトを作成しました。実際、短いWi-Fiの再接続を頻繁に検出しました(ほとんどの間隔は60〜90秒でした)。

これまで私が見つけたもの:

  • 問題がハードウェアではなくクライアントにあることを確認してください(ルーターログを確認してください。他のデバイスにはそのような問題はありません)。同じラップトップがWindowsから起動し、正常に動作します。)
  • 保存した接続を削除し、再接続(およびnmcli con delete <SSID>nmcli dev wifi connect <SSID> password <password>を含むさまざまなサービスの再起動、デバイスの再起動などが可能です。
  • クライアントとルーター側を2.4GHzと5GHz帯域に接続することを強制すること(私のAPは同じSSIDを持つデュアルバンドです)は2.4ではあまり発生しないようですが、まだ完全に削除されていません。 5GHzも必要なので、2.4Ghzを使用することは解決策ではありません。
  • 省電力機能の無効化/etc/NetworkManager/conf.d/default-wifi-powersave-on.conf
  • dhcp6.name-servers, dhcp6.domain-search, dhcp6.fqdn, dhcp6.sntp-servers,その行をコメントアウトしてください。/etc/dhcp/dhclient.conf
  • ワイヤレスインターフェイスのIPv6を完全に無効にします。
  • DNS設定を確認してください。
/etc/resolv.conf -> /run/systemd/resolve/stub-resolv.conf:
# This file is managed by man:systemd-resolved(8). Do not edit.
...
nameserver 127.0.0.53
options edns0
search lan
----------------
/etc/systemd/resolved.conf:
#  This file is part of systemd.
[Resolve]
#DNS=
#FallbackDNS=
#Domains=
#LLMNR=no
#MulticastDNS=no
#DNSSEC=no
#Cache=yes
#DNSStubListener=yes
  • ネットワーク管理者の設定を確認してください。
/etc/NetworkManager/NetworkManager.conf:
[main]
plugins=ifupdown,keyfile

[ifupdown]
managed=false

[device]
wifi.scan-rand-mac-address=no
----------------
/etc/NetworkManager/conf.d/default-wifi-powersave-on.conf:
[connection]
wifi.powersave = 2
dmesg:
[ 3205.127410] wlp2s0: Limiting TX power to 17 (20 - 3) dBm as advertised by XX:XX:XX:XX:XX:XX
[ 3284.204536] wlp2s0: deauthenticating from XX:XX:XX:XX:XX:XX by local choice (Reason: 3=DEAUTH_LEAVING)
[ 3286.955049] wlp2s0: authenticate with XX:XX:XX:XX:XX:XX
[ 3286.958967] wlp2s0: send auth to XX:XX:XX:XX:XX:XX (try 1/3)
[ 3286.961583] wlp2s0: authenticated
[ 3286.964357] wlp2s0: associate with XX:XX:XX:XX:XX:XX (try 1/3)
[ 3286.966033] wlp2s0: RX AssocResp from XX:XX:XX:XX:XX:XX (capab=0x111 status=0 aid=2)
[ 3286.967569] wlp2s0: associated
----------------
Network-Manager.service:
Nov 26 10:27:31 ThinkPad-L440 NetworkManager[954]: <debug> [1701012451.6742] platform: signal: link changed: 3: wlp2s0 <UP;broadcast,multicast,up> mtu 1500 arp 1 wifi? init addrgenmode none addr XX:XX:XX:XX:XX:XX driver iwlwifi rx:23080,12307791 tx:21126,3434093
Nov 26 10:27:31 ThinkPad-L440 NetworkManager[954]: <debug> [1701012451.6743] device[0x55a4db33bb30] (wlp2s0): queued link change for ifindex 3
Nov 26 10:27:31 ThinkPad-L440 NetworkManager[954]: <warn>  [1701012451.6746] sup-iface[0x55a4db3be030,wlp2s0]: connection disconnected (reason -3)
...
Nov 26 10:31:57 ThinkPad-L440 NetworkManager[954]: <debug> [1701012717.2698] auth: call[254]: CheckAuthorization succeeded: (is_authorized=1, is_challenge=0)
Nov 26 10:31:57 ThinkPad-L440 NetworkManager[954]: <debug> [1701012717.2698] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scanning requested
Nov 26 10:31:57 ThinkPad-L440 NetworkManager[954]: <debug> [1701012717.2699] device[0x55a4db33bb30] (wlp2s0): wifi-scan: no SSIDs to probe scan
Nov 26 10:31:57 ThinkPad-L440 NetworkManager[954]: <debug> [1701012717.2700] device[0x55a4db33bb30] (wlp2s0): add_pending_action (1): 'wifi-scan'
Nov 26 10:31:57 ThinkPad-L440 NetworkManager[954]: <debug> [1701012717.2700] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scheduled in 120 seconds (interval now 120 seconds)
Nov 26 10:31:57 ThinkPad-L440 NetworkManager[954]: <debug> [1701012717.2761] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scanning-state: scanning
Nov 26 10:32:01 ThinkPad-L440 NetworkManager[954]: <debug> [1701012721.0916] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scanning-state: idle
Nov 26 10:32:01 ThinkPad-L440 NetworkManager[954]: <debug> [1701012721.1181] device[0x55a4db33bb30] (wlp2s0): failed to match hidden AP XX:XX:XX:XX:XX:XX
Nov 26 10:32:01 ThinkPad-L440 NetworkManager[954]: <debug> [1701012721.1427] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scan-done callback: successful
Nov 26 10:32:01 ThinkPad-L440 NetworkManager[954]: <debug> [1701012721.1428] device[0x55a4db33bb30] (wlp2s0): remove_pending_action (0): 'wifi-scan'
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2661] auth: call[255]: CheckAuthorization(org.freedesktop.NetworkManager.network-control), subject=unix-process[pid=6045, uid=1000, start=300653]
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2681] auth: call[255]: CheckAuthorization succeeded: (is_authorized=1, is_challenge=0)
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2682] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scanning requested
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2683] device[0x55a4db33bb30] (wlp2s0): wifi-scan: no SSIDs to probe scan
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2684] device[0x55a4db33bb30] (wlp2s0): add_pending_action (1): 'wifi-scan'
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2684] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scheduled in 120 seconds (interval now 120 seconds)
Nov 26 10:32:15 ThinkPad-L440 NetworkManager[954]: <debug> [1701012735.2748] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scanning-state: scanning
Nov 26 10:32:19 ThinkPad-L440 NetworkManager[954]: <debug> [1701012739.3076] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scanning-state: idle
Nov 26 10:32:19 ThinkPad-L440 NetworkManager[954]: <debug> [1701012739.3508] device[0x55a4db33bb30] (wlp2s0): wifi-scan: scan-done callback: successful
Nov 26 10:32:19 ThinkPad-L440 NetworkManager[954]: <debug> [1701012739.3508] device[0x55a4db33bb30] (wlp2s0): remove_pending_action (0): 'wifi-scan'
Nov 26 10:32:19 ThinkPad-L440 NetworkManager[954]: <debug> [1701012739.3798] ndisc-lndp[0x55a4db399f80,"wlp2s0"]: processing libndp events
  • ログとステータスを確認して、wpa_supplicant.serviceネットワーク管理者を妨げる複数のDHCPクライアントがないことを確認してください。wpa_supplicantd-busを介してネットワーク管理者が起動したデーモンとして実行されます。すべてが大丈夫に見え、ログに警告やエラーはありません。

デバッグのための追加情報:

$ sudo lshw -C network
        description: Wireless interface
        product: Wireless 7260
        vendor: Intel Corporation
        physical id: 0
        bus info: pci@0000:02:00.0
        logical name: wlp2s0
        version: 83
        serial: XX:XX:XX:XX:XX:XX
        width: 64 bits
        clock: 33MHz
        capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
        configuration: broadcast=yes driver=iwlwifi driverversion=4.15.0-213-generic firmware=17.948900127.0 ip=192.168.2.248 latency=0 link=yes multicast=yes wireless=IEEE 802.11
        resources: irq:32 memory:f2400000-f2401fff

$ sudo iwconfig
wlp2s0    IEEE 802.11  ESSID:"XXXXXXXXXX"  
          Mode:Managed  Frequency:5.66 GHz  Access Point: XX:XX:XX:XX:XX:XX   
          Bit Rate=866.7 Mb/s   Tx-Power=17 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality=54/70  Signal level=-56 dBm  
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:8   Missed beacon:0

$ sudo nmcli connection show
connection.id:                          XXXXXXXXXX
connection.uuid:                        31ce91dc-831d-4343-a876-1fd0570bddd4
connection.stable-id:                   --
connection.type:                        802-11-wireless
connection.interface-name:              --
connection.autoconnect:                 yes
connection.autoconnect-priority:        0
connection.autoconnect-retries:         -1 (default)
connection.auth-retries:                -1
connection.timestamp:                   1701017466
connection.read-only:                   no
connection.permissions:                 --
connection.zone:                        --
connection.master:                      --
connection.slave-type:                  --
connection.autoconnect-slaves:          -1 (default)
connection.secondaries:                 --
connection.gateway-ping-timeout:        0
connection.metered:                     unknown
connection.lldp:                        default
connection.mdns:                        -1 (default)
802-11-wireless.ssid:                   XXXXXXXXXX
802-11-wireless.mode:                   infrastructure
802-11-wireless.band:                   --
802-11-wireless.channel:                0
802-11-wireless.bssid:                  --
802-11-wireless.rate:                   0
802-11-wireless.tx-power:               0
802-11-wireless.mac-address:            XX:XX:XX:XX:XX:XX
802-11-wireless.cloned-mac-address:     --
802-11-wireless.generate-mac-address-mask:--
802-11-wireless.mac-address-blacklist:  --
802-11-wireless.mac-address-randomization:default
802-11-wireless.mtu:                    auto
802-11-wireless.seen-bssids:            XX:XX:XX:XX:XX:XX,XX:XX:XX:XX:XX:XX
802-11-wireless.hidden:                 no
802-11-wireless.powersave:              0 (default)
802-11-wireless-security.key-mgmt:      wpa-psk
802-11-wireless-security.wep-tx-keyidx: 0
802-11-wireless-security.auth-alg:      --
802-11-wireless-security.proto:         --
802-11-wireless-security.pairwise:      --
802-11-wireless-security.group:         --
802-11-wireless-security.pmf:           0 (default)
802-11-wireless-security.leap-username: --
802-11-wireless-security.wep-key0:      <hidden>
802-11-wireless-security.wep-key1:      <hidden>
802-11-wireless-security.wep-key2:      <hidden>
802-11-wireless-security.wep-key3:      <hidden>
802-11-wireless-security.wep-key-flags: 0 (none)
802-11-wireless-security.wep-key-type:  unknown
802-11-wireless-security.psk:           <hidden>
802-11-wireless-security.psk-flags:     0 (none)
802-11-wireless-security.leap-password: <hidden>
802-11-wireless-security.leap-password-flags:0 (none)
802-11-wireless-security.wps-method:    0 (default)
ipv4.method:                            auto
ipv4.dns:                               --
ipv4.dns-search:                        --
ipv4.dns-options:                       ""
ipv4.dns-priority:                      0
ipv4.addresses:                         --
ipv4.gateway:                           --
ipv4.routes:                            --
ipv4.route-metric:                      -1
ipv4.route-table:                       0 (unspec)
ipv4.ignore-auto-routes:                no
ipv4.ignore-auto-dns:                   no
ipv4.dhcp-client-id:                    --
ipv4.dhcp-timeout:                      0 (default)
ipv4.dhcp-send-hostname:                yes
ipv4.dhcp-hostname:                     --
ipv4.dhcp-fqdn:                         --
ipv4.never-default:                     no
ipv4.may-fail:                          yes
ipv4.dad-timeout:                       -1 (default)
ipv6.method:                            auto
ipv6.dns:                               --
ipv6.dns-search:                        --
ipv6.dns-options:                       ""
ipv6.dns-priority:                      0
ipv6.addresses:                         --
ipv6.gateway:                           --
ipv6.routes:                            --
ipv6.route-metric:                      -1
ipv6.route-table:                       0 (unspec)
ipv6.ignore-auto-routes:                no
ipv6.ignore-auto-dns:                   no
ipv6.never-default:                     no
ipv6.may-fail:                          yes
ipv6.ip6-privacy:                       0 (disabled)
ipv6.addr-gen-mode:                     stable-privacy
ipv6.dhcp-send-hostname:                yes
ipv6.dhcp-hostname:                     --
ipv6.token:                             --
proxy.method:                           none
proxy.browser-only:                     no
proxy.pac-url:                          --
proxy.pac-script:                       --
GENERAL.NAME:                           XXXXXXXXXX
GENERAL.UUID:                           31ce91dc-831d-4343-a876-1fd0570bddd4
GENERAL.DEVICES:                        wlp2s0
GENERAL.STATE:                          activated
GENERAL.DEFAULT:                        yes
GENERAL.DEFAULT6:                       yes
GENERAL.SPEC-OBJECT:                    /org/freedesktop/NetworkManager/AccessPoint/2
GENERAL.VPN:                            no
GENERAL.DBUS-PATH:                      /org/freedesktop/NetworkManager/ActiveConnection/3
GENERAL.CON-PATH:                       /org/freedesktop/NetworkManager/Settings/6
GENERAL.ZONE:                           --
GENERAL.MASTER-PATH:                    --
IP4.ADDRESS[1]:                         192.168.2.248/24
IP4.GATEWAY:                            192.168.2.1
IP4.ROUTE[1]:                           dst = 192.168.2.0/24, nh = 0.0.0.0, mt = 600
IP4.ROUTE[2]:                           dst = 0.0.0.0/0, nh = 192.168.2.1, mt = 600
IP4.DNS[1]:                             192.168.2.1
IP4.DOMAIN[1]:                          lan
DHCP4.OPTION[1]:                        domain_name = lan
DHCP4.OPTION[2]:                        requested_routers = 1
DHCP4.OPTION[3]:                        requested_netbios_scope = 1
DHCP4.OPTION[4]:                        requested_subnet_mask = 1
DHCP4.OPTION[5]:                        dhcp_server_identifier = 192.168.2.1
DHCP4.OPTION[6]:                        requested_domain_search = 1
DHCP4.OPTION[7]:                        requested_host_name = 1
DHCP4.OPTION[8]:                        subnet_mask = 255.255.255.0
DHCP4.OPTION[9]:                        requested_ntp_servers = 1
DHCP4.OPTION[10]:                       next_server = 192.168.2.1
DHCP4.OPTION[11]:                       network_number = 192.168.2.0
DHCP4.OPTION[12]:                       dhcp_lease_time = 43200
DHCP4.OPTION[13]:                       dhcp_message_type = 5
DHCP4.OPTION[14]:                       requested_domain_name_servers = 1
DHCP4.OPTION[15]:                       requested_netbios_name_servers = 1
DHCP4.OPTION[16]:                       expiry = 1701060666
DHCP4.OPTION[17]:                       requested_time_offset = 1
DHCP4.OPTION[18]:                       requested_broadcast_address = 1
DHCP4.OPTION[19]:                       ip_address = 192.168.2.248
DHCP4.OPTION[20]:                       domain_name_servers = 192.168.2.1
DHCP4.OPTION[21]:                       broadcast_address = 192.168.2.255
DHCP4.OPTION[22]:                       requested_domain_name = 1
DHCP4.OPTION[23]:                       requested_ms_classless_static_routes = 1
DHCP4.OPTION[24]:                       dhcp_rebinding_time = 37800
DHCP4.OPTION[25]:                       requested_static_routes = 1
DHCP4.OPTION[26]:                       host_name = ThinkPad-L440
DHCP4.OPTION[27]:                       dhcp_renewal_time = 21600
DHCP4.OPTION[28]:                       requested_wpad = 1
DHCP4.OPTION[29]:                       requested_interface_mtu = 1
DHCP4.OPTION[30]:                       requested_rfc3442_classless_static_routes = 1
DHCP4.OPTION[31]:                       routers = 192.168.2.1
IP6.ADDRESS[1]:                         2606:6d00:17:1796:b8a6:2ecd:8a68:6eab/64
IP6.ADDRESS[2]:                         fd03:bb95:6ff8:0:88e5:422f:3bbe:7a9f/64
IP6.ADDRESS[3]:                         2606:6d00:17:1796::1c0/128
IP6.ADDRESS[4]:                         fd03:bb95:6ff8::1c0/128
IP6.ADDRESS[5]:                         fe80::75e0:860c:9167:4558/64
IP6.GATEWAY:                            fe80::52d2:f5ff:fe09:3b20
IP6.ROUTE[1]:                           dst = ff00::/8, nh = ::, mt = 256, table=255
IP6.ROUTE[2]:                           dst = fe80::/64, nh = ::, mt = 256
IP6.ROUTE[3]:                           dst = fe80::/64, nh = ::, mt = 600
IP6.ROUTE[4]:                           dst = 2606:6d00:17:1796::1c0/128, nh = ::, mt = 600
IP6.ROUTE[5]:                           dst = fd03:bb95:6ff8::1c0/128, nh = ::, mt = 600
IP6.ROUTE[6]:                           dst = fd03:bb95:6ff8::/48, nh = fe80::52d2:f5ff:fe09:3b20, mt = 600
IP6.ROUTE[7]:                           dst = fd03:bb95:6ff8::/64, nh = ::, mt = 600
IP6.ROUTE[8]:                           dst = 2606:6d00:17:1796::/64, nh = ::, mt = 600
IP6.ROUTE[9]:                           dst = ::/0, nh = fe80::52d2:f5ff:fe09:3b20, mt = 600
IP6.DNS[1]:                             fd03:bb95:6ff8::1
DHCP6.OPTION[1]:                        dhcp6_name_servers = fd03:bb95:6ff8::1
DHCP6.OPTION[2]:                        ip6_address = 2606:6d00:17:1796::1c0
DHCP6.OPTION[3]:                        dhcp6_client_id = 0:4:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:98:ac:fa:f3
DHCP6.OPTION[4]:                        life_starts = 1701008951
DHCP6.OPTION[5]:                        rebind = 34560
DHCP6.OPTION[6]:                        starts = 1701008951
DHCP6.OPTION[7]:                        dhcp6_server_id = 0:3:0:1:50:d2:f5:9:3b:20
DHCP6.OPTION[8]:                        dhcp6_solmax_rt = 60
DHCP6.OPTION[9]:                        requested_dhcp6_client_id = 1
DHCP6.OPTION[10]:                       requested_dhcp6_name_servers = 1
DHCP6.OPTION[11]:                       max_life = 43200
DHCP6.OPTION[12]:                       requested_dhcp6_domain_search = 1
DHCP6.OPTION[13]:                       ip6_prefixlen = 64
DHCP6.OPTION[14]:                       renew = 21600
DHCP6.OPTION[15]:                       iaid = 4f:9e:d3:6f
DHCP6.OPTION[16]:                       preferred_life = 43200

$ sudo modinfo iwlwifi- 出力がオンになっている。ペーストビン

今アイデアがなくなりました。私は私が考えたものとGoogleで見つけることができるものをすべてチェックしてみました。私が見ることができる唯一のオプションは、Linuxカーネルお​​よび/またはワイヤレスドライバの一種のバグです。しかし、確認を受けるまでこの問題を台無しにしたくありません。

問題を解決するのに役立ちます。

関連情報