How to Transfer/Move Vhosts in Plesk to Utilise Extra Storage

How to Transfer/Move Vhosts in Plesk to Utilise Extra Storage featured image

Let’s imagine, for a moment, you inherited – or setup – a dedicated server which runs Plesk version … whatever … and attached to that server you have some mounted storage.

All of your websites are taking up the space, though, and you want to move the entire virtual hosts, contents, and whatever into your mounted storage area, to free up space.

Easy, right?

Well, not so easy as a cp from one to the other, as you also need to tell Plesk where everything has gone, and what to do in future (i.e. you need to touch a few tables and configurations). Luckily, there’s a script for this, which will do all of that, from the Plesk makers, Odin, which makes all of this happen in a Python-y way.

Find the script here.

This script is called transvhosts.pl.

You will want to call it using something like:

perl transvhosts.pl --dest-dir /my/destination/folder/ --correct-scripts

The above you should replace “/my/destination/folder/” with the path to the actual destination folder you want. For us, it is often something like “/mnt/storage/www/” or similar, as we’re booting things off to a mounted Raid array or suchlike.

This script will take some time to complete. It will be longer the more you have in your folder.

Leave a Reply

Your email address will not be published. Required fields are marked *