How to retrieve json data from .couch file? #5425
-
Or, is this even possible? You'll have to forgive my novelty with this, but the long story short is I have a .couch file from a volume that ran into an as-yet-unspecified issue. Is there any way to retrieve the contents of the file in JSON? I've opened it in my text editor, and can of course see bits and pieces of my content there, but I assume the file itself is encrypted. I wish I knew how to phrase this better, but any ideas? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
The .couch file is not encrypted but it is in a custom format that only CouchDB can read. I suggest just using couchdb to read it. If it's corrupt such that couchdb can't read it then I'm afraid there's not really a good option. |
Beta Was this translation helpful? Give feedback.
-
My company has some tooling to help salvage data from corrupted files, but it’s not free and there is no guarantee we can get anything out, depending on the nature and severity of the corruption, but do get in touch if this is of interest to you: https://neighbourhood.ie/couchdb-support/ But it sounds like you might be able to get away with putting the file into the database dir like so: |
Beta Was this translation helpful? Give feedback.
My company has some tooling to help salvage data from corrupted files, but it’s not free and there is no guarantee we can get anything out, depending on the nature and severity of the corruption, but do get in touch if this is of interest to you: https://neighbourhood.ie/couchdb-support/
But it sounds like you might be able to get away with putting the file into the database dir like so:
database_dir/shards/00000000-ffffffff/foo.123345.couch
and create a corresponding shard map in your_dbs
db. See https://docs.couchdb.org/en/stable/cluster/sharding.html for more details of what that needs to look like.