You are not logged in.

#1 2015-11-07 05:41:05

still_human
Member
Registered: 2015-11-07
Posts: 6

[SOLVED] Backing up to USB with rsync: "Operation not permitted (1)"

I'm attempting to create a full system backup on a USB drive using rsync, following these instructions. I have already successfully created a backup in /media/backup using this method (just to ensure it works).

When attempting to use the USB as the backup destination, I enter the following:

sudo rsync -aAXv --exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/home/lost+found"} /* /mnt/USB/backup

What appears to be several hundred files copy successfully, and then the terminal emulator simply stops displaying new output. After waiting for several minutes, I press Ctrl+C to stop the process, and I get many lines of output like this one:

rsync: chown "/mnt/USB/backup/home/(my username)/.cache/chromium/Default/Cache/(filename)" failed: Operation not permitted (1)

I have searched for a solution to the Operation not permitted (1) rsync error, but there doesn't seem to be a general fix for this problem.

My USB drive is fat32. My SSD has the following partition scheme:

sda1: fat32, /boot (EFI System Partition)
sda2: ext4, /
sda3: reiserfs, /var
sda4: ext4, /home

Does this have something to do with attempting to copy files from one filesystem to another (ext4 to fat32)?

Also, out of curiosity, why does the output just stop and wait to display the error messages until I cancel with Ctrl+C?

Thanks in advance.

Last edited by still_human (2015-11-07 18:36:18)

Offline

#2 2015-11-07 08:28:54

SaltySockets
Member
Registered: 2015-10-10
Posts: 22

Re: [SOLVED] Backing up to USB with rsync: "Operation not permitted (1)"

FAT doesn't support UNIX permissions which are used on all the typical UNIX/BSD/Linux filesystems. NTFS supports user permissions, ownership etc but that doesn't use the UNIX standard either so if you want to back up, do so on a filesystem that supports the UNIX file permissions and ownership. You can backup to a FAT or NTFS filesystems but you have to tell rsync to ignore the ownership and permissions but then all of it will be cleared and it will be useless when you want to restore from backup since all of the important UNIX permissions will be gone. There are ways to get around this but as you say, there's multiple ways. You can use TAR to backup to FAT, which is the easiest way but if you want rync features then it's a bit trickier.

Offline

#3 2015-11-07 18:35:43

still_human
Member
Registered: 2015-11-07
Posts: 6

Re: [SOLVED] Backing up to USB with rsync: "Operation not permitted (1)"

Yep, it worked with ext2. Thank you.

Offline

Board footer

Powered by FluxBB