Ensure that all Amazon EC2 instances are managed by AWS Systems Manager (SSM).
Systems Manager simplifies AWS cloud resource management, quickly detects and resolve operational problems, and makes it easier to operate and manage your instances securely at large scale.
Configure AWS EC2 instance as SSM Managed Instances