By Steve Endow
This is just a post for me to store this information for Future Steve, as he will most certainly need it, just as Present Steve has needed it a dozen times over the last year.
Any time I replace my router, replace a piece of Ubiquiti network gear, or reconfigure my network, all of my Windows Server VMs decide they've been kidnapped and change their network location to Public network.
This blocks all traffic on the servers until I can login directly to each server and fix the problem.
Which requires an annoying process using gpedit or PowerShell, which I can never remember after 6 months.
So here is the post with the information to fix the problem:
Using the GUI:
- Hit Winkey + R to open Run prompt and type gpedit.msc
- Navigate to:
Computer Configuration/Windows Settings/Security Setting /Network List Manager Policies
. - Choose your Network name in the right pane.
Note: To show networks not currently connected, right-click Network List Manager Policies in the left pane and choose Show All Networks. Go to Network Location tab and change the Location type from Public to Private.
Using PowerShell...
One line version:
Set-NetConnectionProfile -InterfaceAlias Ethernet -NetworkCategory Private
Multi-line version:
PS C:\>$Profile = Get-NetConnectionProfile -InterfaceAlias Ethernet1
PS C:\>$Profile.NetworkCategory = "Private"
PS C:\>Set-NetConnectionProfile -InputObject $Profile
Steve Endow is a Microsoft MVP in Los Angeles. He works with Dynamics 365 Business Central, Microsoft Power Automate, Power Apps, Azure, and .NET.
No comments:
Post a Comment
All comments must be reviewed and approved before being published. Your comment will not appear immediately.