Operating System - HP-UX
1752653 Members
5603 Online
108788 Solutions
New Discussion юеВ

System looses default gateway on system reboot

 
William Hill_2
New Member

System looses default gateway on system reboot

I am running a L3000-7X server with HPUX 11.0
every time we reboot the server we lose the default gateway, this can be fixed by using the "route add default xxx.xxx.xxx" command after reboot, I have checked the /etc/rc.config.d/netconf file and it appears to be ok, any suggestions on why this is happening and how we can fix this. Thanks
6 REPLIES 6
Steven E. Protter
Exalted Contributor

Re: System looses default gateway on system reboot

Shalom William,

You can use SAM to set this.

or the set_parms ip_address

or edit /etc/rc.config.d/netconf

GATEWAY=ipaddress of gateway

ex

GATEWAY=192.168.0.254

Do not save an extra copy of netconf in /etc/rc.config.d/ back it up elsewhere. If there are two copies they both get processed.

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
William Hill_2
New Member

Re: System looses default gateway on system reboot

Mr. Protter, enclosed is my netconf file with all the comment lines stripped out

# netconf: configuration values for core networking subsystems

HOSTNAME="ugunhl16"
OPERATING_SYSTEM=HP-UX
LOOPBACK_ADDRESS=127.0.0.1


INTERFACE_NAME[0]=lan0
IP_ADDRESS[0]=xxx.xxx.xxx.xxx
SUBNET_MASK[0]=255.255.255.0
BROADCAST_ADDRESS[0]=xxx.xxx.xxx.xxx
INTERFACE_STATE[0]=up
DHCP_ENABLE[0]=0



GATED=0
GATED_ARGS=""



RDPD=0



RARP=0

ROUTE_GATEWAY[0]="xxx.xxx.xxx.xxx"
ROUTE_COUNT[0]="1"
ROUTE_DESTINATION[0]="default"
DHCP_ENABLE[1]=0
IP_ADDRESS[2]=xxx.xxx.xxx.xxx
SUBNET_MASK[2]=255.255.0.0
INTERFACE_NAME[2]=lan2
BROADCAST_ADDRESS[2]=xxx.xxx.xxx.xxx
INTERFACE_STATE[2]=up



ROUTE_DESTINATION=[4]="net 2.1.0.0"
ROUTE_MASK[4]="255.255.0.0"
ROUTE_GATEWAY[4]="xxx.xxx.xxx.xxx"
ROUTE_COUNT[4]="0"
IP_ADDRESS[3]=xxx.xxx.xxx.xxx
SUBNET_MASK[3]=255.255.0.0
INTERFACE_NAME[3]=lan3
BROADCAST_ADDRESS[3]=xxx.xxx.xxx.xxx
INTERFACE_STATE[3]=down
DHCP_ENABLE[2]=0
DHCP_ENABLE[3]=0
Note: The value for "ROUTE_GATEWAY[0]="xxx.xxx.xxx.xxx" " is the value for my default gateway. Do I still need to add this line to the netconf file
GATEWAY=xxx.xxx.xxx.xxx
Thanks for your help
Bill
Kent Ostby
Honored Contributor

Re: System looses default gateway on system reboot

Check the directory /etc/rc.config.d.

There is a file there called netconf where you can set this information.
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"
D Block 2
Respected Contributor

Re: System looses default gateway on system reboot

William,
double check that there is no other file with similar name: netconf or netconf_blabla.. in the /etc/rc.config.d directory. at times it can pick up a file named "netconfold" before the "netconf" file name.
Golf is a Good Walk Spoiled, Mark Twain.
Chan 007
Honored Contributor

Re: System looses default gateway on system reboot

Edit the /etc/rc.config.d/netconf and add the gateway once again. If you are not sure use sam to that.

Check the permission/owner of /etc/hosts file and add the gateway.

Use netstat -nr to see wheteher it is set on boot.

Sometime people use hexadecimal in it. But use decimal instead.Or you have a typo in it.

Cheers ....007

William Hill_2
New Member

Re: System looses default gateway on system reboot

added gateway entry to the /etc/rc.config.d/netconf file