LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 07-28-2003, 11:08 AM   #1
howlie
LQ Newbie
 
Registered: Jul 2003
Distribution: Red Hat 9
Posts: 5

Rep: Reputation: 0
Unhappy Adding route breaks ping


I seem to be having a strange problem. I have set up a CIPE connection between two Red Hat Linux 9 machines, one at work and one at home. I would like to access my home network from work and vice verce. My home network is NAT'ed behind a Linksys router. My home linux machine is my DMZ.

I have set up the CIPE connection and I can do everything I want to from work, even access my home computers by name using DNS on my home linux! The problem is accessing the work network from home. I'll handle the routing/forwarding later but I seem to be having a strange problem with a defualot route right now. If I ping work using the comand:

ping -I cipcb0 <ip of work machine>

I do just fine. However, if I add a default route using either

route add -host <work machine> dev cipcb0

or

route add -host <work machine> gw <ip of either end of cipe>

my ping stops working, whether or not I use the -I on the ping. Also, if I start a ping on the work computer it will go until I add the route on the home computer. It then stops until I delete the route.

Any suggestions would be appreciated.

Last edited by howlie; 07-28-2003 at 01:11 PM.
 
Old 07-28-2003, 09:20 PM   #2
mfirth
LQ Newbie
 
Registered: Jul 2003
Location: Ipswich, UK
Distribution: Slackware 7.1 and 9.0
Posts: 4

Rep: Reputation: 0
If ping is working without adding this route, what are you adding the route to do?

Normally, ping wouldn't work, and you would add one or more routes to the routing table and it would start working.

If ping is working through whatever routes are there then it is probably that the new route you have added to your work machine is clobbering whatever route it was using before.

If you are trying to add a default route for your home PC through your work PC, or vice versa, then the command you want is probably:

route add default gw <ip of other end of cipe>
 
Old 07-29-2003, 04:02 AM   #3
howlie
LQ Newbie
 
Registered: Jul 2003
Distribution: Red Hat 9
Posts: 5

Original Poster
Rep: Reputation: 0
Perhaps I didn't explain what I'm trying to do very well. What I want to do is to communicate securely over the internet between subnets. A normal ping does not go through the tunnel, and hence is not secure. If I force the ping through the tunnel by specifying the CIPE interface (the -I cipcb0 on the ping command), the ping works. If I try to set a default route to the host on the other end (or the subnet) everything breaks. I would like to make all traffic between the two subnet go through the tunnel by default.
 
Old 07-29-2003, 04:15 PM   #4
mfirth
LQ Newbie
 
Registered: Jul 2003
Location: Ipswich, UK
Distribution: Slackware 7.1 and 9.0
Posts: 4

Rep: Reputation: 0
Have you tried / are you able to configure both ends to route to each other down your secure pipe?

If you set up one end, but not the other I can see how that would cause problems.

e.g. On home PC:

route add -net <work subnet> -netmask <mask> gw <work end of secure pipe>

On work PC:

route add -net <home subnet> -netmask <mask> gw <home end of secure pipe
 
Old 07-29-2003, 10:18 PM   #5
howlie
LQ Newbie
 
Registered: Jul 2003
Distribution: Red Hat 9
Posts: 5

Original Poster
Rep: Reputation: 0
I solved the problem! FYI you cannot make a route to the remote end through the cipe device. (Makes sense if you think of it - but then most things do in hindsight.)

what you have to do is set up a route to the subnet excluding the one ip address which is the internet connection on the other end. I.E.

route add -host 123.456.789.10 gw <addr of eth0>
route add -net 123.456.0.0/16 gw <addr of cipcb0>

Then everything works!

Thanks for the replies.

Last edited by howlie; 07-29-2003 at 10:20 PM.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
can't route/ping between networks ender03 Linux - Networking 21 02-01-2005 06:14 AM
dhcpcd not adding default route cpsully69 Linux - Networking 2 09-07-2004 09:09 PM
Route to subnet exists but I get "Network unreachable" when adding default route fciuffani Linux - Networking 4 08-18-2004 02:11 PM
Problem with adding default route... Grim Reaper Linux - Networking 1 02-22-2003 07:29 AM
Adding default route on startup? WeNdeL Linux - Newbie 2 01-08-2003 01:00 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration