SeqBox and BlockHashLoc are two file recovery tools designed to help recover files if the file system of a storage device is not accessible anymore.
Files may become inaccessible in a number of ways. They may have been deleted, they may be corrupt, or if the underlying file system of the storage device is corrupt or deleted.
The latter can be extremely frustrating, as file recovery software usually won't be able to recover most files, especially if they were fragmented on the drive.
While backups help, they require storage space that is at least as large as the total amount of data that all files occupy that need to be backed up. Since it is recommended to create multiple backups, it usually means that backup storage needs to have a multiple of the size of the backed up data.
SeqBox and BlockHashLoc, the latter is based on the former, are two tools that create recovery files that users and system administrators may use when disaster strikes. The tools are not a replacement for backups, as they cannot restore files if some data is not available anymore, but they may complement traditional backup solutions.
Both applications calculate cryptographic hashes of all blocks that compose a file. The recovery process uses the information to select the blocks on the storage device that the original file was made of to piece them together.
Traditional recovery solutions are not able to do so, as they don't have the information and don't know which blocks belong to a file and which don't if the file system is missing or corrupt.
The main difference between SeqBox and BlockHashLoc is that the former creates a standalone container that contains the recovery information, the latter a parallel file.
The program is provided as two Python scripts; one -- BHLMake -- that you can run to create BHL files with block-hases and metadata, and the other -- BHLReco -- to run recovery operations.
You can run the program using the command bhlmake *.* to process all files in a directory, or use specific filters, e.g. blhmake *.jpg to process all JPG images. You may use the -r parameter to recurse directories on top of that.
The program creates small bhl files for each file that is processed during the make process. These files are used later on by the recovery process. The -t parameter runs tests on these files to make sure they are not corrupt. The recovery files are relatively small, usually between 6 and 10% of the original file.
To restore files after disaster struck, you'd run the bhlreco storagedevice -bhl *.bhl command. You need to replace storagedevice with the disk that you want scanned.
SeqBox works a bit different from BlockHashLoc. It comes with four tools instead of two. You can use the tool SBXEnc to encode a file to a SBX Container, and SBXDec to decode it back to the original file.
The two recovery tools are SBXScan, which scans a set of files and creates an SQLite database with the recovery information, and SBXReco which uses the recovery information of SBXScan to recover the files.
While they do use the same methods to identify files on a storage device, they differ when it comes to the output. SeqBox creates an container with the file in question, BlockHashLoc a separate file instead.
Now You: how do you protect important files?
If you like our content, and would like to help, please consider making a contribution: