Using Rsync to transfer files between servers

We’ve been getting a lot of migration requests from folks who want to moving their existing accounts over to Reclaim Hosting. We offer to migrate over anyone’s hosting account for free, which means you get to see the inner workings of a lot of web hosting companies. When a hosting company doesn’t use CPanel, that often means a manual migration of files and databases which, depending on the account, can take a lot of time. It’s when you are in a situation where you want to be fast and have more control that you realize why people use the dreaded command line.

Despite the server work I’ve been doing over the last few months I’m still relying heavily on the GUI interfaces of WHM and CPanel. But more recently that has started to change. Here and there I’ve been asking Tim for quicker ways to get stuff done, and one came up yesterday that was an insane timesaver. While moving the great Jonathan Worth‘s Phonar empire over to Reclaim, I was faced with a manual file move because his host isn’t using CPanel. This was daunting because he as a fairly hefty file load. While preparing for the move I realized his host provides SSH access which means I could login via terminal and rsynch all his file to his account on the reclaim server. It literally took about 2 or 3 minutes to move everything with one command:

rsync -avz .

Note that jonathan is both the username and the folder name for his CPanel account, that’s the identifier CPanel uses to create accounts. So the command above is run in the public_html directory of the web hosting account I want to transfer stuff off of. In terms of the rsync variables, you can see a list of the arguments that will explain the -avz.


So I am filing this away as yet another sysadmin trick I need to remember so that the next time I come up against a hosting company that doesn’t use CPanel I can at least transfer all the files with a single command. #sysadmin4life

This entry was posted in reclaim, Uncategorized and tagged , . Bookmark the permalink.

One Response to Using Rsync to transfer files between servers

  1. Pingback: New Year, New Digs for the bava | bavatuesdays

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.