billw2 / rpi-clone

A shell script to clone a booted disk.
BSD 3-Clause "New" or "Revised" License
2.56k stars 333 forks source link

Read-only file? #32

Open robustini opened 8 years ago

robustini commented 8 years ago

I try the latest version of your script and i've a lot of error during the cloning. I execute the script as root:

Starting the filesystem rsync to sda (This may take several minutes)...rsync: write failed on "/mnt/clone/usr/bin/git-upload-pack": Read-only file system (30)

Another if i use "-f" option:

rsync: chown "/mnt/clone/boot/bootcode.bin" failed: Operation not permitted (1)

rsync error: received SIGINT, SIGTERM, or SIGHUP (code 20) at rsync.c(632) [sender=3.1.1] rsync error: received SIGINT, SIGTERM, or SIGHUP (code 20) at io.c(504) [generator=3.1.1] ./rpi-clone: line 494: /mnt/clone//var/log/rpi-clone.log: No such file or directory

robustini commented 8 years ago

For help you in a possible debug this simply manual step work fine here:

http://sysmatt.blogspot.it/2014/08/backup-restore-customize-and-clone-your.html

The important switch for rsync imho is this one, it doesn't use "dd" for clone both the partition:

rsync -av --one-file-system / /boot /tmp/newpi/

SpoddyCoder commented 7 years ago

Hi @robustini - this issue should be resolved by the 1.6 release, please download & install latest rpi-clone. If this fixes your issue, please click close thanks! :)