ipfs / ipfs-update

An updater tool for Kubo IPFS binary
https://dist.ipfs.tech/#ipfs-update
MIT License
137 stars 60 forks source link

Hanging while downloading #154

Open jbenet opened 2 years ago

jbenet commented 2 years ago

Version information:

ipfs

Description:

Command Output:

# no ipfs running in bg
% ps aux | grep ipfs 
% ipfs-update install v0.11.0
fetching go-ipfs version v0.11.0

hang

% ipfs-update install v0.11.0
fetching go-ipfs version v0.11.0
binary downloaded, verifying...
success! tests all passed.
stashing old binary
installing new binary to /usr/local/bin/ipfs
checking if repo migration is needed...
  check complete, migration required.
2021/12/31 13:46:19 Looking for suitable migration binaries.
2021/12/31 13:46:19 Need 2 migrations, downloading.
2021/12/31 13:46:19 Downloading migration: fs-repo-9-to-10...
2021/12/31 13:46:19 Downloading migration: fs-repo-10-to-11...

hang

% ipfs-update install v0.11.0
fetching go-ipfs version v0.11.0
binary downloaded, verifying...
success! tests all passed.
stashing old binary
installing new binary to /usr/local/bin/ipfs
checking if repo migration is needed...
  check complete, migration required.
2021/12/31 13:46:19 Looking for suitable migration binaries.
2021/12/31 13:46:19 Need 2 migrations, downloading.
2021/12/31 13:46:19 Downloading migration: fs-repo-9-to-10...
2021/12/31 13:46:19 Downloading migration: fs-repo-10-to-11...
2021/12/31 13:46:21 Downloaded and unpacked migration: /tmp/migrations866676225/fs-repo-9-to-10 (v1.0.1)

hang

aschmahmann commented 2 years ago

shouldn't happen though -- ipfs-update should probably make use of ipfs properties and route around broken gateways

Yes, it's possible to try additional gateways here. However, unfortunately CAR export from gateways is not standardized yet. A promising proposal to enable this which is being looked into in the coming year is https://github.com/ipfs/go-ipfs/issues/8234. Until then this means that using HTTP Gateways involves some trust so we can't just grab any arbitrary gateway off of https://ipfs.github.io/public-gateway-checker/ and use it.

If we wanted to push ahead with this without CAR export being standardized it's certainly possible to do one+ of:

Note: If you have an IPFS daemon running you can do ipfs-update fetch latest and it will pull the data over a local IPFS node that supports the IPFS HTTP API (e.g. go-ipfs) which gives you lots of IPFS properties 😄.