Script to transfer backup from Hosting server to my synology server one account at a time.

Linux_Learner

New Member
Joined
Feb 20, 2020
Messages
1
Reaction score
0
Credits
0
Hi Linux pros,

I'm need to create a script and here's what it need to do:

1. SFTP to my Hosting Server (Linux) sftp [email protected]
2. Backup website accounts 1 at a time (This is due to server space).
3. Pull the backup to source server (Synology) and delete it in the hosting server after transfer.
4. Repeat step 1-3 until all accounts has been transferred successfully.

The script will be running from Task Scheduler in synology server.
Also I wonder if port forwarding is needed to do this?


Any help or direction would be appreciated.
 
Last edited:


I believe rsync can do this, and perhaps one of its GUI versions. I use rsync to make backups, but nothing that complex. You could try looking through the rsync man page.
 
Is the hosting server a Linux system? If you have proper permissions you could initiate the Linux script from anywhere, so the "from" location should not have to be your local machine. As I said, by rsync application is much simpler, but as I read the man page the from and to locations should be anywhere you have appropriate permissions.
 

Members online


Top