1833041 Members
2588 Online
110049 Solutions
New Discussion

route destination

 
Isaac_4
Frequent Advisor

route destination

Hi

I Have some problem when try to make static route for a new network for my server

Now my server have ip address 199.41.60.8 my default route is 199.41.60.5 (router). But I have other router to take way to the new network (7.108.8.0)199.41.60.10.
The command used to add the static network:

route add net 7.108.8.0 netmask 255.255.255.0 199.40.60.10

The problem is that can`t ping any host in the network 7.108.8.23 for example.

Some one can help me

Thank you
The time is gold
9 REPLIES 9
Sundar_7
Honored Contributor

Re: route destination

hmm...were u able to successfully add the route ?

route add net 7.108.8.0 netmask 255.255.255.0 199.40.60.10

I believe you should mention the count as 1.

route add net 7.108.8.0 netmask 255.255.255.0 199.40.60.10 1

Execute the above command try ping
Learn What to do ,How to do and more importantly When to do ?
Sridhar Bhaskarla
Honored Contributor

Re: route destination

Hi,

You will have to specify the 'metric' at the end of your route statement. The metric is the number of hops your system has to make to reach the router. Since 199.41.60.10 is on the same subnet as of your system, then the metric to use it 1.

So, modify your route statement as

route add net 7.108.8.0 netmask 255.255.255.0 199.40.60.10 1

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Isaac_4
Frequent Advisor

Re: route destination

Yes, Im use the 1 in the end offline but I have same problem.

My O.S. is HP-UX 10.20. Exist some way to add two Default Gateway`s in my Hp9000.



The time is gold
Steven E. Protter
Exalted Contributor

Re: route destination

default means just that. system looks there first.

The route add statement lets you add other destinations other than the default. Letting you connect to different routers.

The goal of two default routers sounds to me like split brain. I can't look two places first. I can try gateway one(default) first and then i can try gateway two.

The ping problem may just be that someone disabled ping on one of the routers. Perhaps a different connectivity test is called for.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Sundar_7
Honored Contributor

Re: route destination

Nope, you cannot add two default gatway IP addresses. Do a traceroute to 7.108.8.23 and find out the problem in the route.

Learn What to do ,How to do and more importantly When to do ?
Sundar_7
Honored Contributor

Re: route destination

ermm.. I always thought default route is the last route that is checked , not the first route ?
Learn What to do ,How to do and more importantly When to do ?
Sridhar Bhaskarla
Honored Contributor

Re: route destination

HI Issac,

I would check how the route is taken.

DO,

traceroute 7.108.9.23

If you don't have tracroute (I don't remember for 10.20) use ping with -o option

ping -o 7.108.9.23 -n 2

IT should take you through 199.41.60.10. If it is stopping after it, then you will have to check with your network people on how that route is setup.

Post your 'netstat -rn' and someone may be able to assist you.

You *cannot* have two default gateways. You specify "default" instead of 'net xx.xx.xx.0' while adding route statement for the default gateway. Rest of the routes will be static routes as you have added.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Jorge Peinado
New Member

Re: route destination

Hi,

If HP-UX runs IP routing as is supposed to be normal (i hope :)) the default route is the last route checked.

Also, it MUST (in theory) be possible to add a second route to the same destination with metric greater (or lower) than other configured. Simply, the IP driver MUST checks first the lower metric route, and if it's unsuccessful, take the other.

In the scenery you are describing, maybe the other router MUST reply to the HP-UX box an ICMP-redirect pointing to the default router, if this router point to the default to reach the network.

¿Can you see an incoming ICMP? (the only tool i know in HP-UX to see this will be tcpdump) Also, maybe some firewall is dropping ICMP traffic.
Try also the traceroute. Check also(if you can) the routes to the network in both routers.

BR,
Jorge.
Ron Kinner
Honored Contributor

Re: route destination

Since the 7.108.8.23 is new the odds are that it does not know how to get back to the 199.40.60.0 network. A ping won't work if the destination has no route back to the source.

traceroute worked as expected back in 10.20 so you should be able to do

traceroute 7.108.8.23

and should get replies from 199.40.60.10 then from the next hop then the next. The problem is then usually in the hop that doesn't answer (assuming that the last hop knows where to send the packet to). Assuming that the traceroute runs ok until the last router before the 7.108.8.23 then do a
netstat -rn
on the 7.108.8.23 and you will probably see that it is lacking a route to return to the 199.40.60.0 and its default (if any) point off a different way.

traceroute is usually in /usr/sbin so if it pretends not to have it do
/usr/sbin/traceroute 7.108.8.23

You can also trace to the 7.108.8.x interface on the last router before the 7.108.8.23 if you know it. If that works then you know it's a missing or wrong route in the 7.108.8.23 or it has been told not to respond (running a firewall like Zone Alarm or XP's builtin ).

Other possibilities are a filter or firewall in the network which don't allow ICMP.

Ron