I want to see if a given string ("hello"
in this case) is accessible via IPFS. I am trying this:
echo hello | ipfs add -nq | ipfs cat
I am getting this:
Error: lock /root/.ipfs/repo.lock: someone else has the lock
What's going on? Is there a global lock, or is IPFS just protecting itself from a race condition that could have happened if I hadn't specified the -n
flag?
This seems to work:
HASH=`echo hithere | ipfs add -nq` && ipfs cat $HASH
However, I wonder whether there is a more idiomatic way. This must be a fairly standard thing to do.