Not able to rdp to Windows EC2 instance after deleting firewall rules on instance

0

I tried to install python packages from pip on the windows ec2 instance, but I'm getting error:

WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.HTTPSConnection object at 0x0000012FE96940D0>, 'Connection to pypi.org timed out. (connect timeout=15)')': /simple/pip-tools/

For this I was advised to flush the firewall rules on the jnstance, and check if the pip is working. To delete the firewall rules, I executed following syntax:

netsh advfirewall firewall delete rule name=all

As soon as I executed this command, my remote desktop session(initiated using Windows Remote Desktop) got terminated, and now I'm not able to establish the remote desktop session again.

Can anyone please help to understand, how can I rdp to windows instance?

[N.B.: I will really appreciate if any reference on why pip install not be working, can also be shared. I have whitelisted all outbound traffic on security group and network acl(for nacl all inbound traffic has also been whitelisted) on following ip address:

  1. 151.101.0.223/32
  2. 151.101.128.223/32
  3. 151.101.192.223/32
  4. 151.101.192.223/32
  5. 185.199.110.153/32
  6. 185.199.109.153/32
  7. 185.199.111.153/32
  8. 185.199.111.153/32 ]
已提問 1 年前檢視次數 368 次
1 個回答
0

It is very likely that the RDP rules for incoming rules have been deleted.
The firewall must be disabled using AWSSupport-TroubleshootRDP in Systems Manager automation.
The following blog is in Japanese, but does the same thing.
https://qiita.com/handy-dd18/items/282d2150dfa92d446c94

※To use Systems Manager, attach the IAM policy "AmazonSSMMManagedInstanceCore" to the EC2 IAM role.
If your answer leads to a resolution, please approve the answer for the betterment of the community.

profile picture
專家
已回答 1 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南