Install Windows Server 2012 Gui on Core Install using powershell

0

I have very recently started working toward the 70-410 exam, and almost straight away I'm having issues regarding installing the GUI on a core install of server 2012 using install-windowsfeature command in powershell.

I am using virtualbox, Server 2012 installs and runs fine both installed as Core and Standard versions. With Standard install I can use the remove-windowsfeature command to remove the GUI and at a later date I can reinstall the GUI on that Standard install, though I believe that is due to the files still being present on that machine after uninstall.

To reinstall on the Standard installation I only need to use Install-WindowsFeature Server-Gui-Mgmt-Infra, Server-Gui-Shell -Restart It restarts and all is fine, Gui is now installed.

Now for the Core installation the above command fails as it has no idea where to look for the files. Which is what I would expect.

Using both a mounted Iso file or a physical DVD with the following commands have the same results. Initially I used the command DISM /Get-Wiminfo /Wimfile:d:\Sources\install.wim

Which Lists the 4 versions that I have on the DVD or ISO.

Server 2012 Core, Server 2012 Standard, Datacenter 2012 Core, Datacenter 2012 Standard

Now I have tried using Index 1 and 2, though I expected only index 2 'Server 2012 Standard' to work as Server 2012 Core shouldnt have the GUi files required.

The command I am using is:

Install-WindowsFeature Server-Gui-Mgmt-Infra, Server-Gui-Shell -Source wim:d:\sources\install.wim:2

This completes on the Standard version (after gui has been removed), and boots with Gui on restart.

On the core machine it gives an error saying:

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. The component store has been corrupted. Error: 0x80073712 at line:1 char:1 + install-windowsfeature server-gui-mgmt-infra, server-gui-shell - source wim:d:\so ... + CategoryInfo : InvalidOperation: <@:PSObject> [install-windowsfeature], exception FullyQualifiedErrorId : DISMAPI_Failed_To_Enable_Updates.Microsoft.ServerManager.Commands.AddWindowsFeatureCommand

I suspect it will have something to do with the source but I am not sure, any help is most welcome.

powershell
windows-server-2012
asked on Stack Overflow Jul 14, 2016 by amiller112

1 Answer

0

I tested this on one sample test server I have and it is working without any errors. However, in your case as error suggests. Just try to copy the source files again from some good source as those files seems corrupt.

answered on Stack Overflow Jul 14, 2016 by SavindraSingh

User contributions licensed under CC BY-SA 3.0