Windows Server 2012 – Removed .NET Now Only Have Command Line
Yesterday I had to remove and reinstall .NET on a Windows 2012 server. I needed to do this because .NET had been installed before IIS8, causing IIS to have missing handler mappings, in my case I needed .SVC files to be handled for some WCF services.
If you have tried running the usual aspnet_regiis command and found that its been retired you might have gone and removed and re install .NET in the hope it would solve the issue. Then when you reboot, found that you are greeted with a command line interface, instead of the fancy GUI! After a bit of research on how to reinstate the missing features I ran the following command and all was fixed.
Dism /online /enable-feature /all /featurename:Server-Gui-Mgmt /featurename:Server-Gui-Shell /featurename:ServerCore-FullServer
But my file type is still not being handled correctly!?
The first thing to check is that you have the following enabled…
- Run “
Server Manager"(on task bar and start menu)
- Choose the server to administer (probably local server)
- Scroll down to “
Roles and Features” section.
- Choose “
Add Role or Feature” from Tasks drop down
- On “
Add Role or Feature Wizard” dialog, click down to “
Features” in list of pages on the left.
".Net 4.5", depending on what you have installed. (you can go back up to “
roles” screen to add if you don’t have.
- Under “
WCF Services“, check the box for “
HTTP-Activation“. You can also add non-http types if you know you need them (tcp, named pipes, etc).
Still not working!?
Try manually registering the handler. As every file type has a different handler, you should be able to find what you need to enter with a quick Google.