I am trying to access an ec2 instance using AWS systems manager for that I've created a role attached to the following policies.
AmazonEC2RoleforSSM
AmazonSSMAutomationApproverAccess
AmazonSSMFullAccess
AmazonSSMAutomationRole
And the role is attached to the ec2 instances. The ec2 instance is listed in the session manager ec2 instance list however when I try to connect I am getting the following error
the version of SSM Agent on the instance supports Session Manager, but the instance is not configured for use with AWS Systems Manager. Verify that the IAM instance profile attached to the instance includes the required permissions
Tried the troubleshooting methods but still getting the following error and one more thing even I removed the attached role the ec2 instance still showing up in the session manager instance list