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

Linux_Learner

New Member
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:


jglen490

Well-Known Member
Credits
1,981
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.
 

jglen490

Well-Known Member
Credits
1,981
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


Latest posts

Top