MSMQ 已删除,包括没有互联网的虚拟机中的有效负载,即使安装了映像也无法重新安装

问题描述 投票:0回答:1

由于 PowerShell 中引入的错误,无法访问互联网的 WS2019 虚拟机不仅删除了该功能,还从服务器中删除了其负载

我真的不知道还能尝试什么,任何帮助将非常感激

试过

PS C:\\Windows\\system32\> DISM /Online /Get-Features /Format:Table | FINDSTR "^MSMQ-"
MSMQ-Services                                               | Disabled  
MSMQ-Server                                                 | Disabled with Payload Removed
MSMQ-Triggers                                               | Disabled with Payload Removed
MSMQ-ADIntegration                                          | Disabled with Payload Removed
MSMQ-HTTP                                                   | Disabled with Payload Removed
MSMQ-Multicast                                              | Disabled with Payload Removed
MSMQ-DCOMProxy                                              | Disabled with Payload Removed
MSMQ-RoutingServer                                          | Disabled with Payload Removed

从上传的 iso WS2019 匹配版本中提取信息

dism /get-wiminfo /wimfile:E:\\sources\\install.wim 

WS2019 桌面安装索引 2

安装了该图像

Dism /Mount-Image /ImageFile:e:\\sources\\install.wim /Index:2 /MountDir:C:\\test\\ /readonly

尝试使用上一步中安装的图像启用该功能

DISM /Online /Enable-Feature /FeatureName:MSMQ-Server /All /LimitAccess /Source:C:\\test\\windows

E错误:0x800f081f* 找不到源文件。 使用“源”选项指定恢复功能所需的文件的位置。有关指定源位置的详细信息,请参阅 http://go.microsoft.com/fwlink/?LinkId=243077。

DISM 日志文件可以在 C:\Windows\Logs\DISM\dism.log

找到

尝试过

*PS C:\\Windows\\system32\> Get-WindowsFeature MSMQ*
Display Name                                            Name                       Install State
------------                                            ----                       -------------
[ ] Message Queuing                                     MSMQ                           Available
    [ ] Message Queuing Services                        MSMQ-Services                  Available
        [ ] Message Queuing Server                      MSMQ-Server                      Removed
        [ ] Directory Service Integration               MSMQ-Directory                   Removed
        [ ] HTTP Support                                MSMQ-HTTP-Support                Removed
        [ ] Message Queuing Triggers                    MSMQ-Triggers                    Removed
        [ ] Multicasting Support                        MSMQ-Multicasting                Removed
        [ ] Routing Service                             MSMQ-Routing                     Removed
    [ ] Message Queuing DCOM Proxy                      MSMQ-DCOM                        Removed
Add-WindowsFeature MSMQ-Server -Source C:\\test\\Windows
Add-WindowsFeature : The request to add or remove features on the specified server failed.
Installation of one or more roles, role services, or features failed.
The source files could not be found.
Use the "Source" option to specify the location of the files that are required to restore the feature. For more information on specifying a source location, see http://go.microsoft.com/fwlink/?LinkId=243077.
Error: 0x800f081f
At line:1 char:1

+ Add-WindowsFeature MSMQ-Server -Source C:\\test\\Windows
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (@{Vhd=; Credent...Name=localhost}:PSObject) [Install-WindowsFeature], Exception
    + FullyQualifiedErrorId : DISMAPI_Error__Failed_To_Enable_Updates,Microsoft.Windows.ServerManager.Commands.AddWindowsFeatureCommand

  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Success Restart Needed Exit Code      Feature Result

--------------------------------------------

False   No             Failed         {}

安装的离线和在线图像之间的区别

PS C:\Windows\system32> Dism /Image:C:\test\ /Get-Features /Format:Table | FINDSTR "^MSMQ-"
MSMQ-Services                                                     | Enabled                      
MSMQ-Server                                                       | Enable Pending               
MSMQ-Triggers                                                     | Disabled                     
MSMQ-ADIntegration                                                | Disabled                     
MSMQ-HTTP                                                         | Disabled                     
MSMQ-Multicast                                                    | Disabled                     
MSMQ-DCOMProxy                                                    | Disabled                     
MSMQ-RoutingServer                                                | Disabled                     

PS C:\Windows\system32> DISM /Online /Get-Features /Format:Table | FINDSTR "^MSMQ-"
MSMQ-Services                                               | Disabled                     
MSMQ-Server                                                 | Disabled with Payload Removed
MSMQ-Triggers                                               | Disabled with Payload Removed
MSMQ-ADIntegration                                          | Disabled with Payload Removed
MSMQ-HTTP                                                   | Disabled with Payload Removed
MSMQ-Multicast                                              | Disabled with Payload Removed
MSMQ-DCOMProxy                                              | Disabled with Payload Removed
MSMQ-RoutingServer                                          | Disabled with Payload Removed
powershell msmq dism
1个回答
0
投票

*** 已修复 ***

使用了邻近的\SERVE

© www.soinside.com 2019 - 2024. All rights reserved.