1

I'm running Duplicity for backup of my desktop to a remote storage. Everything has been working fine, but now I see in my log that Duplicity has been exiting with exit status 23 for a couple of runs. As of what I can see the backups are running and the backups are uploaded to the remote computer.

The exit status 23 seems to only happen when it's run in the background as a cron-job. When I run the backup script manually I get a 0 exit status.

Duplicity's man page lacks info on the meanings of the programs exit statuses, so I don't really know where to start.

cat syslog.1 outputs:

...

Jan 23 12:54:35 xx anacron[998]: Job `cron.daily' started
Jan 23 12:54:35 xx anacron[4241]: Updated timestamp for job `cron.daily' to 2019-01-23
Jan 23 12:54:45 xx kernel: [  322.467223] EXT4-fs (sdb1): warning: maximal mount count reached, running e2fsck is recommended
Jan 23 12:54:45 xx kernel: [  322.473997] EXT4-fs (sdb1): recovery complete
Jan 23 12:54:45 xx kernel: [  322.474404] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
Jan 23 12:55:03 xx kernel: [  340.754000] EXT4-fs (sdc): recovery complete
Jan 23 12:55:03 xx kernel: [  340.794089] EXT4-fs (sdc): mounted filesystem with ordered data mode. Opts: (null)

...

7
  • 1
    What's the error output from cron? (It's probably being emailed to your local user account.) Commented Jan 22, 2019 at 21:51
  • @Christopher, Interesting, could you cite the source for that? Commented Jan 23, 2019 at 11:59
  • @roaima Good point! Will look into that! Commented Jan 24, 2019 at 19:37
  • 1
    I now have the exact same issue, after having the cron script run for 3 years. So thanks for closing the question guys, I doubt I would have rephrased it much differently than the OP. Oh, and this is the nr. 1 result on Google for "Duplicity error 23". This could have been helpful. Commented May 12, 2019 at 6:37
  • @zmippie this question appears to have been abandoned. Within a day of it being posted I asked for additional information, but none came. I'd suggest you post a new question with at least the amount of detail here (including error output from cron please), and flag this dead question here as a duplicate of your new one. (Flag with a moderator if you can't actually mark it as a dup.) Commented May 14, 2019 at 7:49

1 Answer 1

0

In my case, duplicity returned status code 23 (and the backup failed) because duplicity was unable to establish an ssh connection with the backup system.

I backup to a NAS on our intranet. In the script that runs the backup, I simply assumed that the NAS was always running and ready to accept ssh connections. Since the script was running under cron, I am using key exchange for authentication.

But if the NAS was down (which happened rarely), the duplicity command in the script would return status code 23.

The solution for me was to check the availability of the NAS and re-schedule the backup if the NAS was down.

Note, however, that there could be other reasons for this error code; the duplicity documentation appears (to me) to be silent on this issue. One could ready the Python code in an attempt to discover all possible reasons for exit(23), but that is beyond the scope of what I need to do.

1
  • As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center. Commented Mar 25 at 23:42

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.