How to list current sshfs mounts to server?

Making an sshfs mount involves connecting across sftp. Hence, what you can do is look for the spawned sftp processes. Assuming the user andreas has made an sshfs mount, or logged in using regular sftp, you’ll see something along the following lines:

root@halleck:~# ps aux | grep -i sftp | grep -v grep
andreas  11029  0.0  0.0   2420   648 ?        Ss   23:56   0:00 /usr/lib/openssh/sftp-server
root@halleck:~#

alt.

root@halleck:~# ps aux | grep -i sftp | grep -v grep
andreas  11091  0.0  0.1   9564  1116 ?        Ss   23:57   0:00 sshd: andreas@internal-sftp
root@halleck:~#

What you see depend in what sftp Subsystem you have configured.

The details in this answer assumes OpenSSH server side.

Leave a Comment