Applicable to:
- Plesk for Linux
Question
How should hard drive be partitioned for Plesk Linux installation?
Answer
Plesk for Linux OS stores user data in the directory /var
, by default, so the partitioning should be set up as follows:
CONFIG_TEXT: SWAP -> Refer to the OS vendor recommendation (usually at least the amount of RAM on the server times two).
/ -> 20GB minimum, 50GB recommended. This partition is used for the OS and Plesk updates.
/tmp -> At least 3GB recommended.
/var -> the rest of the space (domains, mail, backups, and databases are stored there)
Note: it may vary. The /usr/local/psa/tmp/
directory (for domains backups) as well as the /usr/local/psa/PMM/tmp/
one (for full server backups) are used as a temporary placeholder for backups. For instance, when downloading a backup file via Plesk GUI, a temporary file with the same size is created in those locations.
Directories, that usually contain large amounts of data, include:
-
/var/www/vhosts
- domains content -
/var/qmail
- mail configuration/content -
/var/lib/mysql
- MySQL databases -
/var/lib/psa/dumps
- Plesk client/domain backups -
/var/lib/pgsql/data
- PostgreSQL databases -
/var/lib/mailman
- Mailman lists
The file /etc/psa/psa.conf
defines other directories used by Plesk.
On Debian and Ubuntu, Plesk files are located in /opt/psa
directory.
More information about partitioning can be found through the following links:
Comments
4 comments
This resources are too small, servers run out of spaces in 1 month
@iamkingsleyf
In this article there are only recommendations how to partition hard drive for Plesk server.
Additionally to find the top files consuming the disk space use the following command:
du -ah /var | sort -n -r | head -n 5
These are terrible instructions! It wasted a lot of my time. You can't even upgrade Centos with a boot partition that small. Here's what your figures should be!
SWAP - unless you are critically under supplying RAM half not double of your RAM is enough...
/boot - 256MB !!
/ - 15 to 20GB (recommend larger if you have the room)
/tmp - 4GB
/var - the rest, as much as you can...
Also, if you configure using LVM, resizing (up or down if you use ext4) is easy and fast. BUT you can't LVM /boot and since it's the first partition on the disk, having it undersized is a real pita so make sure you use 256MB !!
Rant out. Hopefully useful to someone else...
Hello @ziegi
Thank you for your input, the article has been updated.
Please sign in to leave a comment.