Are junctions affected if the drive is formatted?

Posted on

QUESTION :

I was trying to relocate my user profiles, so that they are not affected by any problems occuring in the drive on which the operating system is stored. I’ve managed to move user profiles using Robocopy and then used junction points:

Robocopy C:Usersuser1 E:Directoryuser1 /E /R:0 /DCOPY:T

mklink /J C:Usersuser1 E:Directoryuser1

If, for some reason, I had to reformat my C: drive, would that affect the junction points created? If so, what do you recommend I do?

ANSWER :

Formatting a volume means its entire file system is created from zero. Files, directories, junctions, symlinks are equal in that they are file system objects, and they disappear the same way. If you format C:, the C:Usersuser1 junction will have to be mklink‘d again.

The target of the junction is not affected in any way – after all it’s located on a different volume, E:.

After re-installing the OS, follow these steps:

  1. Use the same username(s) & Drive letters
  2. Create the junction again: mklink /J C:Usersuser1 E:Directoryuser1
  3. Reboot
  4. Delete C:Users

Leave a Reply

Your email address will not be published.