Skip to content

sshfs 2.10 freezes when mount dir is in $PATH #216

@gwillem

Description

@gwillem

Thanks for making & maintainin sshfs!

I know I am reporting about an old version, but it's the one shipped with Ubuntu 20.04 LTS and it may be a useful reference for others. Been pulling my hair for days about this one.

Symptom: sshfs hangs on a syscall during mounting, will stay in D status, and other processes (notably ps, man) hang as well, until the sshfs process has been terminated with a SIGKILL.

$ sshfs -odebug,sshfs_debug,loglevel=debug -d -o idmap=user -o uid=1000 -o gid=1000 -o IdentityFile=/tmp/key -o IdentitiesOnly=true root@sshserver: /home/willem/.shared
SSHFS version 2.10.0
FUSE library version: 2.9.9
nullpath_ok: 0
nopath: 0
utime_omit_ok: 0
executing <ssh> <-x> <-a> <-oClearAllForwardings=yes> <-ologlevel=debug> <-oIdentityFile=/tmp/key> <-oIdentitiesOnly=true> <-2> <root@sshserver> <-s> <sftp>
^Cread: Interrupted system call

This happened to me after upgrading from Ubuntu 16.04 to 20.04. The latter has sshfs version 3.6.0+repack+really2.10-0ubuntu1, I'm not sure what went on in that odd package naming, but sshfs self-reports version 2.10.

I've done some experimenting, and can only reproduce the hang for a specific mount dir. Specifically, mounting on /home/willem/.shared does NOT work, but mounting on /home/willem/.shared2 (or anything else really) does work.

The hang only occurs when mounting as user. When mounting (using exact same location/paths/keys) as root it does work normally.

Removing and recreating /home/willem/.shared does not help.

Running the sshfs -d-reported ssh command line does work fine.

Unsetting SSH_AUTH_SOCK does not help (nor using -oIdentitiesOnly)

I have tried several SSH servers but it did not seem to matter.

lsof -n | grep .shared does not list anything.

Alternative paths with the same length, and exactly same permissions do work fine.

I have completely disabled apparmor, just to be sure.

I am unsure how to debug further, as strace does not seem to work on sshfs when ran as user (and I cannot reproduce the error when ran as root).

It does not depend on my hardware or network connection, because I have the same problem on both desktop & laptop (both after a clean Xubuntu 20.04 install)

Regular SSH connections to these locations work fine.

For now, I have solved it by picking a different mount path.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions