Proper way to use 'ssh-agent' and 'ssh-add' ?
William Park
opengeometry-FFYn/CNdgSA at public.gmane.org
Sun Feb 5 01:04:37 UTC 2006
On Sat, Feb 04, 2006 at 07:41:57PM -0500, Robert Brockway wrote:
> On Sat, 4 Feb 2006, William Park wrote:
>
> >What is proper way to use 'ssh-agent' and 'ssh-add'?
> >
> >Manpage says, 'ssh-agent' is to be run within login console, like
> > eval `ssh-agent -s`
> >and killed with
> > eval `ssh-agent -s -k`
> >If I put that in ~/.profile, then I have to type my passphrase on every
> >login console or xterm. Very painful.
> >
> >I would like to run 'ssh-add' once, either at console or Xterm; and,
> >after that, all my ssh activities should lookup 'ssh-agent', whether I'm
> >at virtual consoles or Xterms.
>
> I have the following at the end of my ~/.xsession, to use ssh-agent with
> X:
>
> # Allow ssh-agent to kick off the window manager ($MANAGER)
> ssh-agent bash -c "ssh-add < /dev/null && $MANAGER"
>
> $MANAGER is the full path to your window manager set earlier in the
> script.
I'm doing a variation of above, right now.
eval `ssh-agent -s`
ssh-add
startx
It takes care of all ssh activities from that point on, as long as I do
stay on X.
But, I also use multiple virtual consoles. That's the problem.
Does every user need his/her own 'ssh-agent'? Or, is single 'ssh-agent'
(say, from /etc/rc.d/...) enough for whole machine?
--
William Park <opengeometry-FFYn/CNdgSA at public.gmane.org>, Toronto, Canada
ThinFlash: Linux thin-client on USB key (flash) drive
http://home.eol.ca/~parkw/thinflash.html
BashDiff: Super Bash shell
http://freshmeat.net/projects/bashdiff/
--
The Toronto Linux Users Group. Meetings: http://tlug.ss.org
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://tlug.ss.org/subscribe.shtml
More information about the Legacy
mailing list