how to add a route to a particular host?

how to add a route to a particular host?

Post by Carl » Thu, 15 Jun 1995 04:00:00



We have a net like this:

   local ethernet -> default router -> machine A
                                       machine B

I'm in the local ethernet, and of course all packets to machines not in it are
directed to the default router. I want to access machine B. The problem is
that the router doesn't know about it; only machine A has B in it's hosts
table. Therefore I must build a route that says that packets to B must be sent
via A. I tried the following:

   route add <ip address of B> gw <ip address of A>

but I get "SIOCADDRT: Network is unreachable". How can I do it? I'm using
1.2.9 and nettools 1.2.0.

Thanks in advance,
Carlos

 
 
 

1. ? route add -host HOST gateway (not directly attached)

Hello All,

Is there any method to tell my clients to use a not-locally-attached
gateway
in order to reach a specific server?

Example: client is on address  a.b.c.5

Gateway host (solaris) is on address  x.y.z.7  and is pingable from
a.b.c.5 through
bunch of other routers.  This gateway also has a second interface with
IP address k.l.m.1

The server I want to reach is on k.l.m.2 address and is pingable from
the gateway.

I don't want to advertise the x.y.z.0 to k.l.m.0 route from my
gateway,
but only to tell  specific clients that they have to use x.y.z.7
gateway
in order to reach k.l.m.2 host

route add -host k.l.m.2 x.y.z.7
obviously says network unreacheable because x.y.z.7 is not directly
attached to
the client's network.

Is there any other way?

Thanks,
Andrei

2. HELP X on MICRON

3. add route, use particular interface

4. status of TB Santa Cruz MIDI/joystick support ?

5. Adding route to host with supernetted mask

6. Linux/Adaptec 1542cf problem (w/ partial solution)

7. cannot add route to local host through loopback

8. list used shared libs tool

9. How many route add entries can I add to Linux (2.0.32) kernel???

10. disksets .... adding and removing hosts ... adding disks

11. Adding Route Add Default to Startup

12. How can i run particular process on particular processor

13. routed adds wrong default route