Moving from external to internal, updating paths?

Discussion in 'macOS' started by dannys1, Dec 11, 2014.

  1. dannys1 Suspended

    dannys1

    Joined:
    Sep 19, 2007
    Location:
    UK
    #1
    Hi guys,

    On my old iMac I used to have a separate 2tb drive before "Fusion drives" become a thing with an SSD for system files.

    I now going to roll my own Fusion with Apples 256gb SSD and a G-tech G-Raid 4tb Thunderbolt external.

    So far so good, the problem is I have a number of files on the seperate drive that were installed as part of installers, most to a new shared users folder. Does anybody know of a way to simply move these to a new single drive and update locations?

    I mean I can't symlink from a location that doesn't exist anymore. I'm assuming its not possible and as each piece of software asks for the location of things i'll just have to update them - but maybe i've missed out on a utility which searches preference files for a location that no longer exists anymore and updates them to a new one? (wishful thinking!)
     
  2. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #2
    That's true, but you can create a new directory at that location, and put symlinks there.

    For example, let's say your external drive was named "Groucho". When it was an external drive, it would normally mount automatically at this location (pathname):
    Code:
    /Volumes/Groucho
    
    Suppose your folder of apps on Groucho is named "Bucket", and it's located directly on the Groucho volume. When the disk is mounted, then, that folder's pathname will be:
    Code:
    /Volumes/Groucho/Bucket
    
    Within that folder let's say you have two apps, named Laurel.app and Hardy.app. Their pathnames will be:
    Code:
    /Volumes/Groucho/Bucket/Laurel.app
    /Volumes/Groucho/Bucket/Hardy.app
    All of this is the state of affairs BEFORE creating the fusion drive.


    After creating the fusion drive, you want to create a new directory here:
    Code:
    /Volumes/Groucho/Bucket
    
    You can do this in Finder or using a single line in Terminal.app:
    Code:
    mkdir -p /Volumes/Groucho/Bucket
    
    I don't think you'll need 'sudo' on that, as I think the permissions on "/Volumes" allow public write.

    You then create symlinks in that directory for:
    Code:
    /Volumes/Groucho/Bucket/Laurel.app
    /Volumes/Groucho/Bucket/Hardy.app
    and point them where they need to point. I assume you know how to do that.

    Since there is now an actual directory in /Volumes named Groucho, if you try to mount a disk named "Groucho", the system should automatically create a non-conflicting name (e.g. "Groucho-1") and mount the disk there, rather than mounting it onto "Groucho".

    You could also just make "/Volumes/Groucho/" a symlink and point it at the directory where "Bucket" is now located. I'm not 100% sure that would prevent the auto-mounting from mounting on top of that node, because I've always done it the other way (make dir in /Volumes, add symlinks therein).


    If that makes sense, then try it and see what happens, using a single app, to make sure it works the way you want. If it doesn't make sense, I suggest trying it anyway. If you have questions about anything, ask again.
     
  3. dannys1 thread starter Suspended

    dannys1

    Joined:
    Sep 19, 2007
    Location:
    UK
    #3
    Hi Chown,

    That's a great answer, I didnt realise you could create folders within /Volumes/ as sort of mock drives. I think that would perfectly do what I wanted. The majority of items are large sample libraries which installed as part of an installer, and a lot of others are not too location dependant so they wont matter. I would probably go for the option you mentioned there of trying to symlink an entire base folder to a new location as I wouldn't mind keeping something like the same file structure i had on that drive, it makes sense.

    Thanks again, i'll give that a go and I'll post back here how successful it was to symlink entire base folder as i'm sure in the future quite a few people might go for having files installed on a second drive moved over to a unified fusion drive.
     
  4. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #4
    Whatever you do, test the result before committing to it.

    You can make a "fake external drive" by creating a disk image file (Disk Utility.app > Make Image). Give it the same name as your external drive, then eject it and remount it. What name does it appear as in /Volumes:
    Code:
    ls -l /Volumes
     
  5. dannys1 thread starter Suspended

    dannys1

    Joined:
    Sep 19, 2007
    Location:
    UK
    #5
    I will, although the only thing that can go wrong really is it wont see the new path, which is the same problem id have if I just move them somewhere else haha.

    I'll give this a shot, you mean, create the folder, and then create a fake external drive with the same folder name to see if OSX safely renames it to -1 or something and doesn't just meltdown?
     
  6. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #6
    Yup, exactly right.

    The idea is to make a simplified test scenario, and discover exactly how it works (or doesn't). This tells you what to expect if you were to commit more time and effort to following that path. By keeping each step simple and reversible, it makes it a lot easier to go back if things don't work out. "The best-laid schemes o' mice an' men..." and all.
     
  7. dannys1 thread starter Suspended

    dannys1

    Joined:
    Sep 19, 2007
    Location:
    UK
    #7
    Yeah, it renames it to /name1 automatically so in theory, symlinking the entire root directory to a new location should work flawlessly. Fingers crossed.
     

Share This Page