Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 546144 - sys-fs/bedup: likely lastrite candidate
Summary: sys-fs/bedup: likely lastrite candidate
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo TreeCleaner Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-10 09:21 UTC by Michał Górny
Modified: 2018-10-12 16:15 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2015-04-10 09:21:03 UTC
Long story short, bedup was quite nice but it's poorly written and not maintained anymore. Major bugs are:

1. broken with new versions of alembic due to use of private APIs [1],

2. poor error handling, resulting in leftover mounts [2] and immutable files [3],

3. poor recursive design with some magic contextlib2 which results in recursion depth exceeded errors with many identical files [4],

4. unsafe dedup system call [5] which could result in some damage.

sys-fs/duperemove can be used as a replacement to some degree. It's definitely safer since the dedup is done kernel-side, i.e. the kernel ensures that the deduped blocks are actually the same. However, it lacks 'incremental' dedup that bedup had, and support for deduping whole files of any size (right now, it splits input into blocks of given size and discards any file smaller than that).

@treecleaner, how do you feel about lastriting bedup?

[1]:https://github.com/g2p/bedup/issues/55
[2]:https://github.com/g2p/bedup/issues/56
[3]:https://github.com/g2p/bedup/issues/57
[4]:https://github.com/g2p/bedup/issues/29
[5]:https://btrfs.wiki.kernel.org/index.php/Deduplication#bedup
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2015-10-25 12:01:52 UTC
It seems that upstream has resumed work on bedup and fixed most of the issues. There is also a WIP branch switching to safer ioctls. I guess this may be a reason to keep it. However, duperemove has gotten much better in the meantime as well.
Comment 2 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2018-09-13 16:17:12 UTC
The project is dead again, and masked since Oct 2015.  Let's finally lastrite it.
Comment 3 Larry the Git Cow gentoo-dev 2018-09-13 16:18:08 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=837744ce28ceaad6fac6b7350adda2941be11703

commit 837744ce28ceaad6fac6b7350adda2941be11703
Author:     Michał Górny <mgorny@gentoo.org>
AuthorDate: 2018-09-13 16:17:47 +0000
Commit:     Michał Górny <mgorny@gentoo.org>
CommitDate: 2018-09-13 16:17:47 +0000

    package.mask: Last rite sys-fs/bedup
    
    Bug: https://bugs.gentoo.org/546144

 profiles/package.mask | 2 ++
 1 file changed, 2 insertions(+)
Comment 4 Larry the Git Cow gentoo-dev 2018-10-12 16:15:13 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ac2e2b1a5f0cb3e89cb00d8dac066f6a2bbad215

commit ac2e2b1a5f0cb3e89cb00d8dac066f6a2bbad215
Author:     Michał Górny <mgorny@gentoo.org>
AuthorDate: 2018-10-12 16:10:53 +0000
Commit:     Michał Górny <mgorny@gentoo.org>
CommitDate: 2018-10-12 16:15:04 +0000

    sys-fs/bedup: Remove last-rited pkg
    
    Closes: https://bugs.gentoo.org/546144
    Signed-off-by: Michał Górny <mgorny@gentoo.org>

 profiles/package.mask            |  9 ---------
 sys-fs/bedup/Manifest            |  1 -
 sys-fs/bedup/bedup-0.10.1.ebuild | 26 --------------------------
 sys-fs/bedup/bedup-9999.ebuild   | 38 --------------------------------------
 sys-fs/bedup/metadata.xml        | 11 -----------
 5 files changed, 85 deletions(-)