I am having the same trouble as others getting my Atheros AR8131 Ethernet card recognised by Ubuntu 12.10 on my new HP Pavillion P7-1449 PC. I found the same question where the answer suggested the following:

  1. Download Tarball compact-wireless-3.6.8-1-snpc
  2. Run

    ./scripts/driver-select alx
    sudo make install

The problem is when I run the make command I get the following:

make -C /lib/modules/3.5.0-21-generic/build M=/home/chris/Downloads/compat-wireless-3.6.8-1-snpc modules
make: *** /lib/modules/3.5.0-21-generic/build: No such file or directory.  Stop.
make: *** [modules] Error 2

Found a link to an alternative patch file (compat-wireless-2012-09-25-pc) but then I get the similar error:

make -C /lib/modules/3.5.0-21-generic/build M=/home/chris/Desktop/compat-wireless-2012-09-25-pc modules
make: *** /lib/modules/3.5.0-21-generic/build: No such file or directory.  Stop.
make: *** [modules] Error 2

Any help you could provide would be greatly appreciated.

  • Have you tried installing the compat-wireless packages provided by Ubuntu in the repositories? The latest 3.6 is available as a package: linux-backports-modules-cw-3.6-quantal-generic. Compiling from source should be attempted only as a last resort, in my opinion.
    – gertvdijk
    Dec 31, 2012 at 1:04
  • Thanks. Didn't know that existed (I'm new to Linux). Up until now I've been googling and/or checking out this website for solutions to my problems. Check it out and it looks to me like the best candidates are linux-source-3.5.0 or module-init-tools - or do you suggest applying all. Thanks again.
    – Chris
    Dec 31, 2012 at 2:11
  • "Check it out and it looks to me like the best candidates are linux-source-3.5.0 or module-init-tools - or do you suggest applying all." Please rephrase that, I don't get your question in there. And what's the point of downloading the whole Linux kernel source code?
    – gertvdijk
    Dec 31, 2012 at 2:14
  • Unfortunately use of this operating system and website assume in-depth knowledge. In fact, I don't know what any of those links mean. I don't know how to download or deploy any of those files and for the record, I assumed they were patches rather than " the whole Linux kernel source code". On closer look I see the heading "Backported wireless drivers for generic kernel image" but there is nothing listed under that heading so I assume that the driver I need is not made it to the list.
    – Chris
    Dec 31, 2012 at 2:26
  • 1

4 Answers 4


The instructions to install compat-wireless modules are good, but in recent Ubuntu releases, this has been packaged and there's no need to compile this from source anymore! So, let's take a step back and look at another much simpler approach to install it.

Simply install the appropriate linux-backports-modules-cw-* package for your kernel, e.g.:

  • For Quantal, using Linux compat-wireless-3.6 backported to regular kernel

    sudo apt-get install linux-backports-modules-cw-3.6-quantal-generic
  • Same, but for Precise

    sudo apt-get install linux-backports-modules-cw-3.6-precise-generic

Or use any other package management tool to install this package. While it has 'backport' in its package name, it's not needed to enable any backports repository - it's just there in main.

Finally, reboot, or if you know the kernel module to load: sudo modproble modulename.


Lately the modules from the 3.8 kernel have been backported, so use

sudo apt-get install linux-backports-modules-cw-3.8-precise-generic

instead of

sudo apt-get install linux-backports-modules-cw-3.6-precise-generic

as in gertvdijk's answer here


I am not sure, there is no need of compilation. Alx module which only works with my AR8161 on Ubuntu 12.04 LTS is gone. So download, and compile works for me.

I have to download some older package from compact wireless website which ALX module contains as mentioned here.

wget -O- http://linuxwireless.org/download/compat-wireless-2.6/compat-wireless-2012-07-03-pc.tar.bz2

no, that will not help. The last version that contains alx module is version 3.4, unfortunately.

so a regular user with this network card is completely dumped :(

and each time I upgrade to a new version of kernel once a few months, I have to waste one hour trying to figure out where did the linux magicians hide my network card driver! anybody's been curious why Linux fails on Desktop? this is why! :(

why cannot they just move it where all the other network card drivers are?

so the proper command is:

sudo apt-get install linux-backports-modules-cw-3.4-precise-generic


sudo apt-get install linux-backports-modules-cw-3.4-precise-generic-pae

depending on which magic version of kernel you magically use...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.