How to get programs to install on a different HDD

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Level 1
Level 1
Posts: 4
Joined: Tue Nov 06, 2012 2:58 pm

How to get programs to install on a different HDD

Postby Seltox » Thu Jan 24, 2013 5:40 pm

I just bought a 2nd SSD so I could run Linux off of an SSD as well - but now i'm faced with the problem of not knowing how to keep it clean. In Windows I typically just have Windows itself, and fairly critical programs that run all the time on the SSD, and all the other programs on a seperate HDD. I want to emulate this sort of behavour in Linux, but i'm just not familiar enough with the layout. I'm assuming it would involve relocating wherever the programs are installed (putting /usr or something on a second drive?) but i'm not sure, and don't want to just start fiddling :P

For clarification, it won't be the same HDD Windows program uses. Windows has its own SSD and HDD, as does Linux. Then I have two more HDD's that contain common things (documents, music, etc)

User avatar
Level 6
Level 6
Posts: 1369
Joined: Sun Dec 16, 2012 7:29 pm

Re: How to get programs to install on a different HDD

Postby passerby » Thu Jan 24, 2013 5:49 pm

Create two partitions on the disk you want to install programs on.
Copy /home and /usr/bin to those two partitions, then set them to mount on boot. The one for /home should be much bigger.
(If you haven't done this before, look for a tutorial on moving /home, then follow the instructions for /home and /usr/bin)
AFAIK, most programs are stored in either /usr/bin (programs for all users) or /home (for individual users). There may be a third install location, but not to my knowledge.

If you're able to boot successfully after setting those two partitions to be mounted in fstab, you can boot through a live CD/DVD/USB and delete those directories on the original disk. Only do this after you've made sure they work on the new device though.
Home PC: Xubuntu 14.04 x64, Nvidia GTX650, i7 3770K, 16GB RAM, Asus Xonar DX
Work PC: Mint 13 x64 XFCE, Nvidia GT620, i5 3470, 8GB RAM
Laptop: System76 Kudu Pro, Xubuntu 14.04 x64

My HTML5 login themes + screenshots

Return to “Newbie Questions”