How do i increase web storage on Plesk using Block Storage?
Hi, can someone guide me if there is any possibility to increase the web space by attaching the block storage? I run plesk on my linode, the website files are saved in /var/www/vhosts, i want to increase this storage, is it possible by attaching block storage with some kind of re-partioning ?
2 Replies
@arpit2685 --
Yes…and there's no "repartitioning" necessary…
First, backup your Linode.
- Allocate the block storage volume in the Cloud Manager.
- Attach it to your Linode in the Cloud Manager & note the device descriptor (/dev/sdx).
- Reboot.
- Create a mount point for the block storage volume:
sudo mkdir /blk
- Mount the block storage volume:
sudo mount /dev/sdx /blk
OK, now your block storage volume is mounted at /blk. Do some filesystem operations there to make sure everything is ok…cd there; make a directory; make a file; edit a file; etc. Undo everything so that /blk is empty.
- Shut down Plesk.
- COPY (NOT MOVE) /var/www/hosts to /blk:
sudo cp -Rp /var/www/hosts /blk
(-Rp says to copy recursively and preserve permissions…you must do this or what you end up with in /blk/var/www/hosts will be a giant, hot mess…see warning below).
n.b. You might take a look at your Plesk usage here and copy lower-usage accounts to /blk and leave the higher-usage ones at /var/www/hosts. That's up to you. The block storage volume will have slightly less performance than your normal Linode disc volumes.
- Reconfigure Plesk appropriately: you have to tell Plesk that (some of) its stuff is now at /blk/var/www/hosts instead of /var/www/hosts (see warning below).
After you get done reconfiguring Plesk and are sure that it works properly:
- Back up again.
- Remove any files that are duplicated between /var/www/hosts and /blk/var/www/hosts (see warning below).
After you are satisfied Plesk still works properly:
- Back up again.
If you mess up, deallocate the block storage. Restore your Linode from your backup and start over. Since you only have one snapshot backup available, you'll have to be very judicious in picking the points in the process where you overwrite it (see warning below).
DANGER WILL ROBINSON! DANGER! DANGER!
This is only a rough outline of what's necessary. I don't know anything about Plesk. It may be picky and not even allow you to do this. There are NO guarantees expressed or implied in any of this. You follow this advice at your own risk.
-- sw
@arpit2685 did you have success doing this?