32位cmd.exe如何在Windows Server 2003 x64上启动64位cmd.exe?

时间:2021-09-17 06:29:44

This is a follow up to 7-Zip execution permissions on Windows Server 2008 64-bit.

这是对Windows Server 2008 64位上的7-Zip执行权限的跟进。

I'm trying to avoid having an overly complicated build process to make multiple 7-Zip EXE files. I just need a .cmd to kick off my Java process after reading some 64-bit registry entries. However, to succeed with a single EXE file, it needs to be 32 bit.

我试图避免过于复杂的构建过程来制作多个7-Zip EXE文件。我只需要一个.cmd来读取一些64位注册表项后开始我的Java进程。但是,要使用单个EXE文件成功,它需要为32位。

The above question found a trick for getting Windows Server 2008 to detect a 32 bit cmd.exe and swap it to 64 bit. Is there a way to do this on Windows Server 2003? There's a Windows hotfix that allows reg.exe to access 64-bit entries in 32-bit mode, but I can't be assured that's on the customer's server so that workaround is a no go.

上面的问题找到了让Windows Server 2008检测32位cmd.exe并将其交换为64位的技巧。有没有办法在Windows Server 2003上执行此操作?有一个Windows修补程序,允许reg.exe以32位模式访问64位条目,但我不能确定这是在客户的服务器上,所以解决方法是不行。

1 个解决方案

#1


14  

To launch 64-bit cmd.exe from 32-bit cmd.exe you must be able to access c:\Windows\System32 folder without being redirected to c:\Windows\SysWow64 folder. In Win2008 you can achieve this by accessing c:\Windows\Sysnative path. Unfortunately on Win2003 a hotfix is required (see http://support.microsoft.com/kb/942589).

要从32位cmd.exe启动64位cmd.exe,您必须能够访问c:\ Windows \ System32文件夹,而无需重定向到c:\ Windows \ SysWow64文件夹。在Win2008中,您可以通过访问c:\ Windows \ Sysnative路径来实现此目的。不幸的是,在Win2003上需要一个修补程序(请参阅http://support.microsoft.com/kb/942589)。

There is a workaround - you can create an NTFS junction point that directs to c:\Windows\System32 folder and use path to that junction point instead of c:\Windows\System32. Using System Internals' junction.exe I managed to create such a junction point from 32-bit cmd.exe and launch 64-bit cmd.exe.

有一种解决方法 - 您可以创建一个NTFS交接点,该交汇点指向c:\ Windows \ System32文件夹,并使用该交汇点的路径而不是c:\ Windows \ System32。使用System Internals的junction.exe我设法从32位cmd.exe创建这样的联结点并启动64位cmd.exe。

#1


14  

To launch 64-bit cmd.exe from 32-bit cmd.exe you must be able to access c:\Windows\System32 folder without being redirected to c:\Windows\SysWow64 folder. In Win2008 you can achieve this by accessing c:\Windows\Sysnative path. Unfortunately on Win2003 a hotfix is required (see http://support.microsoft.com/kb/942589).

要从32位cmd.exe启动64位cmd.exe,您必须能够访问c:\ Windows \ System32文件夹,而无需重定向到c:\ Windows \ SysWow64文件夹。在Win2008中,您可以通过访问c:\ Windows \ Sysnative路径来实现此目的。不幸的是,在Win2003上需要一个修补程序(请参阅http://support.microsoft.com/kb/942589)。

There is a workaround - you can create an NTFS junction point that directs to c:\Windows\System32 folder and use path to that junction point instead of c:\Windows\System32. Using System Internals' junction.exe I managed to create such a junction point from 32-bit cmd.exe and launch 64-bit cmd.exe.

有一种解决方法 - 您可以创建一个NTFS交接点,该交汇点指向c:\ Windows \ System32文件夹,并使用该交汇点的路径而不是c:\ Windows \ System32。使用System Internals的junction.exe我设法从32位cmd.exe创建这样的联结点并启动64位cmd.exe。