Bug 216542 - sysutils/duplicity Python segfaults, related to librsync 2.0.0?
Summary: sysutils/duplicity Python segfaults, related to librsync 2.0.0?
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on: 216569
Blocks:
  Show dependency treegraph
 
Reported: 2017-01-28 10:29 UTC by FiLiS
Modified: 2017-02-25 18:46 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description FiLiS 2017-01-28 10:29:08 UTC
After we upgraded a couple of boxes to duplicity with the new librsync2 dependency, Python starts segfaulting, when there are backup sets in place. So we started new chains yesterday and today's backup scripts let Python segfault again. I searched around a bit and it seems, someone already filed an issue related to librsync2 here

https://answers.launchpad.net/duplicity/+question/284756

that links to this librsync2 PR

https://github.com/librsync/librsync/issues/50#issuecomment-183803254

and this relates to what we got in the core dump:

...
#0  0x0000000805c7f7df in rs_search_for_block () from /usr/local/lib/librsync.so.2
[New Thread 8086e5c00 (LWP 100222/<unknown>)]
[New Thread 8084f3000 (LWP 100418/<unknown>)]
[New Thread 802006400 (LWP 101415/<unknown>)]

So could we maybe go back to librsync1 until this is fixed in librsync 2.0.1 or import the patch?
Comment 1 Danilo G. Baio freebsd_committer freebsd_triage 2017-01-28 11:04:50 UTC
There is an update on the way for sysutils/duplicity on bug 216366
Could you try ?

Changes from 0.7.10 to 0.7.11:
https://launchpad.net/duplicity/0.7-series/0.7.11
Comment 2 FiLiS 2017-01-28 11:18:48 UTC
Yes, but 0.7.11 doesn't deal with the segfault issue I'm seeing and I'm currently with a few dysfunctional duplicity installations, would rather test when the segfaults are dealt with.
Comment 3 Danilo G. Baio freebsd_committer freebsd_triage 2017-01-28 11:37:50 UTC
(In reply to Philip Jocks from comment #2)
What about get this commit from upstream ?
https://github.com/librsync/librsync/commit/c2daedb5835f5301de50b44add166344e1ef6b02


Could you recompile librsync2 with this patch to see if it fixes the problem ?
http://dbaio.bs2cloud.com.br/FreeBSD/librsync2-1.patch
Comment 4 FiLiS 2017-01-28 12:16:31 UTC
yes, thank you! It seems to work on a testbox that segfaulted before the upgrade. Will check on a different machine with more failing backup sets and more data later and get back to you.
Comment 5 Danilo G. Baio freebsd_committer freebsd_triage 2017-01-28 12:18:21 UTC
(In reply to Philip Jocks from comment #4)

Great, thank you.
I will wait your feedback before submit this patch.
Comment 6 FiLiS 2017-01-29 07:49:13 UTC
looks good. Tried some restores, all seems to be working again.
Comment 7 Danilo G. Baio freebsd_committer freebsd_triage 2017-01-29 12:41:48 UTC
(In reply to Philip Jocks from comment #6)

Thank you... patch submitted on bug 216569.
Comment 8 commit-hook freebsd_committer freebsd_triage 2017-01-30 21:35:57 UTC
A commit references this bug:

Author: bdrewery
Date: Mon Jan 30 21:34:51 UTC 2017
New revision: 432873
URL: https://svnweb.freebsd.org/changeset/ports/432873

Log:
  - Apply a patch from upstream for fix rs_search_for_block bug [1]
    Fixes a sysutils/duplicity crash [2]

  PR:		216569 [1]
  PR:		216542 [2]
  Obtained from:	https://github.com/librsync/librsync/commit/c2daedb5835f5301de50b44add166344e1ef6b02
  Submitted by:	Danilo G. Baio (dbaio) <dbaio@bsd.com.br>

Changes:
  head/net/librsync2/Makefile
  head/net/librsync2/files/
  head/net/librsync2/files/patch-src_search.c
Comment 9 Oleksandr Tymoshenko freebsd_committer freebsd_triage 2017-02-25 18:46:10 UTC
Fixed by the same patch as bug 216569.