Windows Server In place upgrades with regards major versions

0

Hi Folks

I have looked into the main ways O/S upgrades (between major versions from 2019 to 2022 for example) can be performed on EC2 Instances. Obviously those being using the automation documents and also the method by which you can attach a volume and the end result creates a new AMI as an output for you to use. Bottom line neither of these really suit our current setup as a organisation. The first method is very involved and the second means creating a fresh instance from the AMI that will ultimately have a different ID and IP address. To explain a little further on this; we have over 300+ instances that are unique to our clients housing our web product so performing an upgrade using either way is as involved as it gets if we are todo this *manually as he have in the past and did do for the last major Windows Server 2019 to 2022 exercise.

  • By this I mean creating a fresh instance from one of our AMIs that has the latest windows OS, using that new instance and copying over product and systems to it, configuring settings in our product for the change in IP and decommissioning the older 2019 server instance.

As you can imagine this can be quite a labour intensive task for our technicians especially over 300+ instances and mainly done out of hours not to affect our clients.

My question is has anyone had any experience (or recommendations) in automating and having a similar setup or process? In an ideal world the process would be something along the lines of 1) a snapshot is created just before OS update, the current instance performs an inplace Windows upgrade to the latest version, restarts itself if required so that we don't have to migrate our product per instance either.

Any thoughts welcome - TIA

RSBWFC
asked 2 months ago303 views
1 Answer
0

There is SSM automation you can try that has below workflow in your test environment to see if it fits your use case. "The upgrade operation is a multi-step process that can take 2 hours to complete. We recommend performing an operating system upgrade on instances with at least 2 vCPUs and 4GB of RAM. The automation creates an AMI from the instance and then launches a temporary instance from the newly created AMI in the SubnetId that you specify. The security groups associated with your original instance are applied to the temporary instance. The automation then performs an in-place upgrade to the TargetWindowsVersion on the temporary instance. To upgrade your Windows Server 2008 R2 instance to Windows Server 2016, 2019, or 2022, an in-place upgrade is performed twice because directly upgrading Windows Server 2008 R2 to Windows Server 2016, 2019, or 2022 is not supported. The automation also updates or installs the AWS drivers required by the temporary instance. After the upgrade, the automation creates a new AMI from the temporary instance and then terminates the temporary instance."

--> For your concern related to changing IP address: Once you verify the new AMI by going through your verification checklist, If it passes your tests and you're ready to use this new AMI, you can try creating volumes from the new AMI, stop current active instance and swap existing volumes with these new volumes.

https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/automated-upgrades.html https://docs.aws.amazon.com/systems-manager-automation-runbooks/latest/userguide/automation-awsec2-CloneInstanceAndUpgradeWindows.html

AWS
answered 2 months ago
profile picture
EXPERT
reviewed a month ago
  • Thanks for the reply; but that still means creating a new EC2 instance from the "new" AMI which will have a different IP and instance ID wont it?

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.

Guidelines for Answering Questions