Hi, On 15.03.2012 22:05, Brad Morgan wrote: > The BackupPC manual says: The best way to copy a pool file system, if > possible, is by copying the raw device at the block level (eg: using dd). > Could someone give an example of how to do this?
dd if=<source_partition> of=<target_partition> bs=4M > Can someone explain why the output file system doesn't get reduced to the > size of the input file system? Actually the output-filesystem is an exact copy of the source. (Be careful with xfs filesystems here, they don't like to mount the same uuid on the same machine twice.) If your target-partition is bigger, then you need to grow that filesystem after the dd-call finishes. > For example, I have a 127GB disk, /dev/hdb1, mounted via fstab on > /var/lib/backuppc. I have a new 200GB disk, /dev/hdd1, that I used fdisk to > create a single partition, mkfs.ext4 to create the file system, That mkfs-step is not necessary. > and mounted it on /mnt/tempBackupPC. this you should skip completely. > If I use "dd if=/dev/hdb1 of=/dev/hdd1" doesn't > this copy the partition table and file system metadata, superblocks, etc. > such that the output device will now look exactly like the input device > including being reduced in size from 200GB to 127GB? Notice the 1's in your command? These say that only the partition is copied, not the mbr and partition-table. But then the whole filesystem is copied exactly. Be careful with your additional mkfs and mount from above: the os will access that filesystem and might destroy the parts you just copied with dd. If you copy while that fs is mounted... Have fun, Arnold -- Dieses Email wurde elektronisch erstellt und ist ohne handschriftliche Unterschrift gültig. ------------------------------------------------------------------------------ This SF email is sponsosred by: Try Windows Azure free for 90 days Click Here http://p.sf.net/sfu/sfd2d-msazure _______________________________________________ BackupPC-users mailing list BackupPC-users@lists.sourceforge.net List: https://lists.sourceforge.net/lists/listinfo/backuppc-users Wiki: http://backuppc.wiki.sourceforge.net Project: http://backuppc.sourceforge.net/