Internet Connection Sharing
Hi,
I have a linux box (running Fedora Core 2) that I want to setup as a gateway. eth0 of this machine is connected to the ADSL modem, while eth1 is configured as a DHCP server (using dhcpd).
Now I am trying to setup internet connection sharing for machines on my internal network. To do this, I have enabled IP forwarding from /proc/sys/net/ipv4/ip_forward and changed the value of the net.ipv4.ip_forward field in /etc/sysctl.conf. I have also added the following rule to the nat table of the iptables firewall.
Code:
iptables -t nat -A POSTROUTING -j MASQUERADE
The problem is that while I can use ping external IP addresses, the domain name resolution is not working (i.e. I can ping google.com by it's IP address but not by using google.com). This seems to be some kind of DNS problem but I have no idea on how to solve it.
My dhcp.conf file contains
Code:
ddns-update-style interim;
subnet 192.168.0.0 netmask 255.255.255.0
{
option routers 192.168.0.1;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.0.255;
range 192.168.0.2 192.168.0.254;
}
Thanks for your time
is-serp