Reparse Points Solve Path Problems

Some folder paths changed between Win2K and NT, which led to a problem for an NT program with hard-coded paths and no source code. Here’s how a reader solved this problem and was able to run the NT program under Win2K

Apostolos Fotakelis

June 27, 2005

1 Min Read
ITPro Today logo

We have a program at work that manages users' profiles. This program had been developed to work under Windows NT 4.0, whereas we needed it to run under Windows 2000. When we tried to use it with Win2K, we ran into a problem: The program was hard-coded to use the C:WinntProfiles path and offered no way to configure it to use the C:Documents and Settings path. Unfortunately, the original developer had left the job, and there was no source code for this program.

After searching the folder in which I keep all my administrative tools and utilities, I found the right tool for the job: Sysinternals' Junction (http://www.sysinternals.com/
ntw2k/source/misc.shtml). This command-line program creates reparse points to NTFS-formatted hard disks. You first create the folder you want to appear as the "real" one (C:WinntProfiles, in my case), then run Junction following the syntax

junction   

In my case, the command was

junction "c:documents and settings"  c:winntprofiles

Now, the C:WinntProfiles folder points to C:Documents and Settings.

It's important to understand that your files don't replicate. Junction just creates a pointer. So, every change you make to either folder is actually reflected in the other folder as well.

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like