Mount /Users from external drive

Discussion in 'macOS' started by scsjason, Jun 9, 2017.

  1. scsjason macrumors newbie

    Joined:
    Nov 30, 2009
    Location:
    UK
    #1
    Hi,

    I'm looking at configurations for a new iMac and wondering how to balance my storage requirements against speed/cost of an internal SSD. One option is to buy the smallest internal SSD and then move my user data to external storage connected over TB/USB3.

    The simplest way to do this is to mount /Users from the external storage, keeping the OS/Apps on the internal HD. Is this possible in MacOS ?

    --
    jason
     
  2. maculateConception, Jun 9, 2017
    Last edited: Jun 9, 2017

    maculateConception macrumors 6502

    maculateConception

    Joined:
    May 28, 2017
    Location:
    Die Bundesstaat Kalifornien
    #2
    Hi Jason,

    The desired setup you describe is remarkably similar to my current setup on my Macbook Pro, so hope this helps ...

    First, I'll describe my setup which is slightly different from yours. Then, I'll describe, to the best of my knowledge, how to achieve your exact desired setup.

    --------------------- My setup -----------------------

    My thought process was very similar when coming up with distribution of storage. I wanted to have my OS, apps, and frequently accessed/modified (small) files on a quick storage device (SSD), and larger unchanging files on a much larger (but cheaper) device.

    I went with a 250 GB SSD for my main drive, which has OS X and all my applications on it, in addition to coding projects I frequently work on (for fast loading/saving).

    For my larger storage, I went with a 2TB SSHD (hybrid) drive, which I installed in the optical bay (took out the DVD drive, and utilized its SATA connector for a 2nd spinning drive installed in an optical bay caddy).

    Then, I left /Users on the SSD, but created a bunch of symbolic links (using ln -s) to point the various system folders to my larger drive (for documents, movies, pictures, etc), but kept other parts of /Users on the SSD (such as library and desktop). I had to do this via the command line, as Finder wouldn't let me delete the existing system folders (Movies, Music, etc). I had to resort to some sudo rm -rf.

    So, in other words, it is possible to split up your user home directory into 2 parts: 1 directly on your SSD, and the other on your larger storage, via symlinks from the SSD to it.

    To demonstrate my folder structure, this is the output I get from doing an ls in my user home directory on the SSD (note the symlinks).

    MacBook-Pro:~ kven$ pwd
    /Users/kven
    MacBook-Pro:~ kven$ ls -l
    total 48
    drwx------+ 5 kven staff 170 Jun 9 05:43 Desktop
    lrwxr-xr-x 1 kven staff 23 Jun 7 22:52 Documents -> /Volumes/SSHD/Documents
    lrwxr-xr-x 1 kven staff 23 Jun 7 22:52 Downloads -> /Volumes/SSHD/Downloads
    drwx------+ 63 kven staff 2142 Jun 8 16:43 Library
    lrwxr-xr-x 1 kven staff 20 Jun 7 22:53 Movies -> /Volumes/SSHD/Movies
    lrwxr-xr-x 1 kven staff 19 Jun 7 22:53 Music -> /Volumes/SSHD/Music
    lrwxr-xr-x 1 kven staff 22 Jun 7 22:53 Pictures -> /Volumes/SSHD/Pictures
    drwxr-xr-x 16 kven staff 544 Jun 9 02:47 Projects
    drwxrwxrwx+ 6 kven staff 204 May 18 15:54 Public
    drwxr-xr-x@ 2 kven staff 68 Jun 4 05:16 dwhelper
    lrwxr-xr-x 1 kven staff 13 Jun 8 05:50 sshd -> /Volumes/SSHD

    (SSHD is my 2nd and larger drive)

    Now, for your 2nd drive, you could either have it external or use a 2nd internal drive. I don't know if iMacs these days come with an optical drive you can switch out, but if so, then that could be an option. If not, external is fine.

    I've attached an image of this setup.

    --------------------- Your desired setup -----------------------

    You should be able to do exactly what you want - point the whole of /Users/username to an external drive, again through symlinks. Do this in phases.

    1 - First, create a replica of your /Users directory structure on the external drive, without yet pointing your main /Users directory to it.

    2 - Then, go to your main drive, and, in your /Users folder, I think you'll need to rename your existing users directory (not sure if Finder will allow it, but you should be able to do it with sudo on the command line).

    3 - Finally, create a symbolic link to the external /Users/username folder, on the main drive under /Users. So, you will then have something like this on the main drive.

    Contents of /Users:
    username_renamed (your old user home directory, renamed so that it doesn't conflict with the new symlink below)
    username -> /Volumes/ext_drive/Users/username (a symbolic link to the directory on your external drive)

    I haven't tried this exact setup before, but I'm sure others have.

    ------------------------ A word of caution -----------------------

    If you decide to have your user home directory entirely residing on an external drive, if that drive then got physically disconnected, unmounted or ejected unexpectedly, the system might crash/freeze because it is not able to access your user home directory.

    So, I would avoid putting the whole users directory on an external drive, unless you're absolutely sure that it will remain reliably connected the entire time. If it does get disconnected for whatever reason, you may experience serious issues, I would think.

    Alternatively, go with my approach, pointing parts of your users directory to the external drive but having your main users directory physically residing on your main drive. Or, use an *internal* 2nd drive for the user home directory, as opposed to an *external* drive.
     

    Attached Files:

  3. scsjason thread starter macrumors newbie

    Joined:
    Nov 30, 2009
    Location:
    UK
    #3
    Thanks for the response. I had thought about sym links, but just wondered if there was a way of doing it similar to Linux, using mount to mount /Users from a different drive into /Users. There could be a /Users on the internal disk to allow login if the external disk is in-attached, and mount would just replace it when all was working well.

    As you say though, if the external disk un-mounts while the system is running, could cause issues and every time I think I've found a good external disk I see a review by someone complaining about it in-mounting itself.

    Guess I'll just buy the fusion drive and live a simple life :)

    --
    Jason
     
  4. Alrescha, Jun 10, 2017
    Last edited: Jun 10, 2017

    Alrescha macrumors 68020

    Joined:
    Jan 1, 2008
    #4
    It is possible, but as pointed out above, the OS might not react well to that volume going away should the external drive get disconnected.

    An alternative is to change the home directory of just your user account. An accidental disconnection will still not be pretty.

    Personally, I leave everything the way OS X installs and I just keep my bulk data on the external drive. Apps like iTunes and Photos are perfectly happy with their data on /Volumes/MyExternalDisk. I have not been moved to create symlinks.

    A.
     
  5. Fishrrman macrumors G4

    Fishrrman

    Joined:
    Feb 20, 2009
    #5
    OP wrote:
    "One option is to buy the smallest internal SSD and then move my user data to external storage connected over TB/USB3."

    I believe this is a good strategy, one that I will do myself if I buy another iMac (still using one from 2007!).

    I'd get either the 256gb SSD (adds $100) or the 512gb SSD (adds $300).

    Then, I'd add a USB3 external SSD (they're not all that expensive) of, say, 480gb.

    Yes, it "adds another drive icon" on the desktop to manage, but I PREFER to keep my stuff "spread around" without all the data "in one basket".

    Also -- since the new iMacs have USB-c, you could get a USB3.1 Gen 2 external SSD. These run VERY fast (2x the speed of USB3). Probably little discernible difference from the built-in storage for most uses.

    Why pay Apple $700 smackeroos for -their- internal 1gb SSD??
    I guess some folks have money to toss away.
    I don't...
     

Share This Page