ssh batch troubles

Paul Bryan pa_bryan at yahoo.co.uk
Thu Dec 12 00:02:54 EST 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wed, 11 Dec 2002 20:37, Howard Lowndes wrote:
> I am having problems running ssh in a batch job, specifically a cron
> script.  I am trying to pass a command to another box using ssh.
>
> I have tried the -n and -o "BatchMode yes" options to ssh but the job
> hangs just before it is due to close.
>
> Running the script from the command line works OK.
>
> Any clues?

When you run it from the command line, is it prompting for a password? I know 
this sounds obvious, but I've been caught out like this before. I just typed 
the password automatically when running from the command line and then 
wondered why the cron job didn't work!

Sometimes, the answer is so obvious that you just don't see it...

- -- 
Paul Bryan
E-Mail: pa_bryan at yahoo.co.uk
 
PGP Key
http://www.keyserver.net:11371/pks/lookup?op=get&search=0xB1D405DA
Fortune finishes the great quotations, #6

	"But, soft!  What light through yonder window breaks?"
	It's nothing, honey.  Go back to sleep.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE99zeA3qGyTLHUBdoRAkMnAKCSrtsKsv5FYAVCRfTphl4L4VfgKgCfTAMp
Wn5ZkEdetSM1LJYRJ+ch9fM=
=iSgb
-----END PGP SIGNATURE-----



More information about the linux mailing list