How to use rsync command to copy folders from my dedicated server to a local hard drive or vice versa ?

What is Data Synchronization?

The Data Synchronization is a process to maintain the uniformity of data content with in folder, web several applications, databases or systems. There are different ways or different solutions for data synchronization which includes online software or some command through which you can sync your dedicated server to a local hard drive and vice versa. In multiple cases with in the existing information system, where data is managed separately by multiple applications or databases, yet needs to be kept consistent between these systems or you can say the need for data synchronization can either be permanent data synchronization between operational systems.

You can use the following command to copy the content from your home folder on the server to a backup directory on your local computer:

Step 1 :-
rsync -VA -e “ssh -p PORT” YOUR_Dedicatd_SERVER_IPADDRESS:/home/USERNAME/BACKUP /home/LOCAL_USER/
The above following command is used to copy the content where a client can synchronize his dedicated sever data folder to home folder.

Step 2 :-
rsync -VA -e “ssh -p PORT” /home/LOCAL_USER/BACKUP YOUR_Dedicatd_SERVER_IPADDRESS:/home/USERNAME/
The above following command is used to copy the content or a user can synchronize his home folder with his dedicated server folder.

Some Important Procedure Have to Follow :-

You just have to change
YOUR_Dedicatd_SERVER_IPADDRESS with the IPADDRESS of your server,
USERNAME with the cPanel username of the account you want to copy from,
LOCAL_USER/BACKUP with the path on your computer where you want the home folder to be copied.

The most important thing you have to take care that you can’t forget to add the trailing slashes after the folder names else wise there could be a lose of you important data when ever you are going to execute the above process.