Aws Sync Clock

less than 1 minute read

If you are dealing with AWS s3 buckets, there is a common error which araises and tell you

“botocore.exceptions.ClientError: An error occurred (RequestTimeTooSkewed) when calling the ListBuckets operation: The difference between the request time and the current time is too large.”

As a solution to this, you have to tell your server to pick the time directly from Amazon servers. Here is how to do this:

  1. To install NTP, simply choose one of the following, depending on your distribution
apt-get install ntp
  1. Configure NTP to use amazon servers, like so:
vim /etc/ntp.conf
  1. And in it, comment out the default servers and add these:
server 0.amazon.pool.ntp.org iburst
server 1.amazon.pool.ntp.org iburst
server 2.amazon.pool.ntp.org iburst
server 3.amazon.pool.ntp.org iburst

  1. And then restart ntp service:
sudo service ntp restart

Source - allcloud Source - DigitalOcean

Updated: