Question Locked

Automated FTP Script

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Greetings all. I've been trying to automate a task of mine quite unsuccessfully. I recently started using Linux and need to pull some files daily from another server. Can anyone help me. This is the logic of my task. I'm using SUSE 10.1

# ! /bin/bash

ftp 0.0.0.0
username XXXXX
password XXXX
prompt
cd /net-emg
lcd /collector/ER/SMS
find -mmin +2 -mmin -363 | mget PP.*
#new transfer
cd /nel-ecp
lcd /collector/ER/Voice
find -mmin +2 -mmin -363 | mget PP.*
bye
exit

5 replies

by tnt

You can try to use the expect command. It is for those automate interactive process, like your FTP.

by alpha_s

Thanks, I did some research into 'expect'.I may be able to work with this.

This discussion is closed to new replies.