Clean up resources
We will take the following steps to delete the resources we created in this exercise.
Delete EC2 instance
- Go to EC2 service management console
- Click Instances.
- Select both Public Linux Instance and Private Windows Instance instances.
- Click Instance state.
- Click Terminate instance

- Then click Terminate to confirm

- Go to IAM service management console
- Click Roles.
- In the search box, enter SSM.
- Click to select SSM-Role.
- Click Delete

- Then enter the role name SSM-Role and click Delete to delete

- Click Users.
- Click on user Portfwd.
- Click Delete, then enter the user name Portfwd and click Delete to delete the user.
Delete S3 bucket
-
Access System Manager - Session Manager service management console.
- Click the Preferences tab.
- Click Edit.
- Scroll down.
- In the section S3 logging.
- Uncheck Enable to disable logging.
- Scroll down.
- Click Save.
-
Go to S3 service management console
- Click on the S3 bucket we created for this lab. (Example: lab-fcj-bucket-0001 )
- Click Empty.
- Enter permanently delete, then click Empty to proceed to delete the object in the bucket.
- Click Exit.
-
After deleting all objects in the bucket, click Delete
-
Enter the name of the S3 bucket, then click Delete bucket to proceed with deleting the S3 bucket.
Delete VPC Endpoints
-
Go to VPC service management console
- Click Endpoints.
- Select the 4 endpoints we created for the lab including SSM, SSMMESSAGES, EC2MESSAGES, S3GW.
- Click Actions.
- Click Delete VPC endpoints.

-
In the confirm box, enter delete.
- Click Delete to proceed with deleting endpoints.
-
Click the refresh icon, check that all endpoints have been deleted before proceeding to the next step.

Delete VPC
-
Go to VPC service management console
- Click Your VPCs.
- Click on Lab VPC.
- Click Actions.
- Click Delete VPC.

-
In the confirm box, enter delete to confirm, click Delete to delete Lab VPC and related resources.
