SUMMARY: running ssh in crontab



Hi,

Thanks to all for helping me.
I changes the definition of the varible SECHOST to SECHOST='hostname'-sec and
it
works pretty well.

Regards
Andreas

______________________________________________
Von: Nolz Andreas
Gesendet: Samstag, 21. Oktober 2006 13:31
An: 'sunmanagers@xxxxxxxxxxxxxxx'
Betreff: running ssh in crontab

Hello,

I want to run a script by crontab.
When I start toe script in a terminal window, it works pretty well. When I
try
to run it by a cron job, I get the message:
Usage: ssh [options] host [command]
triggered by the following line in the script:
ssh $SECHOST "cd /export/qip; tar xf trans.tar; rm /export/qip/named/*.jnl"
The variable SECHOST is set in the script (SECHOST=$HOSTNAME-sec).

How can I change the script to run it by a cron job?

Thanks in advance!
Best regards!
Andreas


The information contained in this e-mail message is privileged and
confidential and is for the exclusive use of the addressee. The person
who receives this message and who is not the addressee, one of his
employees or an agent entitled to hand it over to the addressee, is
informed that he may not use, disclose or reproduce the contents thereof.
_______________________________________________
sunmanagers mailing list
sunmanagers@xxxxxxxxxxxxxxx
http://www.sunmanagers.org/mailman/listinfo/sunmanagers



Relevant Pages

  • Re: DBD::Oracle problem with bind_param_inout and UTF-8
    ... Consider the following script ... ... This email is intended solely for the use of the addressee and may ... If you receive this email in error please immediately notify the ... sender and delete the email. ...
    (perl.dbi.users)
  • Re: Script Error
    ... BobW wrote: ... an e-mail message I get the following error message and printing fails ... Internet Explorer Script Error ...
    (microsoft.public.windows.inetexplorer.ie6_outlookexpress)
  • RE: start http request and move on
    ... start http request and move on ... another script, call systemand place it in the background so you original ... but the personal views of the originator. ... addressee, any disclosure, reproduction, distribution or other ...
    (perl.beginners)
  • Re: [PHP] variable substitution
    ... I have two variables declared in the global scope of a script. ... One is a string with a reference for substitution to the other ... intended to be an e-mail message body ->!SPAM. ...
    (php.general)
  • Re: how to output a file and send as email
    ... I have a vb script that send out email with attached a file as below. ... I am assuming that you're referring to a text file, ... to the body of the e-mail message. ... See the OpenTextFile method in this link: ...
    (microsoft.public.windows.server.scripting)