1834736 Members
2955 Online
110070 Solutions
New Discussion

Change default Route

 
Nicky_5
Regular Advisor

Change default Route

Hi,

I am in the middle of changing IP, netmask and default gateway. I changed the 1st 2 through SAM and i lost connectivity, and since i had not changed the default gateway, i was not able to connect. The machine does not even have a console

Now i am somehow logged on to the machine, but the sam=== network& communications options does not show me the "routes" option.

Please tell me how i can change the default gateway.

3 REPLIES 3
Nicky_5
Regular Advisor

Re: Change default Route

Hi,

I have managed to do this bu set_parms
but now the netstat -r shows 2 default gateways... please advice/...
RAC_1
Honored Contributor

Re: Change default Route

Logon to console.

/sbin/init.d/net stop;/sbin/init.d/net start

netstat -in

What does it show now?? Are files /etc/hosts and /etc/rc.config.d/netconf OK??
There is no substitute to HARDWORK
John_975
New Member

Re: Change default Route

Take a look at the man page for "route" and "netstat". As you've already noticed you need to be very carefull when changing the default route if you are using a remote connection to access the system.

Run "netstat -rn" to see what if any default routes you have configured. If you don't like it delete it with:

route delete default

Be carefull!!!!

Add new route with:
route add default [optional netmask] 1
- this assumes the gateway is part of you local network.

To make these changes permanent you need to update /etc/rc.config.d/netconf. Otherwise you changes will be lost when you reboot the system.