Skip to content

s5cmd slow startup #244

@raz-adroll

Description

@raz-adroll

Hi,

I noticed that using s5cmd was slow for me, doing a simple s5cmd ls would take ~20 seconds to start.

I decided to look into and I found why s5cmd was so slow when it ran in my machine, but ran ok in an ec2 instance, well, turns out that by default has a retry of 10 requests. Doing s5cmd -r 0 ls would actually be fast.

After some digging, I found out that it would make 10 requests (throttling included) for getting the credentials. So, it would make 10 calls to 169.254.169.254/latest/api/token and then fallback to 169.254.169.254/latest/meta-data/iam/security-credentials/

Then I Google similar issues and I got this: aws/aws-sdk-go#2972

Maybe it should have a less aggressive retry for getting tokens?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions