Debian 12 (22-2024) does not recognize your Ethernet or Wi-Fi, on asus
If Debian 12 (22-2024) does not recognize your Ethernet or Wi-Fi, for ASUS PRIME H510M-K R2.0 motherboard, due to missing non-free firmware or drivers. Here’s how to fix it:
1. Identify Your Network Hardware
Boot into Debian and run:
lspci -nn | grep -i -E 'network|ethernet'
OR
ip link show
This will show the network adapters.
2. Load Missing Non-Free Firmware
Debian does not include proprietary drivers by default. You need to install them.
Enable Non-Free Repositories
- Open a terminal and run:
sudo nano /etc/apt/sources.list
- Add contrib non-free non-free-firmware to the repository lines:
deb http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware
deb http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware
deb http://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware
Save and exit (
Ctrl + X
,Y
,Enter
).Update and install firmware:
sudo apt update && sudo apt install firmware-linux firmware-misc-nonfree firmware-iwlwifi firmware-realtek -y
3. Load the New Firmware
Restart your system:
sudo reboot
Check if Ethernet and Wi-Fi work:
ip a
4. If Ethernet Still Doesn't Work
Try manually loading the module:
sudo modprobe r8169
If your Ethernet controller is Realtek, install drivers:
sudo apt install r8168-dkms
sudo modprobe -r r8169 && sudo modprobe r8168
5. If Wi-Fi Still Doesn’t Work
- Load the driver:
sudo modprobe iwlwifi
- Check Wi-Fi networks:
nmcli dev wifi list
- If
nmcli
is missing, install NetworkManager:
sudo apt install network-manager -y
Then restart:
sudo systemctl restart NetworkManager
6. Final Steps
If you still don’t see Wi-Fi, check logs:
dmesg | grep iwlwifi
If needed, reinstall kernel modules:
sudo apt install linux-headers-$(uname -r) -y