PDA

View Full Version : [all variants] Configuring WDS with Madwifi



alexzip
November 19th, 2008, 04:45 PM
Hi all, i need to join two network segments using two Atheros wireless cards (PCMCIA Proxim Orinoco and D-link DWL-G520) and Madwifi (madwifi-hal-0.10.5.6-r3861-20080903.tar.gz in Ubuntu 8.10) but it doesn┤t work.
Information source: http://madwifi-project.org/wiki/UserDocs/WDSBridge
I did the following:
Computer 1

wlanconfig ath0 create wlandev wifi0 wlanmode ap # Create an AP
brctl addbr br0 # Create a bridge
iwpriv ath0 mode 3 # 1 = 802.11a, 2 = 802.11b, 3 = 802.11g
iwconfig ath0 essid wds channel 1
iwpriv ath0 wds 1
ifconfig ath0 up # Bring up the interface and next up to the bridge
brctl addif br0 ath0
ifconfig br0 10.0.0.1 netmask 255.255.255.0 up # Bring up the bridge
wlanconfig ath1 create wlandev wifi0 wlanmode wds # Now create a station
iwpriv ath1 mode 3
iwconfig ath1 channel 3
iwpriv ath1 wds_add <MAC tarjeta Atheros del PC2>
iwpriv ath1 wds 1
ifconfig ath1 up
brctl addif br0 ath1
echo 1 > /proc/sys/net/ipv4/ip_forward

Computer 2

wlanconfig ath0 create wlandev wifi0 wlanmode ap # Create an AP
brctl addbr br0 # Create a bridge
iwpriv ath0 mode 3 # 1 = 802.11a, 2 = 802.11b, 3 = 802.11g
iwconfig ath0 essid wds channel 1
iwpriv ath0 wds 1
ifconfig ath0 up # Bring up the interface and next up to the bridge
brctl addif br0 ath0
ifconfig br0 10.0.0.2 netmask 255.255.255.0 up # Bring up the bridge
wlanconfig ath1 create wlandev wifi0 wlanmode wds # Now create a station
iwpriv ath1 mode 3
iwconfig ath1 channel 3
iwpriv ath1 wds_add <MAC tarjeta Atheros del PC1>
iwpriv ath1 wds 1
ifconfig ath1 up
brctl addif br0 ath1
echo 1 > /proc/sys/net/ipv4/ip_forward

On each computer a wired network card:
Computer 1

ifconfig eth0 10.0.0.3 netmask 255.255.255.0 up
route add default gw 10.0.0.1

Computer 2

ifconfig eth0 10.0.0.4 netmask 255.255.255.0 up
route add default gw 10.0.0.2

Test:
Ping doesn┤t responds from Computer 1 to 10.0.0.2 or 10.0.0.4.
Ping doesn┤t responds from Computer 2 to 10.0.0.1 or 10.0.0.3.
┐How can I know if the WDS bridge is well made and the wifi cards are linked?
Please, someone could help me.

This is the configuration i want.
http://perso.wanadoo.es/nneoxito/images/link.JPG