Problem installing driver: "dkms: command not found"

I have installed Music Box and it works grate! the problem however is that my wifi dongle dos not work with it. I have downloaded a driver that should do the trick but when I’m trying to intall it I get a error message.
I downloded the drivers to root@MusicBox:~/rtl8812AU_8821AU_linux

When I run ls I get:

Kconfig  LICENSE  Makefile  README.md  clean  core  dkms.conf  fetch.sh  hal  ifcfg-wlan0  include  os_dep  runwpa  wlan0dhcp

Command more README.md gives me:

rtl8812AU_8821AU_linux
======================

rtl8812AU_8821AU linux kernel driver for AC1200 (801.11ac) Wireless Dual-Band USB Adapter

##Autocompiling with DKMS```
sudo cp -R . /usr/src/rtl8812AU_8821AU_linux-1.0
sudo dkms add -m rtl8812AU_8821AU_linux -v 1.0
sudo dkms build -m rtl8812AU_8821AU_linux -v 1.0
sudo dkms install -m rtl8812AU_8821AU_linux -v 1.0
```

First I run

sudo cp -R . /usr/src/rtl8812AU_8821AU_linux-1.0

no problems there, but

dkms add -m rtl8812AU_8821AU_linux -v 1.0
dkms build -m rtl8812AU_8821AU_linux -v 1.0
dkms install -m rtl8812AU_8821AU_linux -v 1.0

gives me error message sudo: dkms: command not found
Does anyone have an idea how to fix this?

sudo apt-get install dkms

1 Like

I tried that but then I enden up with

root@MusicBox:~/rtl8812AU_8821AU_linux# sudo dkms build -m rtl8812AU_8821AU_linux -v 1.0
Error! echo
Your kernel headers for kernel 3.18.7+ cannot be found at
/lib/modules/3.18.7+/build or /lib/modules/3.18.7+/source.

After rebooting I get:

root@MusicBox:~/rtl8812AU_8821AU_linux# sudo dkms add -m rtl8812AU_8821AU_linux -v 1.0
Error! DKMS tree already contains: rtl8812AU_8821AU_linux-1.0
You cannot add the same module/version combo more than once.
root@MusicBox:~/rtl8812AU_8821AU_linux# sudo dkms build -m rtl8812AU_8821AU_linux -v 1.0
Error! echo
Your kernel headers for kernel 3.18.7+ cannot be found at
/lib/modules/3.18.7+/build or /lib/modules/3.18.7+/source.
root@MusicBox:~/rtl8812AU_8821AU_linux# sudo dkms install -m rtl8812AU_8821AU_linux -v 1.0
Error! echo
Your kernel headers for kernel 3.18.7+ cannot be found at
/lib/modules/3.18.7+/build or /lib/modules/3.18.7+/source.
sudo apt-get install linux-headers-generic
```

I get an error

 E: Package 'linux-headers-generic' has no installation candidate

Debian does not have any headers (or kernel) packages called “generic” AFAIK. But futhermore, I think in Raspbian the headers are not distributed as packages but you need to get a tarball from the git and unpack that AFAIK.

I have somehow succeded with add and build but is still stuck on install command.

Debian does not have any headers (or kernel) packages called “generic” AFAIK. But futhermore, I think in Raspbian the headers are not distributed as packages but you need to get a tarball from the git and unpack that AFAIK.

At the moment I have no idea what your talking about, but you have given me some new wordsto google on and I will see how that works out, thanks. :slight_smile: