Chunping Ruan
2013-07-23 07:21:25 UTC
2 days ago, my leveldb server restart after power switch tripping.
Unfortunately, a 5GB size db corrupted. all keys (10,000,000+) became
inavaiable.
I googled a python script, and tried to repair the db.
#!/usr/local/bin/python
import leveldb
leveldb.RepairDB('/data/leveldb-db1')
I can see lot's of such info in LOG file:
................
013/07/22-01:16:48.812110 801407400 Table #8527104: 0 entries Corruption:
corrupted compressed block contents
2013/07/22-01:16:48.812123 801407400 Table #8527104: ignoring Corruption:
corrupted compressed block contents
2013/07/22-01:16:48.812170 801407400 Archiving
/data/sleveldb-db1/8527104.sst: OK
............
After "repair" , there's only 2 .sst files left in the directory, and the
other 3000+ .sst files were moved to another subdir called "lost"
Is there some useful tools to repair the corrupted data ,or how to repair
the db?
OS: FreeBSD 8.2 amd64
Leveldb: 1.8.0
snappy: 1.0.5
Unfortunately, a 5GB size db corrupted. all keys (10,000,000+) became
inavaiable.
I googled a python script, and tried to repair the db.
#!/usr/local/bin/python
import leveldb
leveldb.RepairDB('/data/leveldb-db1')
I can see lot's of such info in LOG file:
................
013/07/22-01:16:48.812110 801407400 Table #8527104: 0 entries Corruption:
corrupted compressed block contents
2013/07/22-01:16:48.812123 801407400 Table #8527104: ignoring Corruption:
corrupted compressed block contents
2013/07/22-01:16:48.812170 801407400 Archiving
/data/sleveldb-db1/8527104.sst: OK
............
After "repair" , there's only 2 .sst files left in the directory, and the
other 3000+ .sst files were moved to another subdir called "lost"
Is there some useful tools to repair the corrupted data ,or how to repair
the db?
OS: FreeBSD 8.2 amd64
Leveldb: 1.8.0
snappy: 1.0.5
--
You received this message because you are subscribed to the Google Groups "leveldb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leveldb+***@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "leveldb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leveldb+***@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.