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

Re: ssh passphrase



> Or something similar.  Basically I want to login to 30 machines and run some
> command but without having to enter my pass-phrase 30 times.  I know I could
> use expect (and will if no-one has a better suggestion).  But I'm sure there
> is a better way (why else would ssh-askpass exist?).

eval `ssh-agent`
ssh-add
(enter passphrase)

for i in ...;do
  ssh $i command
done

That should do it for you.

-- 
 -----------=======-=-======-=========-----------=====------------=-=------
/  Ben Collins  --  ...on that fantastic voyage...  --  Debian GNU/Linux   \
`     bcollins@debian.org  --  bcollins@openldap.org  --  bmc@visi.net     '
 `---=========------=======-------------=-=-----=-===-======-------=--=---'


Reply to: