I have a script that uses rsync to transfer with verification, but it fails randomly and I’m not sure why. Is there a better option to mount a network drive with smb or cifs and transfer files with verification (currently just running this with a cron job).
It really depends… Among other things:
- Local LAN or remote (Internet)
- Target? NAS, another NethServer? Synology will NOT allow root access,so you will have perms issues. I often have to add in the following options: --no-perms --no-owner --no-group
SMB can work, mounting as NFS is often better, less overhead for Linux to Linux communication.
Sometimes it works better mounting the remote as NFS, then rsynching locally (albeit slower, but it works!). SMB mounting is much slower.
My 2 cents
Andy
Sometimes, if target host allows, it’s better to setup native rsync daemon (873/tcp) and transfer files without NFS/SMB/CIFS at all.