Tag: FTP

How to automate FTP-ing file to another FTP account?

We will be using shell script to automate the transfer between two FTP accounts. You’ll need shell access to the source FTP account. #!/bin/bash directory=”/home/raisya/public_html” filename=”test.txt” hostname=”ftp.destination.com” username=”dest” password=”qwerty” logfile=”ftpf.log” ftp -uni $hostname <>$logfile quote USER $username quote PASS $password lcd $directory put $filename quit EOF Explanation: directory=”/home/raisya/public_html” Assigning “/home/raisya/public_html” to directory. filename=”test.txt” Assigning “test.txt” to filename. hostname=”ftp.destination.com” Assigning “ftp.destination.com”…

Read More »