HP XC System Software Installation Guide Version 4.0

E.2.2 Example 1: Modifying Partitions Using Fixed Sizes and Defining an Additional
Partition
This example applies fixed sizes to modify the default partition sizes on all compute nodes and
creates an additional /scratch partition on each compute node.
The user-defined .part files allow partition modifications to be done on a per-image or per-node
basis.
1. Use the text editor of your choice to create the following file to define the partition format
for compute nodes:
/var/lib/systemimager/scripts/compute.part
The file name must contain the .part suffix. The remainder of the file name can be anything
you want.
2. Add the following lines to the file to create partition sizes based on a fixed size in megabytes.
If you specify the TMP_SIZE variable, another partition is created for temporary scratch
files.
BOOT_SIZE="200"
ROOT_SIZE="6000"
VAR_SIZE="7500"
TMP_SIZE="9000"
The additional partition is mounted as /tmp by default.
NOTE: Use the following variables instead to calculate partition sizes based on a percentage
of disk size:
BOOT_PERCENTAGE=
ROOT_PERCENTAGE=
VAR_PERCENTAGE=
TMP_PERCENTAGE=
The actual size of the partition is based on the size of the disk minus any fixed-size partitions
multiplied by the partition percentage. For each partition, you must specify either a _SIZE
or a _PERCENTAGE variable, but not both. In the following example, TMP_PERCENTAGE="1"
represents 100% of remaining disk space.
BOOT_SIZE="200"
ROOT_SIZE="6000"
VAR_SIZE="7500"
TMP_PERCENTAGE="1"
3. To override the name of the /tmp partition, add the TMP_NAME variable and set it to
something other than /tmp:
TMP_NAME="/scratch"
The /tmp directory still exists, but it remains part of the root partition.
4. Save the changes to the file and exit the text editor.
5. Identify the node names of the compute nodes:
# shownode roles --role compute
n[4-156]
6. Create a symbolic link from the node names of the compute nodes to the newly created
compute.part file. The node name is appended with a .part extension:
for i in 'expand_nodes n[4-156]'
do
ln -sf compute.part $i.part
done
E.2 Dynamically Configuring Client Node Disks 207