Configuring and Migrating Memory on vPars

14
Memory Allocation and Binding Live Database
Once booted, the vPars monitor maintains a memory copy of the file database. Any resource
modification to the partition in this live database is validated against the available resources. Hence,
when ILM or CLM memory is added, the vPars monitor checks whether the requested amount is
available. If not, the system administrator knows when the vPars command returns if the memory
allocated is less than the requested amount.
When a partition is down, the allocated memory indicates the amount, type, and locality of memory
that has been reserved for it. It does not indicate the actual address ranges that will form this
allocated memory. The memory granules that make up the address ranges are bound to the partition
when the partition is booted. Hence, when the partition is down, the vparstatus v output only
indicates the amount of memory reserved to the partition. When the partition is live, the output (only
in A.04.xx and A.05.xx vPars releases) contains the actual address ranges that form the amount of
memory. To bind granules, the vPars monitor starts from the low address end of each ILM and CLM
memory type and binds the available granules for base memory first and then binds the granules for
floating memory. The vPars monitor binds the base memory at the low end because during early boot
firmware and HP-UX kernel allocates memory at the low end for contents that they cannot evacuate.
When the partition shuts down, the binding between the granules and the partition is removed. The
next time the partition boots, it is not guaranteed that the partition will get same granules and hence
the address ranges.
For example, as shown in Figure 3 in Memory Granules Chapter, when vpar1 is booted first, the
monitor starts from low end of ILM and CLM on cell 0 and binds the first available granules to base
and then binds the floating granules. When partition vpar2 is booted next, monitor binds the ILM
granules above vpar1 ILM granules as base followed by floating. Figure 4 below shows what
happens when both vpar1 and vpar2 are shutdown and then vpar2 is booted first and then vpar1.
As can be seen the granules and hence the address ranges vpar1 and vpar2 get are different
because the binding is removed when partitions go down and a rebinding is done based on the
available granules at the time the partition is booted.
Figure 4. Change of Address Ranges after Reboot
When a partition is live, the allocation is immediately followed by binding during memory add.
Similarly when memory is deleted, the unbinding of the granules is followed by a reduction in amount
of memory that the partition owns. During add, the vPars monitor starts from the low address and
binds the available granules as each command option is processed. Then the HP-UX kernel in the
partition adds these memory ranges to its usable physical memory. During deletion, the vPars monitor
passes the amount of memory specified to the HP-UX kernel and the HP-UX kernel selects the granules