Skip to content

Performed in place upgrade on an instance

0

I performed an in-place upgrade to a Ec2 instance from Windows 2012 to 2016 by following the instructions provided by https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/os-inplaceupgrade.html

Everything seemed to go as instructed but after the reboot I cannot connect to the instance. It is running, but I look at the Connect tab and i see this error

SSM Agent is not online The SSM Agent was unable to connect to a Systems Manager endpoint to register itself with the service.

How do i fix?

Thank you, Chris

asked 2 years ago519 views

2 Answers
1

Hi,

The first step you should attempt is to reconnect to your instance viaRDP to diagnose the issue from the inside of your instance: see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connecting_to_windows_instance.html for all details.

When you get connected, you should be able to diagnose and fix what went wrong on your EC2 instance.

Best,

Didier

EXPERT

answered 2 years ago

EXPERT

reviewed 2 years ago

0

I understand you're facing connectivity issues after performing an in-place upgrade on your EC2 instance from Windows Server 2012 to 2016. The error message you're seeing indicates that the SSM Agent is unable to connect to the Systems Manager endpoint. This is a common issue that can occur after an OS upgrade. Here are some steps you can take to troubleshoot and potentially resolve the issue:

  1. First, verify that the IAM instance profile attached to your EC2 instance has the correct permissions for Systems Manager. The profile should have the necessary policies to allow the instance to communicate with the SSM service.

  2. Check your instance's security group and VPC settings. Ensure that they allow HTTPS (port 443) outbound traffic to the following Systems Manager endpoints:

    • ssm.[your-region].amazonaws.com
    • ec2messages.[your-region].amazonaws.com
    • ssmmessages.[your-region].amazonaws.com
  3. If your VPC doesn't have internet access, you may need to set up VPC endpoints for Systems Manager to allow outbound traffic from your instance.

  4. It's possible that the SSM Agent was affected during the upgrade process. You may need to reinstall or update the SSM Agent on your instance. However, since you can't connect to the instance directly, this might be challenging.

  5. If you have enabled EC2 Instance Connect before the upgrade, you might be able to use it to access your instance and troubleshoot further.

  6. As a last resort, you might consider creating a new AMI from the current state of your instance, launching a new instance from this AMI, and then troubleshooting the SSM Agent issues on the new instance.

If these steps don't resolve the issue, you may need to engage AWS Support for further assistance. They can help you diagnose the root cause of the connectivity problem and provide more specific guidance based on your account and instance configuration.

Remember, for future upgrades, it's always a good practice to create a backup AMI before performing an in-place upgrade. This allows you to roll back if you encounter issues like this.

Sources
SSM Agent is not online. The SSM Agent was unable to connect to a Systems Manager endpoint to register itself with the service. | AWS re:Post
Unable to Connect to EC2 instance after upgrading from Windows Server 2012 r2 to 2016 | AWS re:Post
Perform an in-place upgrade on your EC2 Windows instance - Amazon Elastic Compute Cloud

answered 2 years ago

EXPERT

reviewed 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.