[SOLVED] How to config route from nic B>C so A can talk to D
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How to config route from nic B>C so A can talk to D
Right this is not really LInux so please forgive me, although it would be no different if it was pure linux, and NO other damn site seems to have an answer and i can't be the first person in the world to try this. So im hoping you guys can rock my world.
Here is the million dollar problem:
Quote:
I have an issue with some traffic routing i can't quite figure: i'll try map out blow what im aiming to do.
Machine A || Machine B (Win 2008 R2) || Machine C
Start: 192.168.5.9 > 192.168.5.5 (NIC 1) - 10.14.137.113 (NIC 2) > 10.14.137.128
So the question is how do I get traffic from Machine A to Machine C. I've tried various 'Route ADD' cmds but no luck so far. So was hoping someone out there could shed some light for me?
Machine B is a AD/DNS and can talk to the entire 10.14.137.x range but has no forwarders set up in DNS. And does not act as a AD/DNS server for the 10.14.137.x range. It fills these roles only for the 192.1668.5.x range. It also has RRAS installed already.
So far machine A can talk to NIC 2 on machine B via
So i had tried something like that. and yes it allow traffic from 192.168.5.9 > 10.14.137.113 but nothing goes beyond it can't figure it out. So im still in the same situation it seems if the destination is set as 10.14.137.128 but it first has to route via 192.168.5.5 then via 10.14.137.113 there is a lose of direction. So i need to figure out how to tell all packets destined for 10.14.137.128 from 192.168.5.9 that there are two ports of call: 1st: 192.168.5.5 2nd: 10.14.137.113.
Are you trying to make your server act as a router? If so, have you done a RIP configuration? Here is one tutorial that explains it quite well.
For a better support maybe you should paste the routing tables of the 3 machines.
Tutorial helped i wasn't aware of that step. I have now done that. Still not getting the traffic going across here are the routing table to help figure this out. There are no firewalsl on machine A, B or C.
I have attached the routing tables as pngs (sorry for the incovenience could not copy/paste em in here.) also haven't bothred with Machine C's as i only need traffic to go from A-C
Machine A || Machine B (Win 2008 R2) || Machine C
Start: 192.168.5.9 > 192.168.5.5 (NIC 1) - 10.14.137.113 (NIC 2) > 10.14.137.128
It seems to me that your machine B (the black background?) has the wrong subnet.
At least you don't seem to have a route to machine C.
it says 10.14.137.113 is host only (255.255.255.255). So the default routing will be used, which doesn't send the data to machine C.
either change the subnet or add a route for 10.14.137.128.
And you do need a route back from C over B to A, so that A can reply. You won't be able to establish a TCP connection if C can't answer,
the the routing in C is important as well.
In my opinion this isn't a routing question because server knows its subnet. If you had, say 1.2.3.4 then the server didn't know which interface to send from, so it needs help (routing)!
This is a forwarding issue; RIP or NAT should solve your problem. I find very odd that you didn't manage to get it working with dynamic routing in WS2008 by using RIP. Try NAT instead: here.
Anyway, let's see a "talk" between systems:
Code:
A:
192.168.5.9
B:
192.168.5.5
10.14.137.113
C:
10.14.137.128
User at A issue "ping 10.14.137.128":
A: Do I have any route to 10.14.137.128? > No
A: What is my default gateway? > Default gateway: 192.168.5.5
A: Send icmp through 192.168.5.9 to 192.168.5.5
B: Received icmp packet from 192.168.5.9. Where to? > 10.14.137.128
B: Do I have any route to 10.14.137.128? > Yes
B: What is route to 10.14.137.128 > 10.14.137.113
B: Send icmp through 10.14.137.113 to 10.14.137.128
C: Got icmp ping packet for me from 192.168.5.9. Have to answer back. Send icmp answer to 192.168.5.9
C: Do I have any route to 192.168.5.9? > No
C: What is my default gateway? > Default gateway: 10.14.137.113
C: Send icmp through 10.14.137.128 to 10.14.137.113
B: Received icmp packet from 10.14.137.128. Where to? > 192.168.5.9
B: Do I have any route to 192.168.5.9? > Yes
B: What is route to 192.168.5.9 > 192.168.5.5
B: Send icmp through 192.168.5.5 to 192.168.5.9
A: Got icmp ping answer packet for me from 10.14.137.128. Done.
So, since A and C have default gateways, only B server needs to know where to send packets.
The route table in your screenshot is incomplete. Above the table are interface parameters. You will need to match the id's with the interface. In this example interface 0 means subnet that contains A and interface 1 means the other (if 0 and if 1, respectively):
Code:
route -p add 10.14.137.128 mask 255.255.255.255 10.14.137.113 if 1
route -p add 192.168.5.9 mask 255.255.255.255 192.168.5.5 if 0
Hope it solves.
Last edited by Joaquim Almeida; 09-27-2012 at 08:16 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.