The Joy of File System Redirection
You have all seen it before, the option when we deploy our applications to make the application run as 32bit on a 64bit system or to disable the 64bit file redirection in a task sequence. What do these options actually do though and why does it matter?
The %windir%\System32 directory is reserved for 64-bit applications. Most DLL file names were not changed when 64-bit versions of the DLLs were created, so 32-bit versions of the DLLs are stored in a different directory. WOW64 hides this difference by using a file system redirector.
In most cases, whenever a 32-bit application attempts to access %windir%\System32, the access is redirected to %windir%\SysWOW64. Access to %windir%\lastgood\system32 is redirected to %windir%\lastgood\SysWOW64. Access to %windir%\regedit.exe is redirected to %windir%\SysWOW64\regedit.exe.
If the access causes the system to display the UAC prompt, redirection does not occur. Instead, the 64-bit version of the requested file is launched. To prevent this problem, either specify the SysWOW64 directory to avoid redirection and ensure access to the 32-bit version of the file, or run the 32-bit application with administrator privileges so the UAC prompt is not displayed.
With this information in mind what does this mean in ConfigMgr terms? Well you are probably all familiar with the following screenshot which comes from the Run Command Line task sequence step.
By default, when running on a 64-bit operating system, the executable in the command line is located and run using the WOW64 file system redirector so that 32-bit versions of operating system executables and DLLs are found. Selecting this option disables the use of the WOW64 file system redirector so that native 64-bit versions of operating system executables and DLLs can be found. Selecting this option has no effect when running on a 32-bit operating system.
I have been to customers where this box is always ticked “because they think it should be”, however consider the scenario where you are running a 32-bit application which actually due to it been written for a 32-bit operating system calls a binary and then fails. This would be because the application or DLL is trying to access as a 32-bit application 64-bit resources which will fail.
In summary then, what I am saying here is don’t disable this option, this way you let the operating system take care of what it needs to run instead of forcing it to run something which may lead to a failure. In systems management it’s always important to understand the applications you are deploying, not only for regular deployments but also in operating system deployment where one failure can lead to a whole task sequence failing.