Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Enable feature TCP Activation on Windows server 2016 fails due to parent issue

I try to enable feature TCP Activation on a Windows Server 2016 but it fails with

"The request to add or remove features on the specified server failed.
Installation of one or more role, role services, or features failed. 
One or several parent features are disabled so current feature can not be enabled. 
Error: 0xc004000d"

I have tracked down the parent features and they are all installed.
I can find nothing relevant in the event log.
The machine is freshly rebooted.

Q: What is failing
or how do I track it down?


TL;DR

I tracked down the TCP Activation feature with Powershell like so:

Get-WindowsFeature | where { $_.Name -eq 'NET-WCF-TCP-Activation45' } | select *

which gives me (shortened)

...
Installed                 : False
InstallState              : Available
DependsOn                 : {NET-Framework-45-Core, NET-WCF-TCP-PortSharing45, NET-Framework-45-ASPNET, WAS-Process-Model...}
...

The feature is not installed. That is what is expected.
Then I find the clue DependsOn which I guess is the same as parent feature in the error message.
So I expand it with

Get-WindowsFeature | where { $_.Name -eq 'NET-WCF-TCP-Activation45' } | select -ExpandProperty DependsOn

which gets me to

NET-Framework-45-Core
NET-WCF-TCP-PortSharing45
NET-Framework-45-ASPNET
WAS-Process-Model
WAS-Config-APIs

and iterating through them gives me

Installed                 : True
InstallState              : Installed

for each and every one.

I try to enable the feature through Powershell in the hope of finding more information.

PS C:\...\> Install-WindowsFeature NET-WCF-TCP-Activation45 -Verbose
VERBOSE: Installation started... 
VERBOSE: Continue with installation?
VERBOSE: Prerequisite processing started...
VERBOSE: Prerequisite processing succeeded.
Install-WindowsFeature : The request to add or remove features on the specified server failed.
Installation of one or more roles, role services, or features failed.
One or several parent features are disabled so current feature can not be enabled. Error: 0xc004000d
At line:1 char:1
+ Install-WindowsFeature NET-WCF-TCP-Activation45
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + 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         {}     

As written before the fold I can find nothing of relevance in the event log.
Are there other logs to look at?
The machine is freshly rebooted and fairly new, I have only installed SqlServer2017 on it. Where do I continue?

like image 834
LosManos Avatar asked Nov 29 '25 16:11

LosManos


2 Answers

For those coming to this thread late the issue is that Windows Activation Service itself must be enabled for this to work, even though its not listed as a "dependency". Then add the other dependencies, and finally WCF-TCP-Activation45.

So to enable TCP Activation the total operation would look like the following.

Enable-WindowsOptionalFeature -Online -FeatureName WAS-WindowsActivationService
Enable-WindowsOptionalFeature -Online -FeatureName WAS-ProcessModel
Enable-WindowsOptionalFeature -Online -FeatureName WAS-ConfigurationAPI
Enable-WindowsOptionalFeature -Online -FeatureName WCF-TCP-Activation45

As a bonus tip if you want to enable HTTP Activation its the exact same except replace "TCP" with "HTTP" in the above.

like image 190
Morgan Avatar answered Dec 02 '25 06:12

Morgan


We encountered the same issue on a Windows Server 2012R2 instance.

After removing .Net Framework 4.7.1 by uninstalling Windows Update KB4033369, the command worked and WCF TCP Activation was enabled.

like image 34
Janiek Buysrogge Avatar answered Dec 02 '25 07:12

Janiek Buysrogge