Debian 12 Nautilus can't connect to sftp

Hello!!!

I have a fresh Debian 12 installation and an upgrade from Debian 11. I’ve notice that both of them can’t connect anymore to my raspberry pi (Debian11) through sftp. I have another machine that’s still on Debian 11 and it connects flawlessly. Every time I try with Bookworm I get a message saying it was unable to access location. CLI sftp works as expected. Raspberry restrict authentication to ssh keys. What can be the cause of this problem and how to fix it?

Hi,
It seems to work on a Debian Bookworm upgraded from Bullseye.
Here is what I do :

  • in Nautilus, click on “+ Other locations”,
  • in the “Connect to server” field, I enter : “sftp://username@hostname”,
  • I click on “Connect” button,
  • and if required, I provide the password to access to my ssh key.

A new remote location is displayed on the Nautilus left panel.
The content of my remote home is displayed and I can navigate through the remote folder tree.

Can you tell us how to reproduce your problem step by step ?

Is access to other location than your raspberry pi OK ?

Regards

I had set up another machine (debian 11) with ssh just for a new try, but got the same results: only cli sftp works - Nautilus asks for credentials (other locations → sftp://[user]@[ip address] → connect), but, at the end, it shows the same failure message.

Does the message provide a reason for the location access failure ?

Something like “Permission denied”, “Connection timed out” or something else ?

I run my distro in portuguese (my native language). The message just say something like “unable to access location” followed by “connection failed”.

Ok, can you follow steps in this documentation :
https://wiki.gnome.org/Projects/gvfs/debugging#Getting_debug_logs
and provide the gvfsd.log file ?

Here’s my gvfsd.log file:

trash: Added new job source 0x5604c8ba40e0 (GVfsBackendTrash)
trash: Queued new job 0x5604c8ba4880 (GVfsJobMount)
trash: send_reply(0x5604c8ba4880), failed=0 ()
trash: backend_dbus_handler org.gtk.vfs.Mount:CreateFileMonitor (pid=7316)
trash: Queued new job 0x5604c8ba4be0 (GVfsJobCreateMonitor)
trash: send_reply(0x5604c8ba4be0), failed=0 ()
recent: Added new job source 0x563d408780f0 (GVfsBackendRecent)
recent: Queued new job 0x563d40879020 (GVfsJobMount)
recent: reloading recent items
recent: send_reply(0x563d40879020), failed=0 ()
recent: backend_dbus_handler org.gtk.vfs.Mount:QueryInfo (pid=7316)
recent: Queued new job 0x563d40860210 (GVfsJobQueryInfo)
recent: send_reply(0x563d40860210), failed=0 ()
trash: backend_dbus_handler org.gtk.vfs.Mount:QueryInfo (pid=7316)
trash: Queued new job 0x5604c8b8cb50 (GVfsJobQueryInfo)
trash: send_reply(0x5604c8b8cb50), failed=0 ()
trash: backend_dbus_handler org.gtk.vfs.Mount:QueryInfo (pid=7316)
trash: Queued new job 0x5604c8b8cbf0 (GVfsJobQueryInfo)
trash: send_reply(0x5604c8b8cbf0), failed=0 ()
network: Added new job source 0x556bba153080 (GVfsBackendNetwork)
network: Queued new job 0x556bba1689f0 (GVfsJobMount)
smb-network: g_vfs_backend_smb_browse_init: default workgroup = 'NULL'
smb-network: Added new job source 0x55e69ca8a080 (GVfsBackendSmbBrowse)
smb-network: Queued new job 0x55e69ca8f210 (GVfsJobMount)
INFO: Current debug levels:
  all: 10
  tdb: 10
  printdrivers: 10
  lanman: 10
  smb: 10
  rpc_parse: 10
  rpc_srv: 10
  rpc_cli: 10
  passdb: 10
  sam: 10
  auth: 10
  winbind: 10
  vfs: 10
  idmap: 10
  quota: 10
  acls: 10
  locking: 10
  msdfs: 10
  dmapi: 10
  registry: 10
  scavenger: 10
  dns: 10
  ldb: 10
  tevent: 10
  auth_audit: 10
  auth_json_audit: 10
  kerberos: 10
  drs_repl: 10
  smb2: 10
  smb2_credits: 10
  dsdb_audit: 10
  dsdb_json_audit: 10
  dsdb_password_audit: 10
  dsdb_password_json_audit: 10
  dsdb_transaction_audit: 10
  dsdb_transaction_json_audit: 10
  dsdb_group_audit: 10
  dsdb_group_json_audit: 10
Using netbios name DEBTT.
Using workgroup WORKGROUP.
smb-network: Erro ao resolver “WORKGROUP”: Nome ou serviço desconhecido
smb-network: Forcing NT1 protocol version
smb-network: do_mount - URI = smb://WORKGROUP
smb-network: do_mount - try #0 
parsed path: fname='smb://WORKGROUP' server='WORKGROUP' share='' path='' options=''
SMBC_check_options(): server='WORKGROUP' share='' path='' options=''
smb-network: looking up cached server 'WORKGROUP'\'IPC$', user 'WORKGROUP';'alex'
smb-network:   returning (nil)
smb-network: auth_callback - anonymous pass
smb-network: auth_callback - out: last_user = 'alex', last_domain = 'WORKGROUP'
smb-network: looking up cached server 'WORKGROUP'\'IPC$', user 'WORKGROUP';'alex'
smb-network:   returning (nil)
Opening cache file at /run/samba/gencache.tdb
tdb(/run/samba/gencache.tdb): tdb_open_ex: could not open file /run/samba/gencache.tdb: Permissão negada
gencache_init: Opening user cache file /home/alex/.cache/samba/gencache.tdb.
sitename_fetch: No stored sitename for realm ''
internal_resolve_name: looking up WORKGROUP#1d (sitename (null))
namecache_fetch: no entry for WORKGROUP#1D found.
resolve_lmhosts: Attempting lmhosts lookup for name WORKGROUP<0x1d>
startlmhosts: Can't open lmhosts file /etc/samba/lmhosts. Error was Arquivo ou diretório inexistente
resolve_hosts: not appropriate for name type <0x1d>
name_resolve_bcast: Attempting broadcast lookup for name WORKGROUP<0x1d>
sitename_fetch: No stored sitename for realm ''
internal_resolve_name: looking up WORKGROUP#1b (sitename (null))
namecache_fetch: no entry for WORKGROUP#1B found.
resolve_lmhosts: Attempting lmhosts lookup for name WORKGROUP<0x1b>
startlmhosts: Can't open lmhosts file /etc/samba/lmhosts. Error was Arquivo ou diretório inexistente
resolve_wins: WINS server resolution selected and no WINS servers listed.
resolve_hosts: not appropriate for name type <0x1b>
name_resolve_bcast: Attempting broadcast lookup for name WORKGROUP<0x1b>
sitename_fetch: No stored sitename for realm ''
internal_resolve_name: looking up WORKGROUP#20 (sitename (null))
namecache_fetch: no entry for WORKGROUP#20 found.
resolve_lmhosts: Attempting lmhosts lookup for name WORKGROUP<0x20>
startlmhosts: Can't open lmhosts file /etc/samba/lmhosts. Error was Arquivo ou diretório inexistente
resolve_wins: WINS server resolution selected and no WINS servers listed.
resolve_hosts: Attempting host lookup for name WORKGROUP<0x20>
resolve_hosts: getaddrinfo failed for name WORKGROUP [Nome ou serviço desconhecido]
name_resolve_bcast: Attempting broadcast lookup for name WORKGROUP<0x20>
smb-network: do_mount - [smb://WORKGROUP; 0] dir = (nil), cancelled = 0, errno = [111] 'Conexão recusada' 
smb-network: do_mount - (errno != EPERM && errno != EACCES), cancelled = 0, breaking
smb-network: send_reply(0x55e69ca8f210), failed=1 (Falha ao recuperar a lista de compartilhamento do servidor: Conexão recusada)
Performing aggressive shutdown.
smb-network: purging server cache
Context 0x7f4d10007c20 successfully freed
Freeing parametrics:
network: Couldn't create directory monitor on smb://x-gnome-default-workgroup/. Error: A localização especificada não está montada
dns-sd: Added new job source 0x563b986ab880 (GVfsBackendDnsSd)
dns-sd: Queued new job 0x563b986ac820 (GVfsJobMount)
dns-sd: send_reply(0x563b986ac820), failed=0 ()
dns-sd: backend_dbus_handler org.gtk.vfs.Mount:CreateDirectoryMonitor (pid=7364)
dns-sd: Queued new job 0x563b986acca0 (GVfsJobCreateMonitor)
dns-sd: send_reply(0x563b986acca0), failed=0 ()
dns-sd: backend_dbus_handler org.gtk.vfs.Mount:Enumerate (pid=7364)
dns-sd: Queued new job 0x563b986a8180 (GVfsJobEnumerate)
dns-sd: send_reply(0x563b986a8180), failed=0 ()
network: send_reply(0x556bba1689f0), failed=0 ()
network: backend_dbus_handler org.gtk.vfs.Mount:Enumerate (pid=7316)
network: Queued new job 0x556bba150b00 (GVfsJobEnumerate)
network: send_reply(0x556bba150b00), failed=0 ()
network: backend_dbus_handler org.gtk.vfs.Mount:QueryInfo (pid=7316)
network: Queued new job 0x556bba13b490 (GVfsJobQueryInfo)
network: send_reply(0x556bba13b490), failed=0 ()
network: backend_dbus_handler org.gtk.vfs.Mount:CreateDirectoryMonitor (pid=7316)
network: Queued new job 0x556bba183180 (GVfsJobCreateMonitor)
network: send_reply(0x556bba183180), failed=0 ()
network: Couldn't create directory monitor on smb://x-gnome-default-workgroup/. Error: A localização especificada não está montada
dns-sd: backend_dbus_handler org.gtk.vfs.Mount:Enumerate (pid=7364)
dns-sd: Queued new job 0x563b986a8390 (GVfsJobEnumerate)
dns-sd: send_reply(0x563b986a8390), failed=0 ()
network: backend_dbus_handler org.gtk.vfs.Mount:Enumerate (pid=7316)
network: Queued new job 0x556bba150bb0 (GVfsJobEnumerate)
network: send_reply(0x556bba150bb0), failed=0 ()
sftp: Added new job source 0x55cfc73f1080 (GVfsBackendSftp)
sftp: Queued new job 0x55cfc73d0f30 (GVfsJobMount)
sftp: spawn_ssh: ssh -oForwardX11 no -oForwardAgent no -oPermitLocalCommand no -oClearAllForwardings yes -oProtocol 2 -oNoHostAuthenticationForLocalhost yes -oControlMaster auto -oControlPath=/run/user/1000/gvfsd-sftp/%C -s pi sftp 
sftp: handle_login #1 initial_connection = 1 - user: (null), host: pi, port: -1
sftp: handle_login #1 - password_save: 0
sftp: handle_login #1 - ret_val: 1
sftp: stderr: unix_listener: cannot bind to path /run/user/1000/gvfsd-sftp/d726d0bea0333ba4154b9c8f9d5629c9e1cfac02.1VxB0A1nSK2fhIt2: No such file or directory
sftp: send_reply(0x55cfc73d0f30), failed=1 (Conexão falhou)
network: backend_dbus_handler org.gtk.vfs.Mount:Enumerate (pid=7316)
network: Queued new job 0x556bba150d10 (GVfsJobEnumerate)
network: send_reply(0x556bba150d10), failed=0 ()

All seems OK until :

Can you run :

pkill gvfs; pkill nautilus

then run nautilus again and provide the output of the following command :

ps -ef |grep gvfs

Can you also provide the output of :

dpkg -l |grep gvfs

> ps -ef |grep gvfs
alex        6149    6121  0 20:44 pts/0    00:00:00 grep gvfs

> dpkg -l |grep gvfs
ii  gvfs:amd64                                     1.50.3-1                               amd64        userspace virtual filesystem - GIO module
ii  gvfs-backends                                  1.50.3-1                               amd64        userspace virtual filesystem - backends
ii  gvfs-common                                    1.50.3-1                               all          userspace virtual filesystem - common data files
ii  gvfs-daemons                                   1.50.3-1                               amd64        userspace virtual filesystem - servers
ii  gvfs-fuse                                      1.50.3-1                               amd64        userspace virtual filesystem - fuse server
ii  gvfs-libs:amd64                                1.50.3-1                               amd64        userspace virtual filesystem - private libraries

Just discovered that Firejail is causing the problem. Running firecfg --clean solves it.

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