I went through enormous pain to figure this out, thought to share with anyone who could one day fin this useful.
Debian 13's default kernel driver (r8169) fails to recognize certain RTL8125 chip revisions found in GMKtec mini PCs. Ethernet interface never appears in ip link show, even though the hardware is present and functional. Fix: compile and install Realtek's out-of-tree r8125 driver via DKMS.
ip link showlists onlyloandwlp1s0(wifi). Noenp*oreno*interface.lspci | grep -i ethernetconfirms hardware is present:02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8125 2.5GbE Controller (rev 0c)dmesg | grep -i r8169shows:r8169 0000:02:00.0: error -ENODEV: unknown chip XID 689, contact r8169 maintainers (see MAINTAINERS file)firmware-realtekpackage is already installed and up to date. Does not resolve the issue, since this is a driver gap, not a firmware gap.
The in-kernel r8169 driver does not have a matching profile for this chip revision (XID 689). Realtek maintains a separate out-of-tree driver, r8125, that supports newer RTL8125 silicon ahead of mainline kernel support.
apt install linux-headers-$(uname -r) build-essential dkms gitcd /usr/src
git clone https://github.com/awesometic/realtek-r8125-dkms.gitcd realtek-r8125-dkms
dkms add .Note the version DKMS assigns from the confirmation message, for example:
Creating symlink /var/lib/dkms/realtek-r8125/9.016.01/source -> /usr/src/realtek-r8125-dkms
DKMS expects the source folder to be named /usr/src/<package>-<version> (e.g. /usr/src/r8125-9.016.01), matching dkms.conf. The cloned repo folder is named realtek-r8125-dkms instead, which causes dkms build to fail with:
Error! Could not find module source directory.
Directory: /usr/src/r8125-9.016.01 does not exist.
Fix with a symlink:
ln -s /usr/src/realtek-r8125-dkms /usr/src/r8125-9.016.01Substitute the version number DKMS reported in step 3.
dkms build r8125/9.016.01
dkms install r8125/9.016.01modprobe r8125
lsmod | grep r8125
ip link showExpected result: an eno* or enp* interface appears with state UP.
DKMS generates a self-signed MOK (Machine Owner Key) certificate during install to sign the module. If Secure Boot is enabled, you may see a MOK enrollment prompt on next reboot. Enroll it (set a temporary password when prompted) or the module will fail to load on subsequent boots despite working in the current session.
- Hardware: GMKtec mini PC, RTL8125 2.5GbE onboard NIC
- OS: Debian 13 (Trixie)
- Kernel: 6.12.95+deb13-amd64
- Driver source: awesometic/realtek-r8125-dkms, version 9.016.01
Thank you @viztastic for this great guide. I worked for me with an identical setup. However when I upgraded the kernel to 6.12.96 for some reason my mini PC acted like the "start" of this guide — ethernet not present in ip link, etc. I fumbled around with some steps, including re-running step 1 of your guide, doing some ChatGPT troubleshooting, and eventually ended up with things working. Not sure fully how with the mess of my process. I wanted to ask, now on 6.12.96 when I run "sudo dkms status", I get:
A snippet of the response from "lspci -k":
another piece of context, a response from sudo dmesg | grep -Ei 'r8125|r8169|dkms':
Is this how things should be with the symlink and guide steps in mind?
Thank you!