When I launch my IPFS daemon, content I have published is remotely available for a few hours. After a while, nevertheless, the network forgets about it. If I do “ipfs dht provide” to refresh the network, the IPFS network is able to locate my content again.
I have not changed the default configuration for the reprovider:
I am currently hosting about 10GB of content.
I am using an ipfs-cluster with two nodes, if that is a possible factor.
First, do you use the accelerated DHT client (you should)?
ipfs config --json Experimental.AcceleratedDHTClient true
Second, the network churn is such that 12 hours is a bit too slow, so I have changed mine to 8 hours and the problem went away.
The reason you might be facing this problem is that provider runs take longer than 24 hours which is also the expiration period for provider records.
As mentioned above, enabling the accelerated DHT Client should help at the cost of higher resource consumption.
Another option is to change the provider strategy to
roots which would reduce the number of records published (they would still be available via Bitswap) .
You can find more information about dealing with this problem in the following blog post:
I have enabled “Experimental.AcceleratedDHTClient”. If not enough, I will decrease the announcement period.
$ ipfs stats provide
TotalProvides: 180k (180,959)
LastReprovideBatchSize: 180k (180,959)
Apparently, my ipfs can announce all my content in the DHT in less than 9 minutes.
Thanks for the suggestion.
Thanks for the suggestions.
After enabling the accelerated DHT client, the reported publishing time is less than 9 minutes. I don’t know the old publishing time, but I very much doubt it was > 24 hours.
Changing provider strategy to “pinned” will not help because all my storage is pinned (not cached foreign content) and “roots” is flaky if whoever is requesting my data is not a peer of me. Burned already trying that.
The provided blog link was useful and interesting. Thanks.
I currently enabled the accelerated DHT client. Lets see. If not enough, I will decrease the publishing period. Advertising blocks is the current fundamental Achilles heel of IPFS.