Operating System - HP-UX
1833137 Members
3489 Online
110051 Solutions
New Discussion

no idea how to add a route

 
Mark Burgman
Occasional Advisor

no idea how to add a route

New problem - since I am new to networking across subnets. I have 8 HP-UX 10.2 machines networked together through an intelligent switch. Their IPs range from 129.204.24.101-108. I also have an UPS with an IP of 192.186.20.181. The first method to get these to talk is to login to the UPS with a serial cable, and change the IP of the UPS to put it on the correct subnet, but I have had no success with this. The second option would be to add the necessary routes to the servers to allow them to reach the other subnet, but I am not sure how to do this. I would take a stab at it, except I have a demo in three days, and don't want to risk winging it. Anyone know the correct chain of commands to get my machines talking? Also, if I telnet to the UPS, and then change its IP, what happens to the telnet session?
Thanks in advance...
6 REPLIES 6
Mel Burslan
Honored Contributor

Re: no idea how to add a route

from what you say, I get the point that you are able to telnet to the UPS from one or more of the systems you listed. If this is the case there is connectivity and you do not have to add anything to the routing tables. If I misunderstood you, please provide the out put from command netstat -rn on one of the 8 systems that you have and make sure the output looks pretty much the same on all others.
________________________________
UNIX because I majored in cryptology...
Sanjay_6
Honored Contributor
G. Vrijhoeven
Honored Contributor

Re: no idea how to add a route

Hi Mark,

It is possible to add a route on HPUX but you will need to add that route to a device that knows how to tracelate the ipadress of the source 129.204.24.101 to the network of the destination 192.168.20.181 (a router) If you change the ip-adress of the UPS to e.g. 129.204.24.109 you do not need a router and will be able to communicat with tht UPS direct. So My advice is telnet to the UPS. Change the ip-adress ( You will lose the connection, when the ip-adress changes) and patch the UPS on the same HUP/ Switch the servers are patched on. This way you will be able to communicate direct.

HTH.

Gideon
Jeff_Traigle
Honored Contributor

Re: no idea how to add a route

Is the UPS plugged into the same switch (or at least on the same network segment)?

If so, make sure you have the correct netmask on the UPS when you change the IP address to the servers' subnet. Also make sure the IP address you're assigning to the UPS isn't already in use.

If it's across a router (don't know why it would be, but ya never know), simply changing the IP address of the UPS will not help and trying to add a route probably won't help either... I forget the non-routable private IP address ranges, but the UPS IP address looks suspiciously close to being in one.

As for how the UPS will behave regarding the telnet session once you change the IP address... I would guess it won't actually change until you exit the session. JetDirect and Microplex print servers behave this way.
--
Jeff Traigle
Ron Kinner
Honored Contributor

Re: no idea how to add a route

I assume there is a router somewhere and that the UPS is on a second subnet and not on the same hub or vVLAN/switch. Changing the IP address on the UPS should work except you will need to plug it into the same hub or VLAN or Switch once you make the change. It can't stay where it is. If you plan on adding routes to the HPUX and leaving it where it is then you need to make sure that it has a proper default route (on its own subnet) which will allow it to get back to the HPUX net. Which UPS are you trying to work with? If it's an APC, I have a lot of those and can help you with the config.

As for the HPUX the 10.20 command for a route add is:

/usr/sbin/route [-f] [-n] delete [net|host] destination [netmask mask] gateway [count]

which translates (if you are root) to:

route add host 192.186.20.181 129.204.24.x 1

You shouldn't need the mask but if it insists then put netmask 255.255.255.255 between the .181 and the 129.

where the 129.204.24.x is presumably the router who knows how to get to the UPS.

This will disappear with the first reboot so you really need to edit /etc/rc.config.d/netconf to add the route there too.

If the UPS is already on the same hub/switch and (in the same VLAN if you use them) then you really need to change its IP address to one in the correct range and forget about routes.

The telnet session will drop as soon as the IP address becomes effective but on many devices that doesn't happen until you tell it to save or logout or reboot or some such. If it drops you as soon as you hit enter on the new IP address, move it to the new subnet and try again with the new address.

What is the problem with the serial port login?

Ron

Mark Burgman
Occasional Advisor

Re: no idea how to add a route

Sorry group - I identified the problem.
The manufacturer of the UPS transposed two numbers in the IP address on both units. I told them that an IP address is very much like a phone number - one number off and you get a different person. Once I had the correct IP address, I had much better success. Thanks for all the help though...