View previous topic :: View next topic |
Author |
Message |
mody Apprentice
Joined: 01 Oct 2004 Posts: 176
|
Posted: Thu Dec 30, 2004 5:58 am Post subject: trouble getting NAT working using "Home Routing: HOWTO& |
|
|
I did exactly as the guide said... the client(internal client) even gets an IP trough DHCP.... but the client is like 'Network is unreachable". I'm not sure what to do... I got all the kernel setting done, all the commands just pasted as my eth0/1 setup was identical to the guides setup
[/code][/b] |
|
Back to top |
|
|
BCC n00b
Joined: 28 Apr 2004 Posts: 51
|
Posted: Thu Dec 30, 2004 6:48 am Post subject: |
|
|
Hi,
Can you post the URL of the howto you are talking about ?
Can you post the error message(s) you are getting ?
Can you post the output of the following commands (as root) ?
Code: | ifconfig
netstat -rn
cat /proc/sys/net/ipv4/ip_forward
iptables -L |
|
|
Back to top |
|
|
mody Apprentice
Joined: 01 Oct 2004 Posts: 176
|
Posted: Thu Dec 30, 2004 1:29 pm Post subject: |
|
|
HOWTO Doc:http://www.gentoo.org/doc/en/home-router-howto.xml
ifconfig:
Code: |
eth0 Link encap:Ethernet HWaddr 00:11:2F:2B:C6:74
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:23 Base address:0xec00
eth1 Link encap:Ethernet HWaddr 00:80:48:2B:FA:FB
inet addr:202.134.165.64 Bcast:202.134.165.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:199 errors:0 dropped:0 overruns:0 frame:0
TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:12629 (12.3 Kb) TX bytes:439 (439.0 b)
Interrupt:18 Base address:0xd400
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
|
netstat -rn is 1
netstat:
Code: |
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
202.134.165.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
127.0.0.0 127.0.0.1 255.0.0.0 UG 0 0 0 lo
0.0.0.0 202.134.165.1 0.0.0.0 UG 0 0 0 eth1
|
iptables -L:
Code: |
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
|
is that helpful .. I might have mixed what you asked for. |
|
Back to top |
|
|
BCC n00b
Joined: 28 Apr 2004 Posts: 51
|
Posted: Fri Dec 31, 2004 7:20 am Post subject: |
|
|
Hi,
What system is running "the client" you are talking about ?
- if windows, can you post the output of (on the client) :
Code: | ipconfig /all
route print
tracert 204.74.99.100 |
- if gentoo (or linux), can you post the output of (on the client) :
Code: | ifconfig
netstat -rp
traceroute 204.74.99.100 |
emerge traceroute on the client if you don't have it installed yet. This command will show you the travel of IP packets from source (the client), eventualy to destination. This could show you where the problem is.
Sorry to only post questions and not answers here
Basicaly, if I understand your problem well, you have a gentoo box connected to the Internet, and a client box connected to your gentoo box.
Can you confirm that, from the gentoo box, you can join any host on the Internet ?
Then, from the client box, can you at least ping the local IP address ? From the client box, can you ping the IP address of eth0 of the gentoo box ?
From the client, try : "ping 192.168.0.1", then try ping "202.134.165.64"
One other question : on the gentoo box, can you post the output of :
Code: | iptables -t nat -n -L |
|
|
Back to top |
|
|
DarKRaveR Guru
Joined: 11 Oct 2003 Posts: 500 Location: Old Europe/G-Many
|
Posted: Fri Dec 31, 2004 7:26 am Post subject: |
|
|
Quote: | eth1 Link encap:Ethernet HWaddr 00:80:48:2B:FA:FB
inet addr:202.134.165.64 Bcast:202.134.165.255 Mask:255.255.255.0 |
IS eth1 the external interface ? and is the IP really a public one directly on the ethernet interface ? And static ?
What's your genereal setup ?
Mainly: Whidch Interface is connected to what, what kind of inet link do you have ? |
|
Back to top |
|
|
mody Apprentice
Joined: 01 Oct 2004 Posts: 176
|
Posted: Fri Dec 31, 2004 8:47 am Post subject: |
|
|
I got it working... thanks for the help. |
|
Back to top |
|
|
BCC n00b
Joined: 28 Apr 2004 Posts: 51
|
Posted: Fri Dec 31, 2004 11:42 am Post subject: |
|
|
mody wrote: | I got it working... thanks for the help. |
Great.
Maybe you could post what the problem was and how you managed to fix it, it could eventualy help people having the same problem as you when using this howto ? |
|
Back to top |
|
|
mody Apprentice
Joined: 01 Oct 2004 Posts: 176
|
Posted: Sun Jan 02, 2005 11:55 am Post subject: |
|
|
I'm not sure my experience will be of help to anyone... I just fulshed all the rules and started from the beginning and it worked... so maybe I made a typing error or something. All I can say thankfully is that the 'howto' is pretty flawless... thanks for all the help. |
|
Back to top |
|
|
|