DejaDup with duplicity and sftp

Request: May be dump the exact command that is being used so that diagnosis is possible.

  1. Do I assume DejaDup uses GIO to mount the file system and then does the job
  2. Would it be possible to directly do sftp like that of duplicity commandline (instead of mounting locally)?
  3. Command line using duplicity works fine
    duplicity --progress /home/username/Downloads sftp://username@example.com:1234/Downloads

With DejaDup Error is observed: Device: Ubuntu Jammy deja-dup: 42.9-1ubuntu3

Traceback (innermost last):
  File "/usr/bin/duplicity", line 92, in <module>
    with_tempdir(main)
  File "/usr/bin/duplicity", line 75, in with_tempdir
    fn()
  File "/usr/lib/python3/dist-packages/duplicity/dup_main.py", line 1555, in main
    action = commandline.ProcessCommandLine(sys.argv[1:])
  File "/usr/lib/python3/dist-packages/duplicity/commandline.py", line 1223, in ProcessCommandLine
    config.backend = backend.get_backend(args[0])
  File "/usr/lib/python3/dist-packages/duplicity/backend.py", line 223, in get_backend
    obj = get_backend_object(url_string)
  File "/usr/lib/python3/dist-packages/duplicity/backend.py", line 209, in get_backend_object
    return factory(pu)
  File "/usr/lib/python3/dist-packages/duplicity/backends/giobackend.py", line 96, in __init__
    self.remote_file.make_directory_with_parents(None)
 gi.repository.GLib.GError: g-io-error-quark: Unknown reason (0)

(A similar error message when the snap version of dejadup is installed - version that was available on - 16.03.2023)

Traceback (innermost last):
  File "/snap/deja-dup/553/bin/duplicity", line 87, in <module>
    with_tempdir(main)
  File "/snap/deja-dup/553/bin/duplicity", line 70, in with_tempdir
    fn()
  File "/snap/deja-dup/553/lib/python3.8/site-packages/duplicity/dup_main.py", line 1572, in main
    action = commandline.ProcessCommandLine(sys.argv[1:])
  File "/snap/deja-dup/553/lib/python3.8/site-packages/duplicity/commandline.py", line 1244, in ProcessCommandLine
    config.backend = backend.get_backend(args[0])
  File "/snap/deja-dup/553/lib/python3.8/site-packages/duplicity/backend.py", line 223, in get_backend
    obj = get_backend_object(url_string)
  File "/snap/deja-dup/553/lib/python3.8/site-packages/duplicity/backend.py", line 209, in get_backend_object
    return factory(pu)
  File "/snap/deja-dup/553/lib/python3.8/site-packages/duplicity/backends/giobackend.py", line 96, in __init__
    self.remote_file.make_directory_with_parents(None)
 gi.repository.GLib.GError: g-io-error-quark: Unknown reason (0)

You’re right that Deja Dup does not expose every duplicity backend. It does mostly go through GIO (except for a few cloud backends like MS or Google).

So debugging why you are getting that GIO error might be a good next step. Or in newer versions (43.2+, I think?) there is a hidden “custom-tool-wrapper” gsetting that could maybe do some real-time replacement of arguments. But that’s super hacky.

Does you sftp target work if you mount and browse it in Files/Nautilus? Can you make a directory there? (It seemed to die for Deja Dup when making a directory)

1 Like

Yes, sftp works with Nautilus.
Yes, I can make directory.

Even gftp (GUI) for sftp works fantastic. The remote server also works with duplicati but since duplicati’s future unclear I would like to move users to DejaDup Is duplicati alive or stable? · Issue #4889 · duplicati/duplicati · GitHub

Hmm that is troubling then. (That we are messing up where nautilus isn’t.) I’ll need to test and be able to reproduce to see why this happens.

What OS/distro/ssh server are you trying to talk to? I tried to reproduce with an Ubuntu 18.04 server, but couldn’t yet.

Both host and the server run Ubuntu 22.04 LTS. Due to security reasons there is no login shell possible on the server.

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.