borg icon indicating copy to clipboard operation
borg copied to clipboard

Borg mount from rclone mount, is it possible?

Open fullofcaffeine opened this issue 7 years ago • 6 comments

Have you checked borgbackup docs, FAQ, and open Github issues?

Yes

Is this a BUG / ISSUE report or a QUESTION?

Question

System information. For client/server mode post info for both machines.

Dell XPS 15, i7, 32GB RAM, 1TB SSD, Linux Mint 18.3

Your borg version (borg -V).

Borg 1.1.6

Operating system (distribution) and version.

Linux Mint 18.3

Hardware / network configuration, and filesystems used.

  • ext4
  • rclone v1.42
  • os/arch: linux/amd64
  • go version: go1.10.1

How much data is handled by borg?

Around 70GB.

Full borg commandline that lead to the problem (leave away excludes and passwords)

  • borg mount foo bar

Where:

  • foo is a (fuse) wasabi (s3-compatible) mount mounted by rclone. The mount from reclone works and is mounted successfully. It contains a borg repo:
foo $ ls                                                                                                                                                      [2.5.0]
config  data  hints.353  index.353  integrity.353  nonce  README
  • bar is where I'd like borg to mount this repo as a filesystem.

Describe the problem you're observing.

I backup to an intermediate server and then reclone borg repos to wasabi (s3-compatible storage). I'm testing the worst-case scenario: If the intermediate server/storage is down/corrupted, I'd like to:

  1. Mount the wasabi folder locally using rclone. That works.
  2. Mount that mount point mounted by rclone (that contains a borg repo) with borg mount. Effectivelly a fuse mount over a fuse mount.

At first sight, it seems to work: borg asks me for the repo password when I run this:

  • borg mount foo bar

Then it goes back to the prompt. However, when I try cd'ing into bar though, I get the following error message:

cd bar                                                                                                                                           [2.5.0]
cd: transport endpoint is not connected: bar

Would that happen because that's a fuse mount being mounted from a another fuse mount? Or am I missing something here?

Can you reproduce the problem? If so, describe how. If not, describe troubleshooting steps you took before opening the issue.

Reproduction steps are described above.

Include any warning/errors/backtraces from the system logs

See above.

fullofcaffeine avatar Oct 07 '18 05:10 fullofcaffeine

Use borg mount --foreground ... to see the problem it runs into.

borg then stays in the foreground and you have to use another terminal for the next steps.

If it stops working, have a look into the borg mount terminal again and if you see a traceback, add it to your bugreport here.

ThomasWaldmann avatar Oct 07 '18 11:10 ThomasWaldmann

@fullofcaffeine did you try this? ^^^

ThomasWaldmann avatar Dec 15 '18 22:12 ThomasWaldmann

@ThomasWaldmann Sorry, I did not have the time and I don't have access to the backup repos atm. I'll try to do this over the next few days.

fullofcaffeine avatar Dec 19 '18 21:12 fullofcaffeine

@fullofcaffeine did you try this? ^^^

I tried this, it works!!

userid avatar Jan 05 '19 07:01 userid

I was getting the same "Transport endpoint is not connected" on borg 1.1.17. I found this issue and tried running borg mount with the --foreground option expecting to find the error in the backtrace, but everything worked fine when borg mount was run with --foreground.

When running borg mount without --foreground I see the rclone error message

2021/08/08 13:25:51 ERROR : lock.exclusive/: Dir.Remove not empty

just after entering the passphrase for borg mount. When runing with the --foreground option there doesn't seem to be any problem when borg tries to remove the lock.exclusive directory.

The commands I used which gave the errors are: Terminal 1: rclone mount wasabi:borgrepo /mnt/borgrepo Terminal 2:

# borg mount /mnt/borgrepo /mnt/mounted-borg
Enter passphrase for key /mnt/borgrepo:
# ls /mnt/mounted-borg
/bin/ls: cannot access '/mnt/mounted-borg': Transport endpoint is not connected

But this works fine: Terminal 1: rclone mount wasabi:borgrepo /mnt/borgrepo Terminal 2: borg mount --foreground /mnt/borgrepo /mnt/mounted-borg (and enter passphrase) Terminal 3: ls -l /mnt/mounted-borg

After running borg umount there is no lock.exclusive directory left behind, and the lock.roster file is also removed.

af7567 avatar Aug 08 '21 12:08 af7567

Guess this should be reproduced with a current borg release, whether it still happens.

Also, the issue might be in the filesystem implementation of rclone mount.

ThomasWaldmann avatar Jul 31 '24 13:07 ThomasWaldmann