Optimum way to copy JFFS2 f-s to backup/restore mtd partition ?

MikeW mw_phil at yahoo.co.uk
Thu May 17 12:37:11 EDT 2007


OK, I can manually use the MTD ioctl()s or mtd-utils to erase,
and then read()-write() or dd or cp(io) between the /dev/mtdX ... mtdY.

I was hoping there might be a mtd-util that would do repeated erase-copy sector,
maybe using 'zero-copy' operations like sendfile(). Not yet !

So, what might be the recommended 'best' way to achieve this transfer,
based on experience of the underlying implementation ?

And if just copying file-by-file into an empty partition, is there any benefit
(space overhead; fragmentation) to be had by ordering the files being copied
in any particular way ... by size; by directory; by frequency of use ?

Best regards,
Thx,
MikeW






More information about the linux-mtd mailing list