MRi
March 13, 2025, 9:47am
1
Hi Forum, seems things are overcomplicated - at least for me - so i kindly ask for help.
GOAL: RSYNC Data from TrueNasFolder to a SMB Share
Using the module i can configure a SMB Share however i dont know how to configure it to PUSH data to it.
Any pointers are welcome
ABain
March 13, 2025, 10:57am
2
Did you check this doc out?
Push vs Pull are set in the direction field
MRi
March 13, 2025, 11:09am
3
but how do i specify the SMB Share as a Target Location?
ABain
March 13, 2025, 12:46pm
4
If you’ve already configured an rsync module to the location you want to target, you just need to create a task to push to it:
MRi
March 13, 2025, 1:07pm
5
its still not clear how to configure the module.
1.) Do i need to enable the module? as i would specify the same host path again as in the rsync task … which wouldnt make sense
Or can this remain be disabled as i only need the SMB Share?
Which i configured as follows
edit: so i just got the error stating
At least one module must be configured and enabled
So in that case i guess the rsync module is not meant to push from local TrueNas to foreign SMB Client
edit: so just for testing, i enabled the module and created a rsync task using the current TrueNas IP ( as remote )
However, i will run into
rsync: [sender] failed to connect to 192.xxx.xxx.xxx (192.xxx.xxx.xxx): Connection refused (111)
rsync error: error in socket IO (code 10) at clientserver.c(139) [sender=3.2.7]
You would need to use Rsync to do a “local” transfer, which is not supported in TrueNAS, unless you do it manually with the command-line.
There was a feature request for this, I think.
1 Like
MRi
March 13, 2025, 2:38pm
7
i raised that FR in Rsync Task should allow local 2 local synchronisation ( Local Destination Target ) - Feature Requests - TrueNAS Community Forums
But your comment gave me the correct idea. I’ve mounted the SAMBA Share via CLI and will do rsync test
truenas_admin@truenas[~]$sudo mount -t cifs -o username=‘user’,password=‘password’,domain=WORKGROUP //192.168.178.56/TN-Sync-4TB /mnt/smb
truenas_admin@truenas[~]$ sudo rsync -rh /mnt/WD8TB/BACKUP /mnt/smb --ignore-existing --delete --info=progress2
227.10M 1% 1.05GB/s 0:00:00 (xfr#1, ir-chk=1058/1082)
MRi
March 14, 2025, 12:58pm
8
another observation that i am running with hgih CPU Utilisation. Any idea how to relax CPU … it seems the whole systme locks up
I couldn’t figure out how to configure Rsync Task to rsync between 2 datasets on same NAS or NAS → SMB share. I don’t think it’s supported via Rsync Tasks.
What I do is I run a cronjob that basically invokes rsync command.
1 Like
MRi
March 14, 2025, 2:38pm
10
@bugacha doing the same manually on CLI. Can you please show me how to create a cron for this.
Also do you use any specific Flags for SMB?
this is a job for local dataset sync
rsync -avhz --progress --inplace --delete /mnt/volume3/photos /mnt/volume1/
for SMB remote, I usually mount via something file this :
//nas3/photos /mnt/photos cifs credentials=/etc/smbcredentials,vers=3.0,_netdev,soft,nofail,noatime,actimeo=1800 0 0
1 Like
MRi
March 14, 2025, 2:50pm
12
great thanks. i’ll give this a try. the issue with my CPU Load seems to be related to SMB Oplocks which is disabeld on the target and now it doesnt lock up nor consume lots of CPU
MRi
March 14, 2025, 3:51pm
13
@bugacha can i somehow monitor the rsync process when using cron?
you can output stdout into a log file and tail it