[Freedombox-discuss] corrupt FS inside image ? - Was: Re: FreedomBox Unstable Image 2012.1021 Available

Olivier Berger olivier.berger at it-sudparis.eu
Wed Nov 7 13:29:54 UTC 2012


Hi.

Nick M. Daly <nick.m.daly at gmail.com>
writes:

>
>   You can also install the image to your DreamPlug directly.  

I've tried and install the contents of the
freedombox-unstable_2012.1021_dreamplug-armel-card.img image to a 4GB SD
card, which was previously partitioned.

I've tried using kpartx to locally mount the contents of the immage
without success :

$ sudo kpartx -l freedombox-unstable_2012.1021_dreamplug-armel-card.img
loop0p1 : 0 262144 /dev/loop0 2048
loop0p2 : 0 3833856 /dev/loop0 264192
loop deleted : /dev/loop0

$ sudo kpartx -a freedombox-unstable_2012.1021_dreamplug-armel-card.img
device-mapper: resume ioctl on loop0p2 failed: Invalid argument
create/reload failed on loop0p2

:-(

FYI, 
$ sudo fdisk -lu freedombox-unstable_2012.1021_dreamplug-armel-card.img

Disk freedombox-unstable_2012.1021_dreamplug-armel-card.img: 1992 MB, 1992294400 bytes
255 heads, 63 sectors/track, 242 cylinders, total 3891200 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: 0x000767de

                                                 Device Boot      Start         End      Blocks   Id  System
freedombox-unstable_2012.1021_dreamplug-armel-card.img1            2048      264191      131072    b  W95 FAT32
freedombox-unstable_2012.1021_dreamplug-armel-card.img2          264192     4098047     1916928   83  Linux

Maybe this is because kpartx doesn't know how to proceed with a first
partition not starting at sector 1.

Anyway, using losetup, I managed to make the partition 2 mounted :
# losetup /dev/loop0 freedombox-unstable_2012.1021_dreamplug-armel-card.img -o $((264192 * 512))
# mount /dev/loop0 /mnt/freedom

However, some files can't be copied when I try to rsync to the SD card's
partition :
# rsync -atvz --progress --delete --exclude=boot /mnt/freedom/ /mnt/freedom2/
sending incremental file list
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Backend") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Config") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Configure") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Dist") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Internals") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Module") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/CPANPLUS/Shell") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/ExtUtils/CBuilder") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/ExtUtils/Command") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/ExtUtils/Constant") failed: Input/output error (5)
rsync: readlink_stat("/mnt/freedom/usr/share/perl/5.14.2/ExtUtils/Liblist") failed: Input/output error (5)
[...]
rsync: readlink_stat("/mnt/freedom/usr/share/zoneinfo/right") failed: Input/output error (5)
IO error encountered -- skipping file deletion

sent 584182 bytes  received 2979 bytes  106756.55 bytes/sec
total size is 1027245570  speedup is 1749.51
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1070) [sender=3.0.9]

Have any others had better results ?

Thanks in advance.

Best regards,
-- 
Olivier BERGER 
http://www-public.it-sudparis.eu/~berger_o/ - OpenPGP-Id: 2048R/5819D7E8
Ingenieur Recherche - Dept INF
Institut Mines-Telecom, Telecom SudParis, Evry (France)




More information about the Freedombox-discuss mailing list