Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

[Tutorial] Moving a Unity installation to a separate drive or partition

Discussion in 'Editor & General Support' started by FuzzyQuills, Oct 10, 2017.

  1. FuzzyQuills

    FuzzyQuills

    Joined:
    Jun 8, 2013
    Posts:
    2,871
    2021 Update: With the existence of Unity Hub, this method of moving installations is irrelevant. These instructions may still be useful for those who decide for whatever reason to install Unity separately outside of using the Hub, especially older Unity versions made before the existence of Hub!

    Hello guys, not sure where to actually put this, so if someone can move it, that would be great.

    With that out of the way, I'm putting this here for those who for some reason need to move their unity installation to a different drive on the same PC. (This guide assumes you're using Windows x64)

    The first step is actually moving the entire install folder to the new location. Easier said than done however, as attempting to open a project may result in "nonexistent playback engines" and a few other errors/warnings in the console. I got this after moving my Unity install off the C: drive onto my D: drive so Windows 10 could update properly, (Unity was taking 3GB of space) and through trial and error (and some hints from some googling) I found how to reset all the paths after moving.

    So, to the fixes: The first involves the registry; Win+R, type regedit to open the registry, navigate to the following key "HKEY_CURRENT_USER\Software\Unity Technologies\Installer\Unity" (or just find the path with Ctrl+F) and in there is an entry in there called "Location x64"
    Right-click, modify and type the new install directory path into Value Data. Close regedit when done.

    The second thing you need to do is to navigate to C:\ProgramData\Unity (you'll need "Show hidden files" turned on) and delete the file "index-local.xml" (This folder also where the license file is located, so be careful going into this folder!)

    Now, you can open unity, and start developing again no issues. It fixed mine when I ran into that snag after moving the installation. It also makes me wonder why relative paths still aren't a thing in some Windows programs in 2017.

    Thought I'd put this out there, as the other fix is to reinstall Unity, which can take a whole lot longer. I'll keep this post updated if I find any more cases with fixes.
     
    Last edited: Jun 17, 2021
    diwang, nar3n12, augustcero and 3 others like this.
  2. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    14,446
    The recommended approach is to use the Unity installation process. You can have multiple versions of Unity on the same system, just install to different locations.
     
  3. FuzzyQuills

    FuzzyQuills

    Joined:
    Jun 8, 2013
    Posts:
    2,871
    This guide is for moving ONE installation to a different drive however, I don't mention multiple installs anywhere...

    I mostly wrote this for people that want to move the install folder without manually uninstalling then reinstalling again, which takes longer.
     
  4. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    14,446
    Got it! i missed that, I guess I get caught up in installing multiple versions for testing, and overlooked the advantage of being able to move a single instance
     
    FuzzyQuills likes this.
  5. ColdMud

    ColdMud

    Joined:
    Jul 12, 2017
    Posts:
    3
    Awesome, thanks!
     
    FuzzyQuills likes this.
  6. FuzzyQuills

    FuzzyQuills

    Joined:
    Jun 8, 2013
    Posts:
    2,871
    Hope it works for you. :)
    Kinda forgot I wrote this tbh, happy someone's able to use it.
     
  7. PolyMad

    PolyMad

    Joined:
    Mar 19, 2009
    Posts:
    2,324
    Thank you for sharing the solution.

    A question: why would you move the existing installation folder and not re-install Unity?
    I would like to move the Unity folder for a simple reason: the layouts I have, I love them and I don't want to waste time setting them up again.

    Another question: I see this "HKEY_CURRENT_USER\Software\Unity Technologies\Installer\Unity"
    What about different Unity versions?
     
  8. PolyMad

    PolyMad

    Joined:
    Mar 19, 2009
    Posts:
    2,324
    OK, I just COPIED the Unity folder from an external drive (where I installed due to lack of space on C) to the main C drive (new arrived yesterday).
    I renamed the OLD Unity folder so that it couldn't be referred anymore by anything and launched from the new copy.
    It all SEEMS to work fine.
     
  9. tetriser016

    tetriser016

    Joined:
    Jan 3, 2014
    Posts:
    100
    OK, apparently there's no index-local.xml in the ProgramData/Unity folder at my end. (I have hidden files visible all the time)

    Will it work just fine or I have to find it elsewhere?
     
  10. xxmark71xx

    xxmark71xx

    Joined:
    Dec 5, 2020
    Posts:
    4
    Thank you for lifting the curtain! Much easier than re-installing, considering I wanted my engine to be on the same drive as the rest of my projects! Thanks again!
     
  11. FuzzyQuills

    FuzzyQuills

    Joined:
    Jun 8, 2013
    Posts:
    2,871
    It could have changed as last time I wrote that, Unity 2020 didn't exist, which version are you trying to move?
    Honestly surprised this got revived as I haven't actually worked with Unity an awful lot since 2018.
    Only opened the forums today to have a peek on what was going on.
     
  12. diliupg

    diliupg

    Joined:
    Jan 23, 2018
    Posts:
    45
    Unity appears to be a standalone installation not tied up to any serious system files so it seem to not matter where the installation and all necessary are as long as the UNITY HUB knows where the installations are.
     
  13. FuzzyQuills

    FuzzyQuills

    Joined:
    Jun 8, 2013
    Posts:
    2,871
    I wrote this guide before Unity Hub existed, so honestly, these instructions likely aren't applicable anymore. I'll edit the original post.
     
  14. diwang

    diwang

    Joined:
    Sep 14, 2015
    Posts:
    30
    Hello , i followed all your step , and opened unity from unity hub , but i still got the playback error , is there any fix to this ? my unity version is 2018.3.0f2 upload_2021-7-10_20-51-52.png

    Edit : i deleted the index-xml in C:\ProgramData\Unity but it does not fix the problem . Re-opened unity and the index-xml does not reappear in the folder either , so i give up i uninstalled the unity 2018 editor , maybe this is the time to install unity 2021 after all.
     
    Last edited: Jul 10, 2021