ipfs get file from a non-bootstrap node hangs forever
- Dominant language
- Go
- Stars
- 17.1k
- Forks
- 3.2k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 11
Description
**Version information:**
AgentVersion: go-ipfs/0.4.20/8efc82534
ProtocolVersion: ipfs/0.1.0
System: amd64/linux
GoLang Version: go version go1.12 linux/amd64
**Problem Description:**
I started three IPFS nodes A, B, C on AWS. They are in three different regions, thus in three different VPCs. I was trying to setup a IPFS network comprised of A, B,C, connected via A, without using any public bootstrap nodes.
1. "ipfs bootstrap rm --all" on A, B,C .
2. "ipfs add /ip4/(A’s public IP)/tcp/4001/ipfs/(A’s node id)" on B ,C.
3. “ipfs deamon “ on A, B, C
4. “ipfs swarm peers” on A shows B, C’s multi address with their public ip . “ipfs swarm peers “ on B, C shows A’s multi address with it’s public ip . this means the network is setup as expected.
5. "ipfs add filename.txt" on B, return the file’s hash F
6. "ipfs dht findprovs F" on C, returns B’s nodeId, which is expected
7. “ipfs get F” on node C, fail to actually get the file. Log shows C was trying to connect to B via B’s private IP (e.g 192.168.X.X)
8. If run “ipfs swarm connect B’s public multi address” on C first, then 7 can be successful.
My question is:
How could step 7 fail when step 6 is successful?
How to make step 7 successful (without having to run 8 first)
Any help is appreciated!
Contributor guide
Research direction
Start by reproducing the three-node AWS setup and run the reported `ipfs dht findprovs`, `ipfs get`, and `ipfs swarm connect` commands. Compare the public and private multiaddresses used during provider discovery and retrieval; done means `ipfs get` succeeds without a manual swarm connection and the address-selection failure is explained.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- distributed-systems, networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100