Operating System - HP-UX
1837245 Members
4834 Online
110115 Solutions
New Discussion

Re: Need command to save config

 
Radcliffe Harewood
New Member

Need command to save config

The HPUX server had no IP address. I found out how to add it via google and entered the following from a command line.
ifconfig LAN0 205.86.18.4 netmask 255.255.255.0.
Then I was able to ping the server. I need to reboot the server to see if the address is saved.
9/29/09 - Rebooted server. IP config was not saved. Need someone with HPUX expertise to assist.


How do I save the config after assigning the IP address?
9 REPLIES 9
Robert-Jan Goossens
Honored Contributor

Re: Need command to save config

Hi,

You can use the set_parms script to set or change the ip-address of the system.

# set_parms ip_address
or
# set_parms initial

Regards,
Robert-Jan
Md. Farhan A Azam
Trusted Contributor

Re: Need command to save config

Hello,

You can put IP address details in "netconf" file, as below...

To check..
#more /etc/rc.config.d/netcof

To put IP address details..
#vi /etc/rc.config.d/netconf



thnx...farhan
Md. Farhan A Azam
Trusted Contributor

Re: Need command to save config

Sorry typing mistake...



To check..
#more /etc/rc.config.d/netconf

To put IP address details..
#vi /etc/rc.config.d/netconf



thnx...farhan
Radcliffe Harewood
New Member

Re: Need command to save config

Tried using set_parms ip_address. While it set the IP address that I wanted it to, it doesn't seem to have assigned it to LAN0. So I'm still unable to ping across my network. When I use ifconfig LAN0 205.86.x.x netmask 255.255.255.0, it works fine, but goes away after a reboot. I don't know how to use VI editor. Any other suggestions?
Horia Chirculescu
Honored Contributor

Re: Need command to save config

Hello, Radcliffe, Farhan A Azam has pointed you on the right direction. All you need to do is first learn something about vi and afther that you must edit the netconf file.

Other way to do that is to use SAM. (Just type sam when logged in as root). You would get a menu-based administration software. Here you can use TAB and arrows to browse the menu/make the necessary modification. (go to "Network Interface Cards", select the desired card -lan0/whatever, use SPACE to select- and then use the "Actions menu" - use TAB for this menu)

Best regards from Romania,
Horia Chirculescu
Best regards from Romania,
Horia.
Md. Farhan A Azam
Trusted Contributor

Re: Need command to save config

Hi,

when editing "netconf" file through vi editior, you will get lines as below, put the entry as per your requirement:-

INTERFACE_NAME[0]="lan0"
IP_ADDRESS[0]="10.56.0.8"
SUBNET_MASK[0]="255.255.255.0"


ROUTE_DESTINATION[0]="default"
ROUTE_MASK[0]=""
ROUTE_GATEWAY[0]="10.56.0.1"
ROUTE_COUNT[0]="1"

OR you can go through SAM also.

thnx...farhan
Suraj K Sankari
Honored Contributor

Re: Need command to save config

Hi,

The easiest way to configure LAN is SAM.

Suraj
Radcliffe Harewood
New Member

Re: Need command to save config

Thanks guys,

This look helpful. I'll give it a try today.

What is SAM? And how do I access it?
saber_lahlib
Occasional Advisor

Re: Need command to save config

Hello,

SAM ==> System Administration Manager


You can use in the shell this :

#ch_rc -a -p IP_ADDRESS[Y]=XXX.XXX.XXX.XXX -p SUBNET_MASK[Y]=XXX.XXX.XXX.XXX -p INTERFACE_NAME[Y]=lanX -p INTERFACE_STATE[Y]="up" -p BROADCAST_ADDRESS[Y]=XXX.XXX.XXX.XXX /etc/rc.config.d/netconf


Y is the interface number