Search code examples
google-cloud-platformgoogle-compute-enginewindows-firewall

I can't connect gcp vm windows after excute "netsh advfirewall reset"


I connect using RDP to vm windows in gcp, after in Windows I execute command netsh advfirewall reset , now I can't connect to my vm.

Please help to connect my vpm, using configuration in cloud shell or other.


Solution

  • Check this document to connect to the Windows SAC, then add your RDP firewall rules

    netsh advfirewall firewall add rule name="Open Port 3389" dir=in action=allow protocol=TCP localport=3389
    
    netsh advfirewall set allprofiles state off