(Mix) Data does not match the given SHA-512 checksum

Hey guys,

I have been building my elixir app on a remote server through edeliver until yesterday when both my stage and prod deploys fail with this error: (Mix) Data does not match the given SHA-512 checksum.

-----> Fetching / Updating dependencies
using mix to fetch and update deps
* creating /home/build/.asdf/installs/elixir/1.7.4/.mix/rebar
** (Mix) Data does not match the given SHA-512 checksum.

Expected: 86e998642991d384e9a6d4f216552609496da0e6ec4eb235df5b8b637d078c1a118bc7cdab501d1d54d24e0b6642adf32cc0c43019d948304301ceef227bedfd
  Actual: f4f0a0c66b8bb4b22b9b6163f66af4118b9b92f0ef772d51147f04b17c60095cea7ebb7b7a6704e53599ba35bef1d593f372719ce3ae150fc1dcd24a58c5f2ef

Could not fetch rebar3 at:


Please download the file above manually to your current directory and run:

    mix local.rebar rebar3 ./rebar3

Now I didn’t originally set the server up so I’m hesitant to start messing around with it, but if you guys could provide any insight as to what might cause the issue it would be helpful. Thank you.

Calling mix local.rebar in my machine works as expected.

I also did this:

$ curl https://repo.hex.pm/installs/1.0.0/rebar3-3.5.1 > omg
$ shasum -a 512 omg
86e998642991d384e9a6d4f216552609496da0e6ec4eb235df5b8b637d078c1a118bc7cdab501d1d54d24e0b6642adf32cc0c43019d948304301ceef227bedfd  omg

Which matched the expected value. So I would try running the commands above in your machine as well and see what is happening. What happens when you curl the address? Does the checksum match? Could you have a proxy or anything else messing your network?

Yes, indeed the checksum on the server is different:

-bash-4.2$ curl https://repo.hex.pm/installs/1.0.0/rebar3-3.5.1 > omg
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
 32  691k   32  223k    0     0  1146k      0 --:--:-- --:--:-- --:--:-- 1151k
curl: (56) TCP connection reset by peer
-bash-4.2$ shasum -a 512 omg
f4f0a0c66b8bb4b22b9b6163f66af4118b9b92f0ef772d51147f04b17c60095cea7ebb7b7a6704e53599ba35bef1d593f372719ce3ae150fc1dcd24a58c5f2ef  omg

I’m not sure if there’s a proxy.

Please show the output of curl -vv https://repo.hex.pm/installs/1.0.0/rebar3-3.5.1 > /dev/null. This will show how your request is routed on our CDN which can help us check if there’s an issue on that end.

1 Like
-bash-4.2$ curl -vv https://repo.hex.pm/installs/1.0.0/rebar3-3.5.1 > /dev/null
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* About to connect() to repo.hex.pm port 443 (#0)
*   Trying
* Connected to repo.hex.pm ( port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
*   CAfile: /etc/pki/tls/certs/ca-bundle.crt
  CApath: none
* SSL connection using TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
* Server certificate:
* 	subject: CN=f2.shared.global.fastly.net,O="Fastly, Inc.",L=San Francisco,ST=California,C=US
* 	start date: Apr 01 11:41:33 2019 GMT
* 	expire date: Sep 07 16:10:08 2019 GMT
* 	common name: f2.shared.global.fastly.net
* 	issuer: CN=GlobalSign CloudSSL CA - SHA256 - G3,O=GlobalSign nv-sa,C=BE
> GET /installs/1.0.0/rebar3-3.5.1 HTTP/1.1
> User-Agent: curl/7.29.0
> Host: repo.hex.pm
> Accept: */*
< HTTP/1.1 200 OK
< x-amz-id-2: wavqIHujgDuq+pIuwOtF+m/vnv83EXetJsLjOWAe6cY6Ays+9bfG0ciNUGOszvGHeKitIYQfBS4=
< x-amz-request-id: 1F6B6834269AABF2
< Last-Modified: Tue, 26 Jun 2018 18:09:35 GMT
< ETag: "3010208afbe695b2fb5b3b6b2d14d74a"
< Cache-Control: public, max-age=604800
< x-amz-meta-surrogate-key: installs
< x-amz-version-id: Xm1RMZiLIOgaasL6jDO9V9f3J7IMk2fE
< Content-Type: binary/octet-stream
< Server: AmazonS3
< Content-Length: 707955
< Accept-Ranges: bytes
< Date: Thu, 18 Jul 2019 13:15:46 GMT
< Via: 1.1 varnish
< Age: 233877
< Connection: keep-alive
< X-Served-By: cache-iad2123-IAD, cache-lcy19241-LCY
< X-Cache: HIT, HIT
< X-Cache-Hits: 1, 1
< X-Timer: S1563455746.090896,VS0,VE1
{ [data not shown]
* SSL read: errno -5961 (PR_CONNECT_RESET_ERROR)
* TCP connection reset by peer
 32  691k   32  223k    0     0  1136k      0 --:--:-- --:--:-- --:--:-- 1145k
* Closing connection 0
curl: (56) TCP connection reset by peer
1 Like

You are going through the LCY POP and the hash of the object stored there is the same as in all other POPs so since we haven’t had any other reports of issues my guess is that this is a local issue for you. Verify that you do not have any caching proxies that may have cached an old object.

1 Like