-   Linux - Wireless Networking (
-   -   Problems on building own AP (

nsp 11-17-2011 11:56 PM

Problems on building own AP
My aim is to build a direct wi-fi connection between my iPad and my Linux machine. Thus I can access my Linux through ssh, ftp, http, and samba server. Since I have a Ralink 3090 wi-fi card in my Linux machine, I want to build it a linux wi-fi AP, and let my iPad connect its ssh or other servers. The driver for wi-fi card is mac80211, with a nl80211 lib, and the daemon software is hostapd.

Hostapd seems work well, since iwconfig tells that wlan0 works on a Master mode, and I can see my wi-fi SSID in iPad. But when iPad connected it, it took several minutes to show connection was ready, and iPad got a strange IP. So I didn't know what IP to connect the Linux box with ssh or http.

I did this on Linux box:

ifconfig wlan0 broadcast netmask
Then let iPad to connect the AP with a static IP and subnet mask it took several minutes to show the connection was ready, but I could not ssh or browse http I tested with a Windows machine, it instantly showed wi-fi connection was ready, but it couldn't ping too.

I followed some guides and tried DHCPD, with some level of unclearness. Almost the same thing: iPad or Windows machine got an expected IP (in the range of presetted), but couldn't ping

I guess it's not a hostapd problem, but a ip_tables problem or some other settings. I checked this thread:

But it is somewhat old, so the kernel modules and iptables command are somewhat different, which means I cannot follow it step by step.

I need someone to tell me what my problem looks like to be. iptables? Or?

Thanks a lot! And sorry for my English.

nsp 11-18-2011 04:50 AM

Then I did something like this:

brctl addbr br0 #This creates the br0 bridge
brctl addif br0 eth0 #This adds the eth0 interface to the br0 ethernet bridge
brctl setfd br0 0 #This sets the forwarding delay to 0 seconds
brctl addif br0 wlan0

and also something like:

iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
I am not sure what the meaning were, and which commands worked.

And my iPad got a dynamic IP of, which is within my upper router's DHCP range! And I can acces the Internet now. But I can't access my own Linux box!

So I think it's a net - subnet problem. Any suggestions?

nsp 11-18-2011 05:18 AM

I think this means my wireless AP is built. But the linux box still needs other functions to let its wireless client to access its servers. What is it? Router? I need suggestions, thanks!

nsp 11-22-2011 03:12 AM


All times are GMT -5. The time now is 11:32 AM.