[ale] How to Automate FTP ????

Zhongbin Yu " <zyu at tc.net> Zhongbin Yu " <zyu at tc.net>
Mon May 24 10:46:01 EDT 1999


when you schedule the job on NT, make sure the system account (the
default account NT run its scheduled job as instead of the owner account
as UNIX cron does) has access to the resources (commands, network
drive, etc). If scheduled job mysteriously fails and you have no problem
from commandline, this could be it. Change the account the scheduled job
is being run by. (control panel/service/scheduler/startup...)

my 2c.

Jerry Yu
----------------------------------------------------------------------------
Systems Engineer	| zyu at tc.net
Premiere Technologies	| 404-262-8544(O)	1-800-979-1105 (P)
Atlanta, GA 30326	| ae.tc.net/dept/engineering/op/public/developer/zyu

On Mon, 24 May 1999, Bob Kruger wrote:

#At 06:22 AM 5/24/99 -0400, you wrote:
#
#>> Hi All,
#>>  well this is actually a help i need. I need to automate FTP to  a
#>> particular machine from my client an Windows NT
#>>  i want to upload data from this NT to a Unix box or an IBM S/390
#>> (mainframe) every 5 minutes ,but i am not able to automate the ftp to given
#>> IP address say for example i need to FTP data to 123.100.123.12 with a user
#>> id of 'xyz' and password 'abcd' with binary mode of transfer and a default
#>> directory of 'dir1' in the host. Any ideas??????
#>> Thanks.
#
#If I understand what you are driving at, you want to automate the upload
#from the NT machine, with the NT machine initiating the session.  If that
#is the case, here is a way that I do it daily.
#
#First, write out a batch file to call ftp.  Here is an example:
#
#@ECHO OFF
#C:
#CD c:\upload
#ftp -s:c:\bin\fileput.ftp linuxbox
#
#Note - file c:\bin\fileput.ftp is the ftp script you will run.  linuxbox is
#the name of the server.  You will have to substitute names as necessary.
#
#Now, you need to construct your script for using NT FTP.  Try something
#like this:
#
#fileput.ftp
#---------------------------------------
#login
#password
#hash
#prompt
#hash
#lcd c:\upload
#cd /serverdir
#binary
#mput filename.ext 
#bye
#quit
#exit
#----------------------------------
#"login" is your linux login.
#"password" is the password user "login" uses.
#"filename.ext" is the file name you want to upload from NT to the linux box.
#The rest is self explanatory.
#
#Make up your own or modify this.  Once this is working properly, use the
#task scheduler with NT to schedule for every five minutes.  
#
#I use something similar here at work to move production data to and from
#linux/NT machines.  It is as reliable as the software.  Expect the
#occasional lockup from NT, although it is rarely as frequent as most
#hardcore linuxphiles will tell you.  As for linux, expect it to run
#reliably until you reboot it...
#
#If you have any more questions, let me know, and I will be glad to assist.
#
#Regards - Bob Kruger
#






More information about the Ale mailing list