Kamis, 14 Februari 2013

Split with DD


One function we might find useful would be the ability to split images up into usable chunks, either for archiving or for use in another program. We will first discuss using split on its own, then in conjunction with dd for “on the fly” splitting.
For example, you might have a 10GB image that you want to split into 640MB parts so they can be written to CD-R media. Or, if you use forensic software in Windows and need files no larger than 2GB (for a FAT32 partition), you might want to split the image into 2GB pieces. For this we use the split
command.
split normally works on lines of input (i.e. from a text file). But if we use the –b option, we force split to treat the file as binary input and lines are ignored. We can specify the size of the files we want along with the prefix we want for the output files. In newer versions of split we can also use the -d option to give us numerical numbering (*.01, *.02, *.03, etc.)
In this case, we have a able2.dd with size 329 MiB.

So, we must split it. Type a command

root@bt:/media/Document/DOJO/Day11# split -d -b 100m able2.dd able2.split
ls

From the picture above, we can see the result of the split is able2.split00, able2.split01, able2.split02, able2.split03, with each result 100 MB and except able2.split003 = 29 MB.

Now, we try to match the Hashing result of file Split with Hashing result original file. Use MD5SUM for it.
Let's type a command 
root@bt:/media/Document/DOJO/Day11# cat able2.split0* | md5sum
for a Split file, and type a command
root@bt:/media/Document/DOJO/Day11# md5sum able2.dd
for a original file

from the above results, the Hashing result is Match.
that means we managed to split the file without changing the original file


0 komentar:

Posting Komentar