Unable to connect to ssh-agent - Linux


When attempting to ssh tunnel using the ssh-agent authentication method I get this error

Unable to connect to ssh-agent: java.io.IOException: failed to fctrl usocket: -1. Using ssh-agent during SSH key-based authentication process disabled.

All attempts to google this error have been unfruitful.

Additional Info fro Session Logs

2020-10-14 14:21:34,526 [ 318864] WARN - om.intellij.ssh.impl.sshj.sshj - Failed to connect. Brief info: SSH connection to root@xxxxx.com:22
* Compression methods from config: none
* With signature factories: ssh-rsa, ssh-dss, ecdsa-sha2-nistp256, ecdsa-sha2-nistp384, ecdsa-sha2-nistp521, ssh-ed25519, ssh-rsa-cert-v01@openssh.com
* With keep alive interval 120 seconds
* With keep alive count max 3
* With OpenSSH-like host key verifier (knownHostsFile=[/home/jarek/.ssh/known_hosts], strictHostKeyChecking=ASK, hashKnownHosts=false)
* With authentications allowed by the client: publickey, password, keyboard-interactive
* Connected
=> none (failure, new auth methods allowed by the server: publickey)
=> publickey /home/jarek/.ssh/id_rsa (empty password, the key was dismissed by the user)
net.schmizz.sshj.userauth.UserAuthException: Authentication failed.
at com.intellij.ssh.impl.sshj.SshjConnectionUtilKt.a(SshjConnectionUtil.kt:605)
at com.intellij.ssh.impl.sshj.SshjConnectionUtilKt.setUpSessionForSshJ(SshjConnectionUtil.kt:480)
at com.intellij.ssh.impl.SshConnection.a(SshConnection.kt:209)
at com.intellij.ssh.impl.SshConnection.c(SshConnection.kt:205)
at com.intellij.ssh.impl.SshConnection.a(SshConnection.kt:159)
at com.intellij.ssh.impl.SshConnection.getSshSession(SshConnection.kt:113)
at com.intellij.ssh.SshConnectionService.connect(SshConnectionService.kt:153)
at com.intellij.ssh.Ssh.b(ssh.kt:264)
at com.intellij.ssh.Ssh.access$connect(ssh.kt:1)
at com.intellij.ssh.ConnectionBuilder.connect(ssh.kt:113)
at com.intellij.database.dataSource.DatabaseSshTunnelEstablisher.createSshSession(DatabaseSshTunnelEstablisher.java:220)

Comment actions Permalink

could you please upload your ssh config and full ide logs to https://uploads.jetbrains.com/  and provide me with upload ID?


also it looks like the error is for 'fnctl' function, which stands for

1 EPERM Operation not permitted. An attempt was made to perform an operation limited to processes with appropriate privileges or to the owner of a file or other resources.

so you need to configure permissions on socket

Comment actions Permalink

Thank you, it was indeed a permissions issue. For future reference this was my experience.
I’m running manjaro.
I installed Datagrip from flatpak
The permissions were lacking when installed this way.
When I installed from source everything worked as expected.


Please sign in to leave a comment.