LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   gzip: is it possible to get something useful from 3 broken gz files? (https://www.linuxquestions.org/questions/linux-software-2/gzip-is-it-possible-to-get-something-useful-from-3-broken-gz-files-912666/)

eantoranz 11-09-2011 11:41 AM

gzip: is it possible to get something useful from 3 broken gz files?
 
Hi!

This is a question about the postgres DB recovery I asked about a few minutes ago, but it's related to a completely different approach.

We have some .gz files (3, I think) made from pg_dump (daily) that will probably contain _almost_ the same information... Each one of them is broken per se but is there a technique that could be used to see if something can be extracted from them by combining the information from all of them? Perhaps one of them could fill a gap that is in another and so on?

Thanks in advance.

jhwilliams 11-09-2011 09:38 PM

Hi eantoranz,

You could try:

Code:

zcat -f broken_postgres.dump.gz
From there, you might need to manually inspect the outputs and paste them together in a sane way.

If it's worth your time, and you're pretty handy with C: checkout the zlib, and hack the executable code to give you debug info about what's up with the broken gz file. http://zlib.net/

The Gzip format RFC spec might useful at this point too: http://www.gzip.org/zlib/rfc-gzip.html#file-format

There are probably other people who have written tools that do something similar though.


All times are GMT -5. The time now is 10:02 PM.