Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][tlug] cron and lftp problems
- Date: Wed, 26 Jan 2005 17:59:55 +0900
- From: "Erin D. Hughes" <erin@example.com>
- Subject: [tlug] cron and lftp problems
Today I wrote 2 scripts 1 is a lftp script to log into a remote server get updated data 2 is a run script that runs the program and then writes the events to a log file Independently they both work, the lftp script can log in and dl files from the remote server, the run script can run the lftp script and writes the findings to the log file. The problem occurs when I try to cron the job. The script returns a error saying it cant find the lftp command. I am completely baffled by this cause I use this same script in several other places and in the same fashion and it always works like a dream. First Ver info Server Red Hat 7.2 Lftp Version 2.6.5 <code> Run script #!/bin/sh # source environment . /etc/profile # set logfile logfile="/home/httpd/xyzsite/xyzcom.log" #get the current date and time and put append it to the log file date >> "$logfile" # run script, log all output to file. /home/httpd/xyzsite/upload >> "$logfile" 2>&1 lftpscript *note this can not have any carriage returns or it will not work lftp -e 'set ssl:verify-certificate no && open ftp://user:pass@example.com && cd /localdir/html && lcd /remote/dir /on/remote/server && mirror -cn dir_to_copy && exit EOF' </code> Log file entries Wed Jan 26 17:34:22 JST 2005<--------- When I run from command line cd ok, cwd=/to_t-mark lcd ok, local cwd=/home/httpd/some dir Usage: exit [<exit_code>] Total: 3 directories, 4 files, 0 symlinks To be removed: 1 directory, 0 files, 0 symlinks Wed Jan 26 17:35:00 JST 2005<-----------When the cron job runs /home/httpd/sfcg/sfcg-ircom/upload: lftp: command not found Any thoughts on this would be appreciated. Thanks Erin<<attachment: winmail.dat>>
- Follow-Ups:
- Re: [tlug] cron and lftp problems
- From: Jake Morrison
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] perl, cgi, and moji-baki-SOLVED
- Next by Date: Re: [tlug] cron and lftp problems
- Previous by thread: RE: [tlug] sort
- Next by thread: Re: [tlug] cron and lftp problems
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links