Results 1 to 4 of 4
Enjoy an ad free experience by logging in. Not a member yet? Register.
- Join Date
- Jun 2006
Need help setting up my Linux box as gateway
eth0 gets its address assigned from the modem/internet. its IP address changes but gateway is 126.96.36.199 its DNS is 10.1.1.1
eth1 settings is
IP: 192.168.1.1 Subnet 255.255.255.0
one of my workstation settings is
IP: 192.168.1.2 Subnet: 255.255.255.0 Gateway: 192.168.1.1 DNS: 10.1.1.1
When i use the route command to activate my gateway
route add -net 192.168.1.0 netmask 255.255.255.0 gw 188.8.131.52 dev eth1
Its saids network unreachable. How do i resolve this?
also when i type route, it saids its default gateway is dslgw-211.29.13 im sure this is refering to the 184.108.40.206 gateway , Why does it say that??
im new to routing, can anyone help me resolve these issues so i can gain internet access to my workstations. Cheers
a couple thingsOriginally Posted by chris_roto_123
There are two important things to consider:
ONE: Your PC absolutely can't do any routing unless you have the ip_forward bit set. Type this command:
It must respond like this:
net.ipv4.ip_forward = 1
If not, edit /etc/sysctl.conf and add a line that says "net.ipv4.ip_forward = 1". There are a couple other ways of achieving this, which I forget.
TWO: Make sure you know for sure which ethernet card is which. Udev swapped mine (Yes! changed eth0 to eth1 and vice versa) a while ago when I upgraded the kernel and I spent a day trying to figure out why the network was screwed up.
- Join Date
- Jun 2006
Yep Ive considered both things, IP forwarding script is activated on startup, i did that by making rc.ip_forward in /etc/rc.d executable. I tried your way as well, which made no difference. As for 10.1.1.1 thats what it saids on eth0 from my ISP, i can ping it so i dont think theres anything wrong with it?, i hope. Anyone else got any idea's
try to configure ur gateway/linux box too as a DNS caching nameserver, and use iptables in order to
work this on ur gateway linux box, in short ur gateway and DNS is on the same server i dont think 10.1.1.1 is valid DNS. try asking ur ISP ur public DNS server ip address.