Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am trying to compile madwifi-0.9.4 and create an access point on a linux box which is currently acting as a nat.
Linux version 2.6.18-92.1.22.el5xen (mockbuild@builder16.centos.org) (gcc version 4.1.2 20071124 (Red Hat 4.1.2-42))
This is the link which was in build -> ../../../usr/src/kernels/2.6.18-92.1.22.el5-xen-i686
I removed that link and changed this link to ../../../usr/src/kernels/2.6.18-128.1.10.el5-xen-i686
This is what is listed under /usr/src/kernels/2.6.18-128.1.10.el5-xen-i686
drwxr-xr-x 26 root root 4096 May 25 00:06 arch
drwxr-xr-x 2 root root 4096 May 25 00:06 block
drwxr-xr-x 4 root root 4096 May 25 00:06 crypto
drwxr-xr-x 65 root root 4096 May 25 00:06 drivers
drwxr-xr-x 66 root root 4096 May 25 00:06 fs
drwxr-xr-x 19 root root 4096 May 25 00:06 include
drwxr-xr-x 2 root root 4096 May 25 00:06 init
drwxr-xr-x 2 root root 4096 May 25 00:06 ipc
-rw-r--r-- 1 root root 57326 May 7 12:18 kabi_whitelist
drwxr-xr-x 5 root root 4096 May 25 00:06 kernel
drwxr-xr-x 5 root root 4096 May 25 00:06 lib
-rw-r--r-- 1 root root 48181 May 7 12:19 Makefile
drwxr-xr-x 2 root root 4096 May 25 00:06 mm
-rw-r--r-- 1 root root 167736 May 7 12:19 Module.kabi
-rw-r--r-- 1 root root 1089 May 7 12:19 Module.markers
-rw-r--r-- 1 root root 373792 May 7 12:19 Module.symvers
drwxr-xr-x 41 root root 4096 May 25 00:06 net
drwxr-xr-x 4 root root 4096 May 25 00:06 samples
drwxr-xr-x 10 root root 4096 May 25 00:06 scripts
drwxr-xr-x 4 root root 4096 May 25 00:06 security
drwxr-xr-x 18 root root 4096 May 25 00:06 sound
-rw-r--r-- 1 root root 46693 May 7 12:19 symsets-2.6.18-128.1.10.el5xen.tar.gz
drwxr-xr-x 2 root root 4096 May 25 00:06 usr
Checking requirements... ok.
Checking kernel configuration... ok.
make -C /lib/modules/2.6.18-92.1.22.el5xen/build SUBDIRS=/home/keith/wifi/madwifi-0.9.4 modules
make[1]: Entering directory `/usr/src/kernels/2.6.18-128.1.10.el5-xen-i686'
CC [M] /home/keith/wifi/madwifi-0.9.4/ath/if_ath.o
In file included from <command line>:1:
/home/keith/wifi/madwifi-0.9.4/ath/../include/compat.h:140: error: redefinition of 'skb_end_pointer'
include/linux/skbuff.h:417: error: previous definition of 'skb_end_pointer' was here
/home/keith/wifi/madwifi-0.9.4/ath/../include/compat.h:145: error: redefinition of 'skb_tail_pointer'
include/linux/skbuff.h:835: error: previous definition of 'skb_tail_pointer' was here
/home/keith/wifi/madwifi-0.9.4/ath/../include/compat.h:150: error: redefinition of 'skb_set_network_header'
include/linux/skbuff.h:1021: error: previous definition of 'skb_set_network_header' was here
/home/keith/wifi/madwifi-0.9.4/ath/../include/compat.h:155: error: redefinition of 'skb_reset_network_header'
include/linux/skbuff.h:1016: error: previous definition of 'skb_reset_network_header' was here
/home/keith/wifi/madwifi-0.9.4/ath/../include/compat.h:160: error: redefinition of 'skb_mac_header'
include/linux/skbuff.h:1036: error: previous definition of 'skb_mac_header' was here
/home/keith/wifi/madwifi-0.9.4/ath/../include/compat.h:165: error: redefinition of 'skb_reset_mac_header'
include/linux/skbuff.h:1046: error: previous definition of 'skb_reset_mac_header' was here
make[3]: *** [/home/keith/wifi/madwifi-0.9.4/ath/if_ath.o] Error 1
make[2]: *** [/home/keith/wifi/madwifi-0.9.4/ath] Error 2
make[1]: *** [_module_/home/keith/wifi/madwifi-0.9.4] Error 2
make[1]: Leaving directory `/usr/src/kernels/2.6.18-128.1.10.el5-xen-i686'
make: *** [modules] Error 2
I am not sure if I have the source code for the kernel installed, this is where I am lost. I see `/usr/src/kernels/2.6.18-128.1.10.el5-xen-i686'.
Hi Keith,
A couple of suggestions:
1. if you're not sure of what kernel you're running (and want to build a module for) the type
Code:
uname -a
in a terminal.
2. For building a module I always use module-assistant which makes everything quite simple. You should be able to find a package for your distro. You will need the headers for your kernel but m-a will download them for you if you don't have them installed.
Cheers,
jdk
I was able to install madwifi with apt-get, I also have the headers and kernel-devel to match my kernel version. When I modprobe ath_pci I get
FATAL: Module ath_pci not found. I tried to do a find for ath_pci I can't locate this module which is leading me to believe it was not compiled? I will look at what you suggested and any other help would be appreciated.
Thanks again,
Also this is the Kernel I am using Linux 2.6.18-92.1.22.el5xen
I think you need to install the module with module-assistant. Using apt-get will install the source but then you must build the module with m-a.
This link may help: http://madwifi-project.org/wiki/User...Debian/MadWifi
Cheers,
jdk
I appreciate the suggestions but module assistant seems to be for debian, I can't locate a rpm or redhat version for centos. It seems really easy on Debian boxes from what I have been reading. If anyone could give me some pointers on how to resolve my issue with compiling the module it would be helpful. As I said I used apt-get which was part of the dag repo for redhat to install madwifi. I had no errors during the install but I cannot find ath_pci anywhere on my system, its leading me to believe it was not installed?
Here are what I have for modules, the card I installed is a TP-Link TL-WN651G Ver 1.5. How can I tell if the module it needs is listed, I thought it should be ath0_pci for madwifi?
Also I did yum install kernel-xen-devel which it installed in /usr/src/kernels
drwxr-xr-x 20 root root 4096 May 25 18:31 2.6.18-128.1.10.el5-xen-i686
lrwxrwxrwx 1 root root 28 May 25 15:27 2.6.18-128.1.10.el5xen-i686 -> 2.6.18-128.1.10.el5-xen-i686
drwxr-xr-x 18 root root 4096 May 25 04:41 2.6.18-92.1.22.el5.centos.plus-i686
Uname -a gives me Linux TrunkmonkeyNat 2.6.18-92.1.22.el5xen #1 SMP Tue Dec 16 13:08:49 EST 2008 i686 i686 i386 GNU/Linux.
When I run make in the madwifi directory I get this error
madwifi-0.9.4]# make
./kernelversion.c:13:30: error: linux/utsrelease.h: No such file or directory
Makefile.inc:91: *** KERNELCONF: /lib/modules/2.6.18-92.1.22.el5xen/build/.config does not exist.. Stop.
This is what I have for a soft link in /lib/modules/2.6.18-92.1.22.el5xen/build
lrwxrwxrwx 1 root root 45 May 25 15:37 2.6.18-128.1.10.el5-xen-i686 -> /usr/src/kernels/2.6.18-128.1.10.el5-xen-i686
I believe there is something wrong with how I have the kernel-devel and or the link set up.
I installed madwifi with yum, after the install I ran the command for modprob ath_pci it showed up in my ifconfig at Wlan0 Master. When I rebooted the box it hung would not reboot I had to power it off. After reboot the module was not loaded, when trying modprobe it was not listed in ifconfig.
It's been a while but I now have the madwifi driver installed, bridged access point is up. I can now see my essid from clients the only problem is when I join I can't surf. The access point will let me join but once in I can't get out to the net. I can ssh that box fine, when I am in that box I can ping the gateway and google fine. Any ideas of what to look for ?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.