Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


Hash: SHA1

Content-Type: text/plain; charset=us-ascii

jbk <jbk at> writes:

> No, this keychain is an open source shell script available from Gentoo that
> utilizes ssh-agent in such a manner that it is possible to start mutiple shells
> with out multiple instances of ssh-agent being generated each time.

If you use the "eval `ssh-agent`" syntax, you get that behavior. What 
I do on my home machine is 

    ssh-agent | head -2 > ~/.ssh/agent-id
    source ~/.ssh/agent-id

and my .bashrc contains 

    [ -e ~/.ssh/agent-id ] && source ~/.ssh/agent-id

I just have to start an ssh-agent once after rebooting the machine, 
then I just leave it running for weeks or months at a time. Every 
instance of bash I start up after that uses the one ssh-agent instance.

I haven't actually tried this on Windows, but given how well cygwin 
works in general, I would expect this to work correctly as well.

Note that the "head -2" is to eliminate the "echo" command that 
ssh-agent prints after the two "export" commands, because running that 
"echo" command from within the .bashrc causes scp and sftp to fail.

- --
John Abreau / Executive Director, Boston Linux & Unix
Email jabr at / WWW / PGP-Key-ID 0xD5C7B5D9
PGP-Key-Fingerprint 72 FB 39 4F 3C 3B D6 5B E0 C8 5A 6E F1 2C BE 99

Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Exmh version 2.5 07/13/2001


BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!

Boston Linux & Unix /