rsync tasks fails after 11.3 upgrade

mattieu

Cadet
Joined
Nov 17, 2019
Messages
1
Hi,
After upgrading to 11.3, all my rsync tasks fails with the logs:
rsync: opendir "/mnt/tank/Documents/user2/Downloads" failed: Permission denied (13) IO error encountered -- skipping file deletion rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1191) [sender=3.1.3]

I run the tasks with another user (user1). This user has read/write rights on the directory:
$ ls -alFh /mnt/tank/Documents/user2 total 378 drwxrwxr-x 13 user2 gnas 13B 31 juil. 2018 ./ drwxr-xr-x 4 root gnas 4B 22 janv. 2015 ../ drwxrwx--- 5 user2 gnas 155B 31 juil. 2018 Downloads/ $ grep gnas /etc/group gnas:*:1002:user1,user2

When I run the exact same command line launched by the FreeNAS UI from a user1 shell, the rsync command succeeds:
$ /usr/bin/lockf -s -t 0 -k /mnt/tank/Documents/user2 /usr/local/bin/rsync -a -z --delay-updates --delete-delay -p -r -t --usermap='*:18000' --groupmap='*:18000' -e 'ssh -p 22 -o BatchMode=yes -o StrictHostKeyChecking=yes' /mnt/tank/Documents/user2 18000@dsthost.net:documents_user2 $

Have you an idea what's going on?
Cheers.
 

Caleb Land

Cadet
Joined
Dec 21, 2019
Messages
1
I'm getting a similar error here. I don't know if it's been since I upgrade to 11.3, since I have been playing with permissions, but I can run the lockf command from the command line as the user I specified in the gui, and it works ok.

If I recursively set the ACLs of my dataset to OPEN then the gui rsync task works, but if I restrict "everyone" it doesn't seem to work.

I'm getting the error:
Code:
lockf: cannot open /mnt/tank/backup/mojo_tools/db: Permission denied


I have to dig a little deeper, but there seems there is something going on with the rsync task
 

robertg

Cadet
Joined
Mar 9, 2020
Messages
4
I'm having the exact same problem

Code:
lockf: cannot open /mnt/myshare/share: Permission denied


It only happens with samba shares that have ACL permissions, normal shares work fine. Did anyone find a solution?
 

robertg

Cadet
Joined
Mar 9, 2020
Messages
4
My solution for now is to run Rsync as root with a cron job. Then I specify the needed user and the users authentication key for the receiving system in the rsync command line.

Example:
Code:
rsync -avzhe "ssh -p 22 -i /path/to/users/sshkey/admin/.ssh/id_rsa" /mnt/tank/myACLshare admin@192.168.1.2:/share/tank/test


This works and I am finally able to use Rsync with samba shares that have ACL permissions.
 

William Bravin

Contributor
Joined
Mar 16, 2016
Messages
195
hello all


I am new to rsync and i am trying to figure it out.

i read thorough these posts and i still do not see a solution for me. I run 2 freenas servers (11.3) and on the second server which i turn on once a week (through the GUI) I built 4 identical tasks all scheduled but for the moment i run them now. All the ACL of the data sets on both servers are owned by myself (wbravin) with full control. the tasks are for documents, music, movies and tv shows. All tasks are simple

all task with the exception of the one for tv shows work well when i go to run the task for movies it fails. So what could be wrong?

I do not know how to get to the logs to identify the problem. How do i get them?

can anyone please help

thank you
 
Last edited:

GregP

Dabbler
Joined
Mar 16, 2013
Messages
15
Yes, this has happened to me too. I have 5 freenas servers running 11.2 U8. I upgraded one of them to 11.3. It has happily been doing four PUSHes every 15 minutes to two other local servers and it started emailing failures right after the upgrade. Manually restarting the PUSH from the GUI sometimes succeeds and sometimes it doesn't. Sometimes it fails when there are changes and sometimes it fails when there is no change to make. Sometimes it fails to one server and sometimes to the other. The upgraded server only does PUSHes. I changed it to boot back into 11.2 U8 and the errors went away. These are servers that I need to be up and running so I have not yet set up a test situation from 11.3 to 11.2 U8 to try to troubleshoot. I'll need to figure out what is going on before upgrading past 11.2.
 

William Bravin

Contributor
Joined
Mar 16, 2016
Messages
195
@GregP HI Thank you for responding so quickly.. I got the notice of your response only today.

I read again this post and i followed the instruction set forth by @Caleb Land but to no avail. Unfortunately i already migrated to 11.3. I am not rolling it back to an older version. Do not need the hassle.

I hope the Freenas group will come up with a better solution.
 

GregP

Dabbler
Joined
Mar 16, 2013
Messages
15
Now that we are at 11.3 U5 I tried again. I just upgraded all 5 servers from 11.2-U8 to 11.3-U5. One of the servers has 4 rsync PUSH tasks running every 15 minutes to two of the others and has been happily doing that for a very long time. I again started receiving emails from the PUSH server. Usually 2/4 jobs would fail. Not always the same two. Sometimes manually running them would work and sometimes not. Reverting the one PUSH server to 11.2-U8 fixed the problem again. The receiving side works fine at 11.3-U5. Luckily, I did not upgrade the ZFS pools. The failing shares were SAMBA.
 

GregP

Dabbler
Joined
Mar 16, 2013
Messages
15
Update
Update to TrueNas 12.0 Release seems to fix the problem. Only seems to be required on the Push side.
 

hmidouch

Cadet
Joined
Jan 2, 2021
Messages
5
Restarting the PUSH from the GUI sometimes succeeds and sometimes it doesn't. Sometimes it fails when there are changes and sometimes it fails when there is no change to make. Sometimes it fails to one server and sometimes to the other. The upgraded server only does pushes.
192.168.100.1 192.168.1.1 jpg to pdf
 
Last edited:

William Bravin

Contributor
Joined
Mar 16, 2016
Messages
195
Top