14

How to restart the whole gvfs "subsystem", when I've e.g. killed a frozen gvfs-sftp process and want to use it again?

GVFS is the subsystem that takes care about mounting/unmounting drives when you click them in Nautilus, including network drives.

The problem is that sometimes the transfer freezes and I need to kill the frozen "provider" (e.g. the gvfs-sftp). But then I can no longer connect to any network drives in Nautilus using SFTP. Restarting the whole computer helps, but there probably is a better way.

I searched the whole /etc in my computer to find out how is this gvfs system started, but I didn't succeed.

2 Answers2

22

It shows that gvfs is automatically started with the first Nautilus instance (I still don't know how, but it does).

So to restart gvfs, just kill all the remaining process (killing the "master" gvfsd daemon is enough), make sure all instances of nautilus are closed, and then open a new one.

killall gvfsd
nautilus -q  # Close all Nautilus windows/instances
nautilus
0

In Ubuntu 22.04 LTS it is enough to kill the gvfsd-sftp process in a Terminal with command:

killall gvfsd-sftp

It will be restarted as soon as nautilus has to open a new SFTP connection.
This also works in Linux Mint 21.3 MATE with caja.