sftp script running through crontab
From: Hideki Machida (jap_e2k_at_hotmail.com)
Date: 05/21/03
- Previous message: dhiraj.2.bhuyan_at_bt.com: "RE: Help with OpenSSH -> SSH2 Server"
- Next in thread: TooManyMirrors: "Re: sftp script running through crontab"
- Reply: TooManyMirrors: "Re: sftp script running through crontab"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: 21 May 2003 09:56:06 -0000 To: secureshell@securityfocus.com('binary' encoding is not supported, stored as-is)
This is the script that I am using.
---------------------------------------------------------
#!/bin/sh
DIR="/DIR"
LDIR="/LDIR"
LOG=aaa.gz
list="aaa.txt"
for i in `cat $list`
do
/usr/local/bin/sftp account@hostname <<EOF>/dev/null
cd $i/$DIR
lcd $i/$LDIR
mput $LOG
quit
EOF
done
-----------------------------------------------------------
The system is HP-UX.
Now the problem I am having is that when running this directly it executes
without a problem, yet when this is executed though cron it comes with the
following error.
$./script.sh
Warning: tcgetattr failed in ssh_rl_set_tty_modes_for_fd: fd 1: Not a
typewriter
If anybody can shed some light on this issue it would be of great help.
- Previous message: dhiraj.2.bhuyan_at_bt.com: "RE: Help with OpenSSH -> SSH2 Server"
- Next in thread: TooManyMirrors: "Re: sftp script running through crontab"
- Reply: TooManyMirrors: "Re: sftp script running through crontab"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|