In Is a 40GB SSD practical to use for ' / ' Jorge describes how he symlinks things in his /home
that would benefit from being on an SSD. How is this done?
I've figured that I need to do the following:
- Create a directory on the SSD to hold what I want to link from
/home
, e.g.mkdir /var/jorge
. - Move the things from
/home
that should be on the SSD, e.g.mv /home/jorge/.config /var/jorge
. - Create the symlinks, e.g.
ln -s /var/jorge/.config /home/jorge/.config
.
Is this the correct way to proceed? Do I need to do it from a live CD?
You can do it from a Live CD, but if you logout from a graphical session and switch to a virtual console using Ctrl + Alt + F1, you'll be able to move the folders too.
Your steps are correct, some expansion below:
Mount the SSD if needed, that can be as easy as:
You can use tab-completion after
/dev/disk/by-label/
. This only works if your partition has a label, otherwise you need to replace it by/dev/sdXY
create a folder that holds the files from home:
If you've a custom umask setting like
0027
, you need tosudo chmod 755 /media/ssd-store
. You can check your umask setting by runningumask
(defaults to0022
)Change the ownership if needed, so the user can always create more symlinks if needed:
Move the files (add
sudo
if you do not own/media/ssd-store/home/jorge
):Create the symlink:
Notes on the above: you should add an entry in
/etc/fstab
for automounting the SSD. Usesudo blkid
to determine the UUID for your SSD partition and add the next line to/etc/fstab
: