Package needed:
hostapd
dhcp server
ip tables
Get hostapd:
sudo apt-get install hostapdEdit or create /etc/hostapd/hostapd.conf
ctrl_interface=/var/run/hostapd#ctrl_interface_group=wheel
# Some usable default settings...macaddr_acl=0auth_algs=1ignore_broadcast_ssid=0
# Uncomment these for base WPA & WPA2 support with a pre-shared key#wpa=3#wpa_key_mgmt=WPA-PSK#wpa_pairwise=TKIP#rsn_pairwise=CCMP
# DO NOT FORGET TO SET A WPA PASSPHRASE!!#wpa_passphrase=YourPassPhrase
# Most modern wireless drivers in the kernel need driver=nl80211driver=nl80211
# Customize these for your local configuration...interface=wlan0hw_mode=gchannel=1ssid=LinuxReaders
macaddr_acl=0auth_algs=1ignore_broadcast_ssid=0wpa=3wpa_passphrase=linuxreaderscomwpa_key_mgmt=WPA-PSKwpa_pairwise=TKIPrsn_pairwise=CCMPTo start hostapd:
sudo hostapd -d /etc/hostapd/hostapd.confGet Dhcp server:
sudo apt-get install isc-dhcp-serverEdit or create dhcpd.conf
sudo nano /etc/dhcp/dhcpd.confoption subnet-mask 255.255.255.0;default-lease-time 360000;max-lease-time 720000;
option domain-name-servers 8.8.8.8;subnet 192.168.1.0 netmask 255.255.255.0 { range 192.168.1.10 192.168.1.254; option broadcast-address 192.168.1.255; option routers 192.168.1.1;}
Edit or create /etc/default/isc-dhcp-server and add wlan0 in INTERFACES
sudo nano /etc/default/isc-dhcp-server
INTERFACES="wlan0"Assign IP Address to wlan0
sudo ifconfig wlan0 192.168.1.1 netmask 255.255.255.0Edit /etc/rc.local to get wifi working on every reboot
echo 1 > /proc/sys/net/ipv4/ip_forward
/sbin/iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
ifconfig wlan0 inet 192.168.1.1 netmask 255.255.255.0
hostapd -d /etc/hostapd/hostapd.conf &
/etc/init.d/isc-dhcp-server restart
Hi,
ReplyDeleteI've been trying to figure out how many connetions the PandaBoard ES can handle at one time when used as a router? I'm trying to turn the PandaBoard ES into a wireless mesh router but am unsure if it can handle the multiple connections.