A SysOps Administrator is configuring AWS Systems Manager Patch Manager to automate security updates for a fleet of Amazon Linux 2 EC2 instances. The instances run in a private VPC subnet with no internet connectivity. To allow communication with Systems Manager, the administrator successfully creates interface VPC endpoints for ssm, ssmmessages, and ec2messages. However, when the automated patching task runs, the instances fail to download the required OS update packages, and the patching execution fails. Which of the following should the administrator do to resolve this issue?
- Create a gateway VPC endpoint for Amazon S3 and associate it with the route table of the private subnet.Answer
- BCreate a gateway VPC endpoint for Amazon S3, but rely on the default VPC route table without adding specific route entries to the subnet's route table.
- CCreate a public route pointing to an Internet Gateway in the private subnet's route table to allow direct outbound connections to the Amazon Linux repositories.
- DAssociate the custom patch baseline with a Patch Group named Amazon-Linux-2 and tag the target instances with the key Patch_Group and the value Amazon-Linux-2.
Answer
Create a gateway VPC endpoint for Amazon S3 and associate it with the route table of the private subnet.
Amazon Linux 2 package repositories are hosted in Amazon S3 buckets. In a private subnet with no internet access, instances can communicate with the Systems Manager service via interface VPC endpoints, but they cannot download the actual patch files from Amazon S3 without a route to S3. Creating a gateway VPC endpoint for Amazon S3 and associating it with the private subnet's route table allows the instances to securely download the update packages entirely within the AWS network.
Step-by-Step Solution
Key Concept
Enabling S3 access for SSM Patch Manager in a private VPC subnet using Gateway Endpoints.