Fixing "permission denied" error when trying "ipfs add"

When I tried to add a directory from another partition ipfs said "permission denied".

$ ipfs add -r bionicpup64-8.0-with-crypto-tools
Error: open bionicpup64-8.0-with-crypto-tools: permission denied

USAGE
  ipfs add ... - Add a file or directory to ipfs.

  ipfs add [--recursive | -r] [--dereference-args] [--stdin-name=]
           [--hidden | -H] [--ignore=]...
           [--ignore-rules-path=] [--quiet | -q]
           [--quieter | -Q] [--silent] [--progress | -p] [--trickle | -t]
           [--only-hash | -n] [--wrap-with-directory | -w]
           [--chunker= | -s] [--pin=false] [--raw-leaves] [--nocopy]
           [--fscache] [--cid-version=] [--hash=] [--inline]
           [--inline-limit=] [--] ...

  Adds contents of  to ipfs. Use -r to add directories (recursively).

  For more information about each command, use:
  'ipfs add  --help'

I fixed this problem with the command:

$ sudo snap connect ipfs:removable-media

For some reason snap "think" that my hard drive partition is a "removable media". The same error message appears when trying to add file/directory from the /tmp partition.

Comments