Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

It seems that ssh-agent is not starting on my OpenSuSE system. When I run pgrep -fl ssh-agent, the result is blank. On my Linux Mint laptop, I get 1785 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-session x-session-manager.

How do I fix this? Can anyone with OpenSuSE check to see if it's not started up by default, or if I maybe messed something up?

things tried...

I've tried adding the following to .xinitrc,

if test -S "$SSH_AUTH_SOCK" -a -x "$SSH_ASKPASS"; then
      ssh-add < /dev/null
fi

and my .xsession file contains,

ssh-agent {
  ssh-add &
  startkde
}

but neither of these things seems to do anything. Thanks in advance!!

share|improve this question
1  
I have this same issue on my KDE only machines. Other openSUSE machines running XFCE or GNOME have no issue and this service is automatically started, except for KDE. I would like to hear of your fix if you find one. –  SaultDon Aug 27 '12 at 18:15
add comment

1 Answer

OK, so yesterday I installed the new 12.2RC2 ("GM") and 12.1 on separate partitions, both using KDE.

After I upgraded everything to the latest packages and enabled the SSHD service, I restarted and generated a private/public key pair with ssh-keygen

On both machines the sshd was running - but ssh-add output an error about not being able to connect to authorization agent or something.

So I ran ssh-agent -k where the -k flag "killed" the current running agent and then re-ran ssh-agent to restart it.

Then I restarted the PCs (you might be able to just restart the sshd service instead) and it was working! I could then issue ssh-add without any errors.

It looks like on KDE desktops ssh-agent is not initialized properly when you first start the sshd service, it works fine on other DE like GNOME or XFCE.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.