ClearOS 6 may not configure your partitions automatically in a way that you want if you simply choose the default geometry when you initially install. This guide can help you manipulate the partitions during the initial install to reflect what we consider to be good practices for ClearOS. If you have completed the installation and are not happy with the way you've laid out the paritions, ClearOS uses LVM and you can still manipulate many aspects to optimize your use of storage.
During the installation you will be presented with the ability to choose a custom partitioning scheme, select this option (Create Custom Layout).
At the disk provisioning wizard, select Create.
For single drive systems, select Standard Partition and choose Create. For multiple drive systems, you will choose RAID Partition because you will want your /boot partition spread across all devices.
You will specify the following for the options:
We will create the last two partitions as LVM Physical Volumes. Select Create, choose LVM Physical Volume and then click Create.
Make the first volume 51200 in size and click OK. (You can make it bigger but the OS aspects of ClearOS should not exceed 50 GB. If it does, you are doing it wrong.
Do the same for the next partition but set the size to 20480. Don't worry about the extra space right now. LVM is EASY to make bigger. It is harder to make partitions smaller though. At the end your partitions structure should look like this:
All the rest of the partitions will reside under the LVM structure. We will set up the core OS on the first LVM partition and we will reserve entire last LVM partition for user data (Flexshares, home directories, websites, databases, mail directories, proxy cache and others)
Highlight the first LVM partition and select Create. Select LVM Volume Group and click Create.
Call the volume group 'main' and select ONLY the first device (in this case sda2, the one that is 51200.00 MB in size.) Deselect any others. Click Add and we will make our first Logical Volume within this volume group called 'main'. Set the following options:
Click OK. Repeat the process by clicking Add until all the Logical Volumes for this Volume Group are added:
Once you are done adding all the Logical Volumes, your layout should look like this:
Click OK. The overview should look like this:
Time to make the last Volume Group for the user data. Click Create then select LVM Volume Group and click Create.
There should be only one Physical Volume left and it should be checked. Name the Volume Group 'data0' (data0 is the reserved name for the user data partition on ClearOS that is LOCAL to the machine). In the logical volume section Add a new Logical Volume with these options:
Your final layout should look like this:
Click Next and you should get a warning about formating the drive and a prompt to “Write changes to disk”. Click Format and Write changes to disk:
Finish off by installing the boot loader to /dev/sda. It should look like this:
From here the server will continue the install. As you add apps from the Marketplace, you will want to set the data partition to be the volume which contains the user data. This will prevent your OS disk from filling up. More importantly, if you need to reinstall you system, you can reformat all the drives EXCEPT the user data volume group. You'll thank me later.