Podłączyłem routerowi przez gniazdo USB dysk w obudowie (akurat przypadkowo też
1TB):
# fdisk -l
Disk /dev/sda: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 1 267350 2147483647+ ee EFI GPT
Disk /dev/sdb: 1000.2 GB, 1000204140544 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 126 1003520 83 Linux
Partition 1 does not end on cylinder boundary
/dev/sdb2 126 189 505856 83 Linux
Partition 2 does not end on cylinder boundary
/dev/sdb3 189 252 505856 83 Linux
Partition 3 does not end on cylinder boundary
/dev/sdb4 252 121602 974744576 5 Extended
/dev/sdb5 252 284 256000 82 Linux swap
/dev/sdb6 284 121602 974486528 7 HPFS/NTFS
No i teraz nie wiem, który jest routera (Internal HDD WD10JPVT), a który
zewnętrzny (USB1 ASM1153E ;-))
Okazało się (po chwilowym odłączeniu zewnętrznego), że podpięty docelowy to
sda, natomiast wewnętrzny źródłowy to sdb.
# dd /?
BusyBox v1.18.1 (2013-04-12 18:16:31 PHT) multi-call binary.
Usage: dd [if=FILE] [of=FILE] [bs=N] [count=N] [skip=N] [seek=N]
Copy a file with converting and formatting
Options:
if=FILE Read from FILE instead of stdin
of=FILE Write to FILE instead of stdout
bs=N Read and write N bytes at a time
count=N Copy only N input blocks
skip=N Skip N input blocks
seek=N Skip N output blocks
Zamiast obrazu nie prościej skopiować sektor za sektorem?
-----
Dawno nie używałem openwrt ale zobacz czy działa np:
lsblk lub blkid
Jeśli nie to szansa jest, że ten dysk to będzie np. /dev/sda.
ls -l /dev/sd*
Jeśli będą i inne sdX to najpewniej ten, który ma też sdXn (n=1,2.. etc., czyli
np. sda1)
Wtedy z chałupy odpal dowolnego Linuksa i np. tak:
ssh user@server dd if=/dev/sda bs=2M|dd of=sciezka/lokalny.img bs=2M status=progress
|