到目前为止,我们公司中有两台计算机,使用CMD.exe运行powershell命令时出现并行错误。我们在Win 7的所有计算机模型上运行此脚本都没有问题。我尝试重新安装C ++应用程序无济于事。我们将不胜感激。
SxsTrace:
=================
Begin Activation Context Generation.
Input Parameter:
Flags = 0
ProcessorArchitecture = AMD64
CultureFallBacks = en-US;en
ManifestPath = C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe
AssemblyDirectory = C:\Windows\System32\WindowsPowerShell\v1.0\
Application Config File = C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe.Config
-----------------
INFO: Parsing Application Config File C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe.Config.
ERROR: Line 0: XML Syntax error.
ERROR: Activation Context generation failed.
End Activation Context Generation.
事件查看器:
Log Name: Application
Source: SideBySide
Date: 5/21/2019 1:31:45 PM
Event ID: 59
Task Category: None
Level: Error
Keywords: Classic
User: N/A
Computer: test.domain.com
Description:
Activation context generation failed for "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe".Error in manifest or policy file "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe.Config" on line 0. Invalid Xml syntax.
Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
<System>
<Provider Name="SideBySide" />
<EventID Qualifiers="49409">59</EventID>
<Level>2</Level>
<Task>0</Task>
<Keywords>0x80000000000000</Keywords>
<TimeCreated SystemTime="2019-05-21T17:31:45.000000000Z" />
<EventRecordID>70132</EventRecordID>
<Channel>Application</Channel>
<Computer>test.domain.com</Computer>
<Security />
</System>
<EventData>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe</Data>
<Data>C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe.Config</Data>
<Data>0</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
</Data>
</EventData>
</Event>
已安装的应用程序:
Name Version
Microsoft Visual C++ 2005 Redistributable (x64) 8.0.59192
Microsoft Visual C++ 2005 Redistributable (x64) 8.0.61000
Microsoft Visual C++ 2005 Redistributable (x64) 8.0.56336
Microsoft Visual C++ 2005 Redistributable 8.0.61001
Microsoft Visual C++ 2015 x86 Additional Runtime - 14.0.24215 14.0.24215
Microsoft Visual C++ 2015 x86 Minimum Runtime - 14.0.24215 14.0.24215
Microsoft Visual C++ 2008 Redistributable - x64 9.0.21022 9.0.21022
Microsoft Visual C++ 2008 Redistributable - x86 9.0.30729.17 9.0.30729
Microsoft Visual C++ 2013 x64 Additional Runtime - 12.0.40660 12.0.40660
Microsoft Visual C++ 2013 x64 Minimum Runtime - 12.0.40660 12.0.40660
Microsoft Visual C++ 2013 x86 Additional Runtime - 12.0.40660 12.0.40660
Microsoft Visual C++ 2013 x86 Minimum Runtime - 12.0.40660 12.0.40660
Microsoft Visual C++ 2008 Redistributable - x86 9.0.30729.6161 9.0.30729.6161
Microsoft Visual C++ 2012 x64 Additional Runtime - 11.0.61030 11.0.61030
Microsoft Visual C++ 2012 x64 Minimum Runtime - 11.0.61030 11.0.61030
Microsoft Visual C++ 2012 x86 Additional Runtime - 11.0.61030 11.0.61030
Microsoft Visual C++ 2012 x86 Minimum Runtime - 11.0.61030 11.0.61030
Microsoft Visual C++ 2015 x64 Additional Runtime - 14.0.23026 14.0.23026
Microsoft Visual C++ 2015 x64 Minimum Runtime - 14.0.23026 14.0.23026
对于注册表,什么也没做。我以为可以消除故障排除步骤。
HKEY_LOCAL_MACHINE \ Software \ Microsoft \ Windows \ CurrentVersion \ SideBySide \ Winners \ x86 | policy.9.0.microsoft.vc90.crt