Hello Cooper, David A. [ISS] (Contractor)
In an Always On Availability Group (AG) cluster with SQL on Azure VMs, automated patching typically uses a rolling update process to apply patches to the nodes in the cluster.
The process works as follows:
- The patch is first applied to the secondary replica nodes one at a time.
- During the patching process, the secondary replica nodes are disconnected from the primary replica node to avoid any potential data conflicts.
- Once the patching is complete on a secondary replica node, it is reconnected to the primary replica node and resumes synchronizing with the primary replica node.
- After all secondary replica nodes have been patched, the primary replica node is then patched in the same way as the secondary replica nodes.
- Once the patching is complete on the primary replica node, it is reconnected to the secondary replica nodes and resumes serving as the primary replica node.
During this process, the original primary node may still be the primary node after patching is completed. However, it is possible that another replica node could be selected as the primary node depending on the specific failover settings and the state of the nodes in the cluster.
It's important to note that the exact process for automated patching may vary depending on the specific configuration of the Always On AG cluster, the version of SQL Server, and other factors. It's recommended to review the documentation provided by Microsoft or consult with a certified Azure expert for guidance on how to best configure automated patching for your specific environment.
Please accept as answer and upvote if the above information is helpful for the benefit of the community.