The next and last part of our stack is the filesystem layer. This is where the PostgreSQL data will reside, so we need to ensure it's allocated properly. Unlike the underlying LVM layers, the filesystem is not so easily modified.
In this recipe, we will discuss some common formatting options and why we recommend them in addition to necessary commands.
Since this is the last layer in our complete stack, we strongly suggest following all the recipes up to Incorporating the second LVM layer before starting here.
pg1 is our current primary node, follow these steps there as the
- Activate the second LVM volume with this command:
lvchange -a y VG_POSTGRES/LV_DATA
- Count the number of CPUs on the primary node.
- Multiply the CPU count by four.
- If the total in the previous step is less than 256, use 256.
- Use this command to find the Linux kernel version:
- For kernel versions
3.0and above, format the XFS filesystem with this command...