I have already made images of hard disk partitions.

How can I find out from which areas it is left to make images so that a complete disk image can be assembled from all the resulting files?

  • and what, with copying of all block device there are problems? ( sudo cp /dev/sda /путь/к/файлу ). - aleksandr barakin
  • @alexanderbarakin, it is irrational to spend 9 hours again on copying what is already there. Moreover, there were reading errors there and during this time they could have become more. - Qwertiy
  • @alexanderbarakin, added logs to the question. Although, I believe that the necessary information can be obtained without these logs. - Qwertiy
  • one
    As far as I understand, there is nothing more to copy. you only need to save information about the beginning / end of sections - a couple of lines of text. I personally don’t see any sense in starting the bootloader: if necessary, it is easier (and, in my opinion, “more correct”) to recover “on the spot”. - aleksandr barakin
  • one
    I just lack the initial area? - I do not know what the "initial area" is. perhaps you should read about mbr and gpt on wikipedia. I have already written my view on the recovery of the initial bootloader (in the case of mbr), in the case of gpt, the initial loaders are recorded as files on a separate section. How to find out the exact starting addresses and sizes - written on the link provided. here's another one for a change: unix.stackexchange.com/q/12986/110559 - aleksandr barakin

1 answer 1

  1. Use fdisk to get disk information:

     mint@mint ~ $ sudo fdisk -l /dev/sdb Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0xf3d7eaf1 Device Boot Start End Blocks Id System /dev/sdb1 * 2048 524290047 262144000 7 HPFS/NTFS/exFAT /dev/sdb2 524290048 1953521663 714615808 7 HPFS/NTFS/exFAT 
  2. Only the initial area is not copied - these are 2048 sectors with the size of 512 bytes. Multiply, we get the size of 1 MB.

  3. We copy:

     ddrescue -d -s 1048576 -v /dev/sdb sdb-1M.img sdb-1M.log 
  4. If you wish, you can make sure that further information is already copied:

     ddrescue -d -s 1048576 -v -i 1048576 -o 0 /dev/sdb sdb-M2.img sdb-M2.log ddrescue -d -s 1048576 -v /dev/sdb1 sdb1-1M.img sdb1-1M.log 
  • Forgot to check the tail ... - Qwertiy