Loading...
X

Linux does not see Wi-Fi on Realtek chipset. “firmware: failed to load rt2870.bin” error (SOLVED)

When connecting a Wi-Fi adapter with a Realtek chipset, nothing happens, or the device does not work properly.

Command

iw dev

outputs the following information:

phy#0
        Interface wlan0
                ifindex 3
                wdev 0x1
                addr 52:e7:b0:49:a2:84
                type managed
                txpower 0.00 dBm

The txpower value is zero, the system does not see the Wi-Fi device.

Run command

journalctl -f

and connect the Wi-Fi adapter to your computer

Jan 27 06:09:24 HackWare-Kali kernel: usb 1-1: reset high-speed USB device number 2 using ehci-pci
Jan 27 06:09:25 HackWare-Kali kernel: ieee80211 phy0: rt2x00_set_rt: Info - RT chipset 3572, rev 0223 detected
Jan 27 06:09:25 HackWare-Kali kernel: ieee80211 phy0: rt2x00_set_rf: Info - RF chipset 0009 detected
Jan 27 06:09:25 HackWare-Kali kernel: ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
Jan 27 06:09:25 HackWare-Kali NetworkManager[612]:   [1643281765.9900] device (wlan0): driver supports Access Point (AP) mode
Jan 27 06:09:25 HackWare-Kali systemd[1]: Starting Load/Save RF Kill Switch Status...
Jan 27 06:09:25 HackWare-Kali NetworkManager[612]:   [1643281765.9949] manager: (wlan0): new 802.11 Wi-Fi device (/org/freedesktop/NetworkManager/Devices/3)
Jan 27 06:09:25 HackWare-Kali kernel: usbcore: registered new interface driver rt2800usb
Jan 27 06:09:26 HackWare-Kali systemd-udevd[1328]: Using default interface naming scheme 'v250'.
Jan 27 06:09:26 HackWare-Kali NetworkManager[612]:   [1643281766.0124] rfkill0: found Wi-Fi radio killswitch (at /sys/devices/pci0000:00/0000:00:0b.0/usb1/1-1/1-1:1.0/ieee80211/phy0/rfkill0) (driver rt2800usb)
Jan 27 06:09:26 HackWare-Kali systemd[1]: Started Load/Save RF Kill Switch Status.
Jan 27 06:09:26 HackWare-Kali NetworkManager[612]:   [1643281766.0298] device (wlan0): state change: unmanaged -> unavailable (reason 'managed', sys-iface-state: 'external')
Jan 27 06:09:26 HackWare-Kali kernel: ieee80211 phy0: rt2x00lib_request_firmware: Info - Loading firmware file 'rt2870.bin'
Jan 27 06:09:26 HackWare-Kali kernel: rt2800usb 1-1:1.0: firmware: failed to load rt2870.bin (-2)
Jan 27 06:09:26 HackWare-Kali kernel: firmware_class: See https://wiki.debian.org/Firmware for information about missing firmware
Jan 27 06:09:26 HackWare-Kali kernel: rt2800usb 1-1:1.0: Direct firmware load for rt2870.bin failed with error -2
Jan 27 06:09:26 HackWare-Kali kernel: ieee80211 phy0: rt2x00lib_request_firmware: Info - Loading firmware file 'rt2870.bin'
Jan 27 06:09:26 HackWare-Kali kernel: rt2800usb 1-1:1.0: firmware: failed to load rt2870.bin (-2)
Jan 27 06:09:26 HackWare-Kali kernel: rt2800usb 1-1:1.0: Direct firmware load for rt2870.bin failed with error -2
Jan 27 06:09:26 HackWare-Kali NetworkManager[612]:   [1643281766.0307] device (wlan0): firmware may be missing.
Jan 27 06:09:26 HackWare-Kali NetworkManager[612]:   [1643281766.0310] device (wlan0): set-hw-addr: set MAC address to 52:E7:B0:49:A2:84 (scanning)
Jan 27 06:09:26 HackWare-Kali dbus-daemon[611]: [system] Activating via systemd: service name='org.freedesktop.Avahi' unit='dbus-org.freedesktop.Avahi.service' requested by ':1.72' (uid=119 pid=1345 comm="/usr/libexec/colord-sane ")
Jan 27 06:09:26 HackWare-Kali dbus-daemon[611]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.Avahi.service': Unit dbus-org.freedesktop.Avahi.service not found.
Jan 27 06:09:28 HackWare-Kali ModemManager[639]:   [base-manager] couldn't check support for device '/sys/devices/pci0000:00/0000:00:0b.0/usb1/1-1': not supported by any plugin
Jan 27 06:09:31 HackWare-Kali systemd[1]: systemd-rfkill.service: Deactivated successfully.
Jan 27 06:09:33 HackWare-Kali systemd[1]: blueman-mechanism.service: Deactivated successfully.

In the output, the key line is “firmware: failed to load rt2870.bin”, that is, it was not possible to load the firmware rt2870.bin.

In Kali Linux, the rt2870.bin firmware is placed in the firmware-misc-nonfree package, install it:

sudo apt install firmware-misc-nonfree

On Ubuntu, Linux Mint and their derivatives, run the following command:

sudo apt install linux-firmware

On Debian, run:

sudo apt install firmware-misc-nonfree

On Arch Linux, Manjaro, BlackArch and their derivatives, run the command:

sudo pacman -S linux-firmware

After installing the firmware and restarting the computer, the problem will disappear and the Wi-Fi adapter will work.

Note that Debian and derivatives have a firmware-realtek package which also contains Realtek firmware. In addition to these two packages, various distributions contain Realtek drivers and firmware in separate packages – to determine exactly which package you need, search your distribution's package repository for the name of the Wi-Fi adapter, as well as the name of the driver and firmware file that may appear in the error message.

See also the section “Drivers and firmware”.


Leave Your Observation

Your email address will not be published. Required fields are marked *