Created
June 21, 2014 17:16
-
-
Save llazzaro/3353a8add5d9f7fea918 to your computer and use it in GitHub Desktop.
Share Internet with Debian
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sysctl -w net.ipv4.ip_forward=1 | |
iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE | |
iptables -F FORWARD | |
iptables -A FORWARD -j ACCEPT | |
apt-get install dnsmasq | |
printf " interface=eth0\ndhcp-range=192.168.10.10,192.168.10.19,4h" >> file.txt | |
/etc/init.d/dnsmasq restart | |
ifconfig eth0 192.168.10.1 netmask 255.255.255.0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment