I am not a networking guy, so apologies in advance.
I have a small Linux (Ubuntu) box with 2 ethernet ports.
- eth2 is connected to a cable modem that gives it a 192.168.1.x address + internet connection
- eth3 I plug directly into, I was able to install isc-dhcp-server and configure it (config below). I am able to plugin a Windows laptop and get an IP in the 10.0.0.x range as configured.
How the heck do I get eth3 seeing the internet (like eth2 already does)? I'd like to be able to plugin a Windows laptop or an access point to eth3 and have it get an internet connection automatically.
I've tried pinging from eth3 and eth2 out to google.com and the results:
ping -I **eth3** google.com => destination host unreachable
ping -I **eth2** google.com => works!
Here is my config:
nano -w /etc/dhcp/dhcpd.conf
ddns-updates off;
option domain-name "example.local";
option domain-name-servers 8.8.8.8;
authoritative;
subnet 10.0.0.0 netmask 255.255.255.0 {
interface eth3;
default-lease-time 6000;
max-lease-time 7200;
range 10.0.0.100 10.0.0.200;
option subnet-mask 255.255.255.0;
option routers 10.0.0.254;
option broadcast-address 10.0.0.255;
option domain-name-servers 8.8.8.8;
}
nano -w /etc/default/isc-dhcp-server
INTERFACES="eth3"
nano -w /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
auto eth3
iface eth3 inet static
address 10.0.0.200
gateway 10.0.0.1
netmask 255.255.255.0
dns-nameservers 8.8.8.8
I have tried port forwarding:
sudo sysctl net/ipv4/ip_forward=1
Also tried bridging, but it kicks me out of the box as soon as I hit enter:
brctl addbr br0
brctl addif br0 eth2 eth3
Any advice or help would be appreciated. I've spent a good 8 hours fumbling through this and feel like an idiot!
Thanks!