Skip to main content
Jul 6, 2022 1:24 PM UTC
Question

SSH Agent fails to start

I'm trying to use 1Password SSH to authenticate with Github. Followed the procedure in the documentation, but somehow the agent fails to start, from the logs, whenever I dis/enable the SSH agent feature:

ERROR 2022-07-06T15:16:41.378 tokio-runtime-worker(ThreadId(1)) [1P:/Users/builder/builds/BhfSvM9x/0/dev/core/core/ssh/op-ssh-agent/src/lib.rs:160] Unable to start agent: Ipc(Io(Io { kind: InvalidInput, inner: "" }))
ERROR 2022-07-06T15:16:41.378 tokio-runtime-worker(ThreadId(1)) [1P:/Users/builder/builds/BhfSvM9x/0/dev/core/core/ssh/op-agent-controller/src/desktop.rs:328] Ipc(Io(Io { kind: InvalidInput, inner: "" }))
ERROR 2022-07-06T15:16:41.378 tokio-runtime-worker(ThreadId(1)) [1P:ssh/op-agent-controller/src/desktop.rs:334] SSH Agent failed to start

My ~/.ssh/config:

Host *

IdentityAgent "~/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"

Some other output:

ssh-add -l

The agent has no identities.

ls -l /Users//Library/Group\ Containers/2BUA8C4S2C.com.1password/t/

total 0
srw------- 1 staff 0 Jul 6 14:54 s.sock

I've been spending hours to find the solution, but can't find a fix.
Tried oa: rebooting, reinstalling 1Password, renaming > 2BUA8C4S2C.com.1password.old to reset 1password.

Any help appreciated :)


1Password Version: 8.8.0
Extension Version: 2.3.6
OS Version: 12.3
Browser:_ Safari

8 replies

Jul 7, 2022 7:44 AM UTC

Maybe worth noting that all my SSH keys are in the 'Personal' keyvault (which is translated to 'Persoonlijk'?)

floris_1P
1Password Employee
1Password Employee
Jul 18, 2022 9:56 AM UTC

Could you send me the output of:

echo ~/Library/Group\ Containers/2BUA8C4S2C.com.1password/t/agent.sock | wc -c

Jul 19, 2022 6:19 AM UTC

Sure!

floris_1P
1Password Employee
1Password Employee
Jul 19, 2022 7:08 AM UTC

Ahh that explains it. It's very silly, but the reason this is happening is that the OS doesn't allow socket path lengths that long. We're working on finding an alternative there, but if you really want it to work now then you could consider changing your OS username or home dir to something shorter. That should fix it for now. We'll keep you posted here once we have a better solution. Apologies for the inconvenience.

Jul 26, 2022 1:53 PM UTC

Hey Floris, yeah company policy to have email addresses as OS username.
Thanks for the heads up, I'll wait patiently :)

1P_Tommy
1Password Employee
1Password Employee
Jul 26, 2022 2:04 PM UTC

Sorry for the need to do that Ampned Hopefully, the team can find something that may help here. Thanks for being part of the family.

Aug 4, 2022 8:49 AM UTC

Hey guys, I've just had a similar problem when running Rancher Desktop. The bypass was to replace the directory with a symlink to a different location with a shorter path.

Is that something that would be possible in this scenario as well?

Link to the corresponding issue: https://github.com/rancher-sandbox/rancher-desktop/issues/797

Aug 9, 2022 10:28 AM UTC

Hi @Ampned! Symlinking does not seem to be a viable solution for this issue, but we're working on another fix for this problem. We'll keep you posted.