Life's random bits By b1thunt3r (aka Ishan Jain)…
Change Network Location Type in 2012/2012R2 (NT 6.2/6.3)

Change Network Location Type in 2012/2012R2 (NT 6.2/6.3)

Ishan jain
It happens sometimes I want to change the Location type/profile of a certain Network Adapter (mostly when testing).

On Windows 8 all you need to do is enable network sharing under:

PC-Settings → Network → Connections → INTERFACE

But in Windows Server 2012 it is a bit more complicated. For that you will need help of PowerShell.

Start PowerShell as Admin.

Run:

Get-NetConnectionProfile

This will give you a list of Interfaces on you system, note down the InterfaceIndex of the Interface you want to change Location type/profile of.

Then run:

Set-NetConnectionProfile -InterfaceIndex [INDEX] -NetworkCategory Private

And voilà you are done.