Operating System - HP-UX
1821616 Members
3951 Online
109633 Solutions
New Discussion юеВ

Re: default gateway remains

 
SOLVED
Go to solution
huaxiang
Frequent Advisor

default gateway remains

1уАБcheck routing tables
Destination Gateway Flags Refs Interface Pmtu
127.0.0.1 127.0.0.1 UH 0 lo0 32808
10.1.0.33 10.1.0.33 UH 0 lan1 32808
10.1.0.35 10.1.0.35 UH 0 lan1:1 32808
192.168.10.21 192.168.10.21 UH 0 lan6 32808
10.1.0.0 10.1.0.33 U 3 lan1 1500
10.1.0.0 10.1.0.35 U 3 lan1:1 1500
192.168.10.0 192.168.10.21 U 2 lan6 1500
127.0.0.0 127.0.0.1 U 0 lo0 32808
default 10.1.0.254 UG 0 lan1 1500
default 172.19.252.193 UG 0 lan1 1500
2уАБ remove default gateway "172.19.252.193",vi /etc/rc.config.d/netconf, comment out following:
#ROUTE_DESTINATION[0]="default"
#ROUTE_MASK[0]=""
#ROUTE_GATEWAY[0]="172.19.252.193"
#ROUTE_COUNT[0]="1"
#ROUTE_ARGS[0]=""
#ROUTE_SOURCE[0]=""
3уАБthen /sbin/init.d/net stop & start ,but
4уАБ gateway тАЬ172.19.252.193тАЭ remains
5уАБ OSя╝М 11.31
6уАБwhat's the problemя╝Я

2 REPLIES 2
Solution

Re: default gateway remains

The script /sbin/init.d/net doesn't include any code to *delete* routes - it works at startup obviously cos there's nothing in the table at all then.

To remove this route just run:

route delete default 172.19.252.193

I hope you have some way to connect to the system from other subnets after you run this.

HTH

Duncan


I am an HPE Employee
Accept or Kudo
Steven E. Protter
Exalted Contributor

Re: default gateway remains

Shalom,

You need to reboot your system for instant response.

Lots of network services are using the default gateway. These network services are causing the gateway to remain in memory in spite of the steps you have taken.

You do know your system will not be able to talk to the Internet and also perhaps internal servers when you get this to work the way you want?

The results of this change could be rather catastrophic if you are not careful.

Why are you trying to remove the gateway? Perhaps it would be better to change it.

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