Microsoft KB Archive/931707

= When you use a symbolic link or a hard link to run a program in Windows Vista, the program does not run =

Article ID: 931707

Article Last Modified on 10/26/2007

-

APPLIES TO


 * Windows Vista Business
 * Windows Vista Enterprise
 * Windows Vista Home Basic
 * Windows Vista Home Premium
 * Windows Vista Ultimate
 * Windows Vista Enterprise 64-bit Edition
 * Windows Vista Home Basic 64-bit Edition
 * Windows Vista Home Premium 64-bit Edition
 * Windows Vista Ultimate 64-bit Edition
 * Windows Vista Starter

-



SYMPTOMS
When you use a symbolic link or a hard link to run a program in Windows Vista, the program does not run. Instead, the program exits without generating an error message. You experience this problem if the following conditions are true:
 * The program that you run by using the symbolic link or by using the hard link must load resources.
 * The Multilingual User Interface Pack (MUI) file that is associated with the target program is not located under the symbolic link or under the hard link.



CAUSE
This problem occurs because the program does not load the appropriate MUI file when you use a symbolic link or a hard link to start the program. This problem occurs for the following reasons.

For a symbolic link

This problem occurs because of a problem in the Windows Vista Resource Loader component. If the appropriate MUI file is not located under the symbolic link, Windows Vista does not load the appropriate MUI file. Therefore, the target program does not run successfully.

For a hard link

Windows Vista does not support resource redirection for a hard link. This behavior helps increase performance in Windows Vista.



RESOLUTION
To resolve this problem, perform one of the following actions:
 * Create a symbolic link or a hard link to the MUI file that is associated with the target program. Put this link in a folder that is under the symbolic link or under the hard link for the target program. When you do this, you must copy the folder structure of the target program.
 * Copy the MUI file from the target program to a folder that is under the symbolic link or under the hard link. When you copy this file, you must match the folder structure of the target program.

Sample scenario
The following sample scenario describes how to create a symbolic link for the Whoami.exe program. Additionally, this sample scenario describes how to create a symbolic link to the appropriate MUI file for the Whoami.exe program.

Step 1: Create a symbolic link
Create a symbolic link for the Whoami.exe program. To do this, follow these steps:  Click Start, type cmd in the Start Search box, right-click Cmd.exe in the Programs list, and then click Run as administrator.

If you are prompted for an administrator password or for confirmation, type the password, or click Continue. Move to your home folder. For example, type cd\users\, and then press ENTER. Type mklink testlink.sys c:\windows\system32\whoami.exe, and then press ENTER. The following information appears:

symbolic link created for testlink.sys <<===>> c:\windows\system32\whoami.exe



Note If you type testlink.sys, and then press ENTER, the Whoami.exe program runs as expected. However, if you type testlink.sys /? and then press ENTER, you experience the problem that is mentioned in the &quot;Symptoms&quot; section. This problem occurs because the /? option in the command line causes the Whoami.exe program to load the Help file resources.

Step 2: Create a symbolic link to the appropriate MUI file
Create a symbolic link to the MUI file for the Whoami.exe program. When you do this, you must match the folder structure of the target program. In this example, you must create a symbolic link to the C:\Windows\System32\en-US\Whoami.exe.mui file. To do this, follow these steps:  Create an en-US subfolder under the current working folder. To do this, type mkdir en-US, and then press ENTER. Change to the en-US subfolder. To do this, type cd en-US, and then press ENTER.</li>  Type mklink testlink.sys.mui c:\windows\system32\en-US\whoami.exe.mui, and then press ENTER. The following information appears: <pre class="fixed_text">symbolic link created for testlink.sys.mui <<===>> c:\windows\system32\en-US\whoami.exe.mui </li> Return to the original working folder. To do this, type cd.. , and then press ENTER.</li></ol>

After you follow these steps, the Whoami.exe program runs successfully when you type testlink.sys /? , and then press ENTER.

<div class="status_section">

STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section.

<div class="moreinformation_section">

MORE INFORMATION
For more information about symbolic links in Windows Vista, visit the following Microsoft Web site:

http://www.microsoft.com/technet/technetmag/issues/2007/02/VistaKernel/default.aspx

Keywords: kbtshoot kbbug kbenv kbprb kbpending kbexpertisebeginner KB931707

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.