Hi,
I have a script which uploads files successfully to another server via ftp. But after the files are uploaded, I want them to be deleted (removed), but it doesn't seem to work. I would appreciate if someone could help me out with this. How can I modify my script so that the uploaded files will be deleted after the ftp session?
Here's the script:
#!/bin/sh
cd /opt.../logs
Server="xx.xx.xx.xx"
Username="sonya"
Password="s2525"
DstDir="/files/son"
ftp -n $Server <<End-of-Session
user $Username $Password
binary
cd $DstDir
prompt
mput "go*"
bye
rm go*
End-of-session
exit 0
Thanks a lot,
Sonya