Has rsync changed? Can't rsync from Linux any more

Discuss backup and restore functions of the DiskStation with respect to computer clients, such as Synology Data Replicator, Time Machine, or other client backup software.
Forum rules
We've moved! Head over to Synology Community (community.synology.com) to meet up with our team and other Synology enthusiasts!
TrevorN
Trainee
Trainee
Posts: 13
Joined: Mon Apr 24, 2017 12:38 pm

Has rsync changed? Can't rsync from Linux any more

Unread post by TrevorN » Sat Mar 17, 2018 12:34 pm

I have had a DS1515+ for three years and in that time have regularly run an rsync command from a Linux box in my network to maintain a backup on the NAS. Recently the NAS bricked itself with the dreaded Intel chip bug and I sent it away for repair. When I put the fixed unit back into my network, the same rsync command failed.
On my Linux box the command I've been running is

Code: Select all

sudo rsync -aHv --exclude-from=backup-exclude.list / backup@[i]n.n.n.n[/i]:/backups/[i]server[/i]/full_rsync_backup
What I am seeing now when I run this is

Code: Select all

sending incremental file list
ERROR: module is read only
rsync error: syntax or usage error (code 1) at main.c(1131) [Receiver=3.0.9]
rsync: connection unexpectedly closed (112 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(226) [sender=3.1.1]
Before I sent this unit away the command ran successfully. When it was returned I ran through the standard procedure for migrating the old hard drives into the unit and everything seemed to work.
The DSM version is now reported as DSM 6.1.5-15254 Update 1
Since rsync started failing I have verified that the rsync service is enabled (it is), that the backup user has read/write access to the /backups, /backups/server and /backups/server/full_rsync_backup directories (it does), I added the backup user to the administrators group in case that made any difference (it didn't), and verified that the backup user can ssh to the NAS (it can).

I'm not sure what might have changed nor what else to check. The Synology documentation on this use case is out of date and/or incorrect.

Can anyone shed some light on this for me please?

Cheers
T

TrevorN
Trainee
Trainee
Posts: 13
Joined: Mon Apr 24, 2017 12:38 pm

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by TrevorN » Sun Mar 18, 2018 1:17 pm

As it happens the command

Code: Select all

rsync -aHv / backup@n.n.n.n::NetBackup/server/full_rsync_backup
works just fine, so that's what I've switched to. But I didn't have to use NetBackup a couple of months ago, and all the files were on the NAS in backups/server/full_rsync_backup to prove it.

mwheinz
I'm New!
I'm New!
Posts: 4
Joined: Mon Feb 13, 2017 11:41 pm

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by mwheinz » Wed May 09, 2018 10:07 pm

I just discovered I'm having the same issue. Did you ever find a solution?

mwheinz
I'm New!
I'm New!
Posts: 4
Joined: Mon Feb 13, 2017 11:41 pm

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by mwheinz » Wed May 09, 2018 10:25 pm

Sorry - looks like my error was due to a change in my ssh configs. It's working again.

TrevorN
Trainee
Trainee
Posts: 13
Joined: Mon Apr 24, 2017 12:38 pm

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by TrevorN » Thu May 10, 2018 12:00 pm

I never found out why rsync to the backups directory stopped working ; my solution was to rsync to the Netbackup app instead, which is working fine.

There is one slight downside to this, which is that I am mirroring this diskstation to a second diskstation (via shared folder sync) and so the sync signals potential issues overwriting the second diskstation's Netbackup content.

You say that you found something wrong in your config that fixed your problem, can I ask what it was? Maybe it's my problem too.

User avatar
sciurius
Sharp
Sharp
Posts: 160
Joined: Thu Sep 05, 2013 9:35 am

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by sciurius » Thu May 10, 2018 12:36 pm

Did you try --rsync-path option?

rsync --rsync-path=/usr/bin/rsync ...
DS418 / DSM 6.2-23739 Update 2 / 2 x WD40EFRX-68WT0N0 (SHR) / MailServer / MailStation / ownCloud / Transmission / ResilioSync / Syncthing / spotweb / LMS+Spotify
DS413 / DSM 6.2-23739 Update 2 / 2 x ST3000DM001-1CH166 (SHR) / Testing

TrevorN
Trainee
Trainee
Posts: 13
Joined: Mon Apr 24, 2017 12:38 pm

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by TrevorN » Thu May 10, 2018 12:46 pm

No. That illustrates what I mean when I said the Synology documentation is poor, I can't find rsync-path in any of the knowledgebase documents that refer to rsync :-)

Have I understood this right: I need to specify the path to rsync on the DS in the rsync-path switch on the rsync command on my Linux source?

User avatar
sciurius
Sharp
Sharp
Posts: 160
Joined: Thu Sep 05, 2013 9:35 am

Re: Has rsync changed? Can't rsync from Linux any more

Unread post by sciurius » Thu May 10, 2018 6:48 pm

I need to specify --rsync-path=/usr/bin/rsync on the linux box that wants to rsync with the synology nas.

Code: Select all

% rsync -avH -n jv@nas1:./ ./
Permission denied, please try again.
rsync: connection unexpectedly closed (0 bytes received so far) [Receiver]
rsync error: error in rsync protocol data stream (code 12) at io.c(226) [Receiver=3.1.3]
Exit 12
% rsync --rsync-path=/usr/bin/rsync -avH -n jv@nas1:./ ./
receiving incremental file list
...etc...
The error message is either "permission denied" or "readonly module".
DS418 / DSM 6.2-23739 Update 2 / 2 x WD40EFRX-68WT0N0 (SHR) / MailServer / MailStation / ownCloud / Transmission / ResilioSync / Syncthing / spotweb / LMS+Spotify
DS413 / DSM 6.2-23739 Update 2 / 2 x ST3000DM001-1CH166 (SHR) / Testing

Locked

Return to “Backup/Restore for computer clients”