Operating System - HP-UX
1836589 Members
1458 Online
110102 Solutions
New Discussion

IP Package ocnfiuration with subnet mask

 
SOLVED
Go to solution
Roberto Volsa
Frequent Advisor

IP Package ocnfiuration with subnet mask

Hello,
is it possible to configure a package IP indicating a particular subnet mask?
I need to configure a subnet with is not the default (if you configure SUBNET=10.10.10.0 then the netmask is chooses by default as 255.255.255.0).

Thanks and regards
RV
7 REPLIES 7
Geoff Wild
Honored Contributor

Re: IP Package ocnfiuration with subnet mask

You can configure the subnet in the control script:

IP[0]=10.10.10.0 SUBNET[0]=10.10.10.128

Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Roberto Volsa
Frequent Advisor

Re: IP Package ocnfiuration with subnet mask

This is right Geoff, but i cannot configure a different subnet mask, which is what i need.

RV
Geoff Wild
Honored Contributor

Re: IP Package ocnfiuration with subnet mask

Okay....

Say you need a SM of 255.255.248.0

And your ip you want is 10.10.10.136

That means your Network (subnet) would be: 10.10.8.0

So, in the package config file:

SUBNET 10.10.8.0

And in the control file:

IP[0]="10.10.10.136" SUBNET[0]="10.10.8.0"

And you netmask should be generated correctly - as 255.255.248.0

ifconfig lan2:1

Or whatever your lan card is set to...

Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Stephen Doud
Honored Contributor
Solution

Re: IP Package ocnfiuration with subnet mask

The standard package control script functions do not support adding a relocatable IP with a non-standard subnet to a NIC. Therefore, do NOT list the IP/SUBNET as a parameter pair in the package control script. Instead, edit the customer_defined_run_cmds to ifconfig the particular NIC with the IP/NETMASK that you need. Similarly, you MUST edit the customer_defined_halt_cmds to locate the correct LAN:index value to zero out the assignment when the package halts.
Note that HP has not tested this strategy and therefore does not support it.
Geoff Wild
Honored Contributor

Re: IP Package ocnfiuration with subnet mask

Good call Stephen - probably why I don't do it - the only thing we have is heartbeat networks with differnet subnets - not relocatable ips...

Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Roberto Volsa
Frequent Advisor

Re: IP Package ocnfiuration with subnet mask

Hi Stephen,
the solution seems good.

Only a question now:
1- how to avoid package assign the relocatable IP address

Thanks in advance,
RV
Roberto Volsa
Frequent Advisor

Re: IP Package ocnfiuration with subnet mask

Solution found with stephen suggestion