Rsync FreeNAS 9.2 --> TrueNAS Core 12 failing with "Operation not permitted" on non-existant files

pcubed

Cadet
Joined
May 10, 2021
Messages
7
Hi folks,

I'm trying to migrate an old FreeNAS 9.2 installation to the latest version of TrueNAS Core by moving the data via rsync. I initially noticed errors saying:

Code:
rsync: mkstemp "/mnt/Vol01/..." failed: Operation not permitted (1)


And so I looked around the forum and found this post which seemed suited to my use case (the two servers are both integrated into an AD via Samba and I want to keep all the ACLs). However, even after following the advice of desertrider, I'm getting the same errors but I've noticed that the files referenced don't actually exist according to the filename that rsync gives me. For example:

Code:
rsync: mkstemp "/mnt/Vol01/...MyDocument.doc.gLGA9e" failed: Operation not permitted (1)


You'll notice the .gLGA9e extension on the file. MyDocument.doc exists but not MyDocument.doc.gLGA9e. For all of the thousands of files I want to sync, they all fail (except the directories, which are all created with the ACLS preserved it seems) but they all have a different weird extension at the end.

I'm using rsync over SSH as root (both sender and receiver) with the following command:

Code:
[root@oldnas] /mnt/Vol01# rsync --partial --stats --progress -A -a -r -v --no-perms MyFolder root@newnas:/mnt/Vol01/


Any ideas what I'm missing ?
 

pcubed

Cadet
Joined
May 10, 2021
Messages
7
So it seems that the problem is with the temp files that rsync creates. It doesn't seem to be able to change the permissions on them, for whatever reason. Here is a StackOverflow thread explaining the same problem, but on Linux. Here is now the command that works

Code:
rsync --stats --progress -A -a -r -v --inplace MyFolder root@newnas:/mnt/Vol01/


I've also gotten into to work by specify the --temp-dir param but only in certain places. There's certainly some issue with the ACLs, but I have no idea what it might be. I've tried setting root as the owner of the directory and doing rsrync as root but it still won't work. Well, at least this is somewhat of a solution.
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
So it seems that the problem is with the temp files that rsync creates. It doesn't seem to be able to change the permissions on them, for whatever reason. Here is a StackOverflow thread explaining the same problem, but on Linux. Here is now the command that works

Code:
rsync --stats --progress -A -a -r -v --inplace MyFolder root@newnas:/mnt/Vol01/


I've also gotten into to work by specify the --temp-dir param but only in certain places. There's certainly some issue with the ACLs, but I have no idea what it might be. I've tried setting root as the owner of the directory and doing rsrync as root but it still won't work. Well, at least this is somewhat of a solution.


Probably a restricted aclmode on the dataset. Try specifying --no-perm in the rsync command.
 
Top