The error message “partial credentials found in shared-credentials-file missing aws_secret_access_key” indicates that the shared credentials file you are using is incomplete and does not contain the necessary AWS secret access key. The shared credentials file is typically located at ~/.aws/credentials for Linux/Mac or %USERPROFILE%\.aws\credentials for Windows.
The credentials file should be in the following format:
[default] aws_access_key_id = YOUR_ACCESS_KEY aws_secret_access_key = YOUR_SECRET_KEY
To fix this issue, open the credentials file and make sure it includes the “aws_secret_access_key” field with its corresponding value. For example:
[default] aws_access_key_id = ABCDEFG1234567890 aws_secret_access_key = 1a2b3c4d5e6f7g8h9i0j1k2l3m4n5o6p
If the “aws_secret_access_key” field is missing entirely, you can add it by following these steps:
- Open the credentials file using a text editor.
-
Add the following lines under the appropriate profile section (e.g., “[default]”):
aws_secret_access_key = YOUR_SECRET_KEY
- Replace “YOUR_SECRET_KEY” with the actual secret access key obtained from the AWS Management Console.
- Save the file.
Once you have added the missing secret access key, save the credentials file and retry your AWS operation. The error should no longer occur, assuming all other credentials are correctly configured.