Delete files
Please help me regarding below query.
I trying to copy binary files through FTP script which given below....what I want that after getting the file from the source server I would like to delete the file from the source server but only the files which I have ftp to my server. Is there anyway to do it? I understand ftp do not understand "if...then...else" or "while" statements. How can I go about doing it?
LOCALDIR=/backup/archive
REMOTESERVER=192.0.0.132
REMOTESERVER=/dump/archive
LOGIN=admin
PASSWORD=xyz
FTPLOG='/tmp/ftplog'
date >> $FTPLOG
cd $LOCALDIR
ftp -n $REMOTESERVER <<INPUT_END