Networking Forums

Networking Forums > Computer Networking > Linux Networking > Activating routing

Reply
Thread Tools Display Modes

Activating routing

 
 
Fabrice Delente
Guest
Posts: n/a

 
      09-07-2008, 12:59 PM
Hello.

I have two machines, slick and swift. They communicate over a WIFI link
(both are set in Ad-Hoc mode), using addresses 192.168.1.3 for swift and
192.168.1.4 for slick. I can ssh from one to the other without trouble.

swift is connected to the internet through an ethernet cable to a DSL modem.

I'd like it to act as a router for slick.

I have installed and started dnsmaq on swift, which acts as a DNS server for
slick (this works).

However, I can't ping google.com from slick. It is served an IP, but can't
reach its destination:

fab@slick:~$ ping google.com
PING google.com (64.233.187.99) 56(84) bytes of data.
From swift.airforce-one.org (192.168.1.3): icmp_seq=1 Redirect Host(New nexthop: 192.168.1.254)
From swift.airforce-one.org (192.168.1.3): icmp_seq=2 Redirect Host(New nexthop: 192.168.1.254)
From swift.airforce-one.org (192.168.1.3): icmp_seq=3 Redirect Host(New nexthop: 192.168.1.254)
From swift.airforce-one.org (192.168.1.3) icmp_seq=1 Destination Host Unreachable
From swift.airforce-one.org (192.168.1.3) icmp_seq=2 Destination Host Unreachable
From swift.airforce-one.org (192.168.1.3) icmp_seq=3 Destination Host Unreachable
From swift.airforce-one.org (192.168.1.3): icmp_seq=4 Redirect Host(New nexthop: 192.168.1.254)
From swift.airforce-one.org (192.168.1.3): icmp_seq=5 Redirect Host(New nexthop: 192.168.1.254)
From swift.airforce-one.org (192.168.1.3): icmp_seq=6 Redirect Host(New nexthop: 192.168.1.254)
From swift.airforce-one.org (192.168.1.3) icmp_seq=5 Destination Host Unreachable
From swift.airforce-one.org (192.168.1.3) icmp_seq=6 Destination Host Unreachable
From swift.airforce-one.org (192.168.1.3) icmp_seq=7 Destination Host Unreachable
From swift.airforce-one.org (192.168.1.3): icmp_seq=8 Redirect Host(New nexthop: 192.168.1.254)

--- google.com ping statistics ---
9 packets transmitted, 0 received, +6 errors, 100% packet loss, time 8010ms
, pipe 3

Here is slick's routing table:

root@slick:~# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.1.0 * 255.255.255.0 U 0 0 0 wlan0
loopback * 255.0.0.0 U 0 0 0 lo
default 192.168.1.254 0.0.0.0 UG 0 0 0 wlan0
default swift.airforce- 0.0.0.0 UG 0 0 0 wlan0

and here is swift's routing table:

root@swift:~# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
82.230.24.0 * 255.255.255.0 U 0 0 0 eth0
192.168.1.0 * 255.255.255.0 U 0 0 0 ath0
default 192.168.1.254 0.0.0.0 UG 0 0 0 ath0
default 82.230.24.254 0.0.0.0 UG 0 0 0 eth0

Any help? Thanks!

--
Fabrice DELENTE
 
Reply With Quote
 
 
 
 
Fabrice Delente
Guest
Posts: n/a

 
      09-07-2008, 04:47 PM
Moe Trin <(E-Mail Removed)> wrote:
> So - who is 192.168.1.254, and how did that enter the picture?


I entered it myself, out of despair and because I had read about it on a
page somewhere.

I'll try the modifications you suggest, thanks!

--
Fabrice DELENTE
 
Reply With Quote
 
Fabrice Delente
Guest
Posts: n/a

 
      09-08-2008, 05:05 AM
Clifford Kite <(E-Mail Removed)> wrote:
> In addition to Moe's excellent advice be sure ip forwarding is enabled
> on swift:
>
> corncob:~# cat /proc/sys/net/ipv4/ip_forward
> 1


Yes, I did that too, but still can't access the internet from slick... Is
there anything else to configure (I have enable "Advanced route" in the
kernel options)?

Thanks.

--
Fabrice DELENTE
 
Reply With Quote
 
Kees Theunissen
Guest
Posts: n/a

 
      09-08-2008, 09:22 AM
Fabrice Delente wrote:
> Clifford Kite <(E-Mail Removed)> wrote:
>> In addition to Moe's excellent advice be sure ip forwarding is enabled
>> on swift:
>>
>> corncob:~# cat /proc/sys/net/ipv4/ip_forward
>> 1

>
> Yes, I did that too, but still can't access the internet from slick... Is
> there anything else to configure (I have enable "Advanced route" in the
> kernel options)?
>
> Thanks.
>


Use NAT (a.k.a. masquerading) on swift when forwarding packets to/from
slick. As slick uses the private IP number 192.168.1.4 you can't
simply forward slicks packets unmodified to the public internet.


Regards,

Kees.

--
Kees Theunissen.
 
Reply With Quote
 
Fabrice Delente
Guest
Posts: n/a

 
      09-08-2008, 04:23 PM
Kees Theunissen <(E-Mail Removed)> wrote:
> Use NAT (a.k.a. masquerading) on swift when forwarding packets to/from
> slick. As slick uses the private IP number 192.168.1.4 you can't
> simply forward slicks packets unmodified to the public internet.


I've looked into the kernel options but didn't find any optin to activate.
Could you tell me how to do masquerading? Thanks!

--
Fabrice DELENTE
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Activating new NTL broadband connection - URL Tony Brett Broadband 21 01-19-2007 03:08 PM
Activating both A + G Wireless Channels brentromero Wireless Networks 2 11-02-2005 12:34 AM
WG511T activating WPA in Win 2000 Carmine Broadband Hardware 2 10-22-2004 09:33 AM
Problem Activating/Connecting via Port 443 Doug Thews Windows Networking 3 07-13-2004 09:52 PM
Wndows freezes when activating SSID Anthony Windows Networking 0 01-18-2004 02:53 AM



1 2 3 4 5 6 7 8 9 10 11