Skip to content

Issues when trying to override CLI credentials on an EC2 instance #7795

Answered by RyanFitzSimmonsAK
rankol asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @rankol, thanks for reaching out. Having a token invalid error on get-caller-identity is definitely strange, since that command doesn't require any permissions. Do you have aws_session_token in your profile or AWS_SESSION_TOKEN as an environment variable? If so, try clearing it.

I was able successfully make my profile using the same process you followed, but it might be worth it for you to try another method. Could you try making your profile by importing CSV credentials? Here's the associated documentation for that, specifically the section on using named profiles and aws configure import, but I'll go over the steps.

  1. Generate CSV credentials from the IAM web console.
  2. Edit them in Not…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@rankol
Comment options

Answer selected by tim-finnigan
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants