After many many months of hacking at my wireless card, i've finally managed to get it running in master mode - I'd previously thought it was impossible until I found some short nuggets on information on the net....recent kernel upgrades have also helpd. I've now managed to build hostapd so that it supports nl80211 and the latest madwifi drivers. This means I can now run my rt61pci card in master mode as an access point!
At least kernel-2.6.18-194 (as provided in ClearOS5.2 SP1) as this comes with v2.3.0 of module rt61pci
Any of my testing kernel-2.6.32.x series will also do
Updated version of libnl (see RPM below)
01:08.0 Network controller: RaLink RT2561/RT61 802.11g PC
[root@starlane ~]# modinfo rt61pci
description: Ralink RT61 PCI & PCMCIA Wireless LAN driver.
vermagic: 2.6.18-194.8.1.v5 SMP mod_unload 686 REGPARM 4KSTACKS gcc-4.1
parm: nohwcrypt:Disable hardware encryption. (bool)
1. First configure your card from the webconfig (give it a static IP on it's own subnet, and LAN or HotLAN role)
2. Download the card firmware from www.ralinktech.com/support.php?s=2
Extract and save all three *.bin files into /lib/firmware
Setup the community repo as per instructions HERE
yum --enablerepo=timb install hostapd
If your running a newer kernel-2.6.32+ you can use a new version of hostapd
yum --enablrepo=timb-testing --enablerepo=timb install hostapd
4. Edit config at /etc/hostapd.conf, as a minimum you will need to add the interface name (wlan0), the hw_mode (a,b or g), channel number (1-13), and ssid. You can also select the madwifi driver if using an Atheros card by changing the driver name. Driver options are: hostap / wired / madwifi / nl80211
If you want WPA2 uncomment the four lines and the passphrase. The passphrase needs to be greater than 8 characters long.
# Uncomment these for base WPA & WPA2 support with a pre-shared key
# DO NOT FORGET TO SET A WPA PASSPHRASE!!
# Most modern wireless drivers in the kernel need driver=nl80211
# Customize these for your local configuration...
5. Then run 'service hostapd start'
You should now find that your card has entered master mode, (run 'iwconfig' to check) and that your access point is now available to be connected to.
Before you can connect you will need to enable DHCP on this interface. You can do this from the webconfig
Errors and client handshakes are displayed in /var/log/messages
Debugging - run 'service hostapd stop' then from the console 'hostapd -d /etc/hostapd.conf' to get the debug output
Frequent start/stops of the service may result in the driver crashing due to the virtual wlan0 interface. Disable the interface and reload the module to start again,
service hostapd stop
ifconfig wlan0 down
modprobe -r rt61pci
service hostapd start
If things are still a bit flaky try the newer 2.6.32 kernels
i'm posting this from my laptop connected at 54mpbs using WPA2-PSK, with throughput of 25Mbps
For the technically minded:-
I have also provided hostapd-0.7.3 (the latest version) but this requires the 2.6.32 kernel due to upgrades in the nl80211 driver. Feel free to try this version also. 0.6.9 works well with the 2.6.18 kernels...
You cannot use iwconfig to set master mode, the rt2x00 drivers for the rt61 card only permit hostapd to make these changes
The config file provided is a simplified version of the actual hostapd config. There are many more configurations available...see the hostapd source for details
You can configure more complex environments such as radius authenticaton, see hostapd docs for info