centg3
By:
centg3

How can we move /home in ubuntu to a block storage?

September 13, 2017 240 views
Block Storage Ubuntu 16.04

Hi,
I wanted to ask if we can add a block storage and then move /home there.
That's an easy process when installing ubuntu to a laptop with say 2 partitions but is this possible in these mounted volumes?

Thanks in advance

1 comment
  • Suppose inside user's home at the droplet I add a link to a dir in block storage with this user's permissions; is this possible? Php can fopen() with path like link/block-storage-users-folder/some-file? Can we use different filesystems between droplet and block storage? Which filesystem is best for many user's files? Php runs with users permissions NOT www-data or the like.

1 Answer
kenzie September 13, 2017
Accepted Answer

Yeah you can, it's quite simple to do

  • mount your new block storage at let's say /mnt
  • rsync /home over to /mnt
  • delete everything from /home (this is optional to create more space for root partition, MAKE SURE EVERYTHING IS THERE BEFORE DELETING)
  • unmount /mnt
  • mount the new storage with fstab to /home to have it mount on bootup
Have another answer? Share your knowledge.