Courseiva
Machine Learning Implementation and OperationshardMultiple ChoiceObjective-mapped

MLS-C01 Practice Question: Machine Learning Implementation and Operations

A financial services company uses Amazon SageMaker to train a fraud detection model. The training data is stored in an S3 bucket encrypted with AWS KMS. The SageMaker training job is configured to use a custom Docker container that reads data from S3 and writes model artifacts back to S3. The training job fails with the error: 'Unable to write model artifact to s3://my-bucket/output/model.tar.gz. Access Denied.' The IAM role used by the training job has the following permissions: s3:GetObject and s3:PutObject on the bucket, and kms:Decrypt on the KMS key. The training job is not using a VPC. What is the MOST likely cause of the failure?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

The IAM role does not have kms:GenerateDataKey permission on the KMS key

The training job needs kms:GenerateDataKey permission to write objects encrypted with the KMS key. The provided IAM role has s3:GetObject, s3:PutObject, and kms:Decrypt, but lacks kms:GenerateDataKey, causing the Access Denied error when writing. Option A is incorrect because a region mismatch would not necessarily cause an Access Denied error if cross-region access is allowed, and the error indicates a permissions issue. Option C is incorrect because S3 Batch Operations is not required for writing artifacts. Option D is incorrect because the role already includes s3:PutObject.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • The S3 bucket is in a different region than the training job

    Why it's wrong here

    The error indicates an access denied, not a region issue. S3 cross-region access is supported with proper permissions; the failure is due to missing KMS permission.

  • The IAM role does not have kms:GenerateDataKey permission on the KMS key

    Why this is correct

    Correct because when writing to an encrypted S3 bucket, the IAM role needs kms:GenerateDataKey in addition to kms:Decrypt to create the data key for encryption.

  • The S3 bucket requires S3 Batch Operations for writing artifacts

    Why it's wrong here

    S3 Batch Operations is used for bulk operations, not for single artifact writes. This is irrelevant to the access denied error.

  • The IAM role does not have s3:PutObject permission on the output bucket

    Why it's wrong here

    The role already has s3:PutObject, so lack of that permission is not the issue. The missing permission is kms:GenerateDataKey.

Quick reference

AWS S3 Storage Class Comparison

Storage ClassMin DurationRetrievalUse Case
S3 StandardNoneImmediateFrequently accessed data
S3 Standard-IA30 daysImmediateInfrequent access, rapid retrieval
S3 One Zone-IA30 daysImmediateNon-critical infrequent data
S3 Intelligent-TieringNoneImmediate–hoursUnknown or changing access patterns
S3 Glacier Instant90 daysMillisecondsArchive with instant retrieval
S3 Glacier Flexible90 daysMinutes–hoursArchive, flexible retrieval
S3 Glacier Deep Archive180 daysHoursLong-term compliance archive

About these practice questions

One of 1,672 original MLS-C01 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This MLS-C01 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the MLS-C01 exam.