1개 답변
- 최신
- 최다 투표
- 가장 많은 댓글
0
Hi there,
Since you cannot connect to your Lightsail instance via ssh or through the browser-based ssh client after enabling ufw. You can recover your instance by taking a snapshot of it if you did not create a backup on launch and create a new instance from it. When you launch the new instance via console add the following script as a launch script to disable ufw:
sudo service ufw stop
You can also use AWS CLI to launch the new instance from a snapshot by running the following command:
aws lightsail create-instances-from-snapshot --region <snapshot-region> --instance-snapshot-name <snapshot-name> --instance-names <new-instance-name> --availability-zone <preferred-AZ> --user-data 'sudo service ufw stop' --bundle-id <value>
Alternately, you can export your Lightsail snapshot to Amazon EC2 for further troubleshooting by following the steps here and here. Additionally, here is a video tutorial on how to export Lightsail instance to Amazon EC2 instance.
Hope this helps
답변함 2년 전
관련 콘텐츠
- AWS 공식업데이트됨 일 년 전
- AWS 공식업데이트됨 일 년 전
- AWS 공식업데이트됨 3년 전