Due to the lack of the disk space on partitions like / or /var, it's sometimes necessary to move the /var/vmail folder to a larger partition which has more free space and mostly to the /home partition.

You can check the list of your partitions with this command:

df -h

Before moving the emails you should first check the actual usage of /var/vmail with this command

du -hs /var/vmail

Step 1: We advise you stop postfix and dovecot during this process

systemctl stop postfix dovecot

Step 2: copy the vmail folder to the new location

rsync -av /var/vmail/ /home/vmail/

The Above command will copy the folder vmail to /home, so we will have /home/vmail. All permissions will be maintained as well.

Step 3: Backup /var/vmail folder

mv /var/vmail /var/vamil.orig

Step 4: create a symlink from the new location to old location

ln -s /home/vmail /var/vmail

Step 5: start postfix and dovecot

 systemctl start postfix dovecot

You can then test send and receipt of emails. If all is ok, then you can delete the /var/vmail.orig folder to make the space available.