Repository: borgbackup/borg

Issue:
Can't mount on ubuntu. Missing dependencies ?
Trying to mount a backup archive on ubuntu 16.04 fails with:
`# borg mount ~/.backup/ /tmp/pqp/`
`Loading fuse support failed [ImportError: No module named 'llfuse']`

I have installed borgbackup from ubuntu repositories. Is there any missing dependencies on ubuntu packages ?

> `# dpkg -l | grep -i fuse`
> ii  exfat-fuse                                  1.2.3-1                                    amd64        read and write exFAT driver for FUSE
> ii  fuse                                        2.9.4-1ubuntu3.1                           amd64        Filesystem in Userspace
> ii  gvfs-fuse                                   1.28.2-1ubuntu1~16.04.1                    amd64        userspace virtual filesystem - fuse server
> ii  ifuse                                       1.1.2-0.1build3                            amd64        FUSE module for iPhone and iPod Touch devices
> ii  libfuse2:amd64                              2.9.4-1ubuntu3.1                           amd64        Filesystem in Userspace (library)
> ii  ntfs-3g                                     1:2015.3.14AR.1-1build1                    amd64        read/write NTFS driver for FUSE



Discussion:
borg mount needs llfuse.

http://packages.ubuntu.com/xenial-updates/borgbackup

it recommends python3-llfuse, but does not require it.

apt-get install python3-llfuse

Thanks ! It worked ! Before closing this, shouldn't this package be a dependency in ubuntu repositories ? I dont know who mantains the package, but it should be warned.

IMHO, if one of borg features depends on this package, it should be a dependency, not a suggestion =)

Well, you can use borg without using borg mount, so it is somehow optional.
As long as llfuse is available, one of course wants to have it. But llfuse is a bit of a fragile thing concerning platform support.

@LocutusOfBorg ^^^

eh, I'm stick to what upstream suggests

```
# msgpack pure python data corruption was fixed in 0.4.6.
# Also, we might use some rather recent API features.
install_requires = ['msgpack-python>=0.4.6', ]

extras_require = {
    # llfuse 0.40 (tested, proven, ok), needs FUSE version >= 2.8.0
    # llfuse 0.41 (tested shortly, looks ok), needs FUSE version >= 2.8.0
    # llfuse 0.41.1 (tested shortly, looks ok), needs FUSE version >= 2.8.0
    # llfuse 0.42 (tested shortly, looks ok), needs FUSE version >= 2.8.0
    # llfuse 1.0 (tested shortly, looks ok), needs FUSE version >= 2.8.0
    # llfuse 2.0 will break API
    'fuse': ['llfuse<2.0', ],
}
```

If you want me to make it a real dependency just ask, if you think suggest is too weak

Well, the python-based setup has it optional, because building llfuse quite frequently has issues (e.g. on the BSDs). But if a distribution always has a well-built functioning llfuse package of suitable version, there is maybe nothing against making it a requirement, so people don't run into missing it.

Tagging this "documentation", so we can add a note for package maintainers with the result of this discussion.

Fixed in git https://anonscm.debian.org/cgit/collab-maint/borgbackup.git/commit/?id=b231fdc8ecf623852f2667bc2805609fd8172407

Thanks! Good that there is a way to exclude platforms for a requirement. ;)

OK, so I'll add a line in setup.py and requirements.d/fuse.txt that package maintainers shall add llfuse as requirement for borg on all platforms where llfuse is available and working.


Resolving patch:
diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -21,12 +21,17 @@
 # Also, we might use some rather recent API features.
 install_requires = ['msgpack-python>=0.4.6', ]
 
+# note for package maintainers: if you package borgbackup for distribution,
+# please add llfuse as a *requirement* on all platforms that have a working
+# llfuse package. "borg mount" needs llfuse to work.
+# if you do not have llfuse, do not require it, most of borgbackup will work.
 extras_require = {
     # llfuse 0.40 (tested, proven, ok), needs FUSE version >= 2.8.0
     # llfuse 0.41 (tested shortly, looks ok), needs FUSE version >= 2.8.0
     # llfuse 0.41.1 (tested shortly, looks ok), needs FUSE version >= 2.8.0
     # llfuse 0.42 (tested shortly, looks ok), needs FUSE version >= 2.8.0
     # llfuse 1.0 (tested shortly, looks ok), needs FUSE version >= 2.8.0
+    # llfuse 1.1.1 (tested shortly, looks ok), needs FUSE version >= 2.8.0
     # llfuse 2.0 will break API
     'fuse': ['llfuse<2.0', ],
 }


Test patch: