Transferring sites from one server to another using FTP
We had to duplicate one site on another server today. And we had only FTP access to both the servers. The last time I had to do this, I used “mget” to download all files and folders from one server and then used a script to upload them to another server. It was a pain to create all the folders myself, and the script I used broke on certain file names.
So I wanted something better this time. Tried to hack up the script a bit, but did not have enough time before the go-live. Did some Google, and found out “lftp“. The command line linux tool is amazing! It does a lot of things! To download all the files from one server, I simply had to use the mirror option with source and destination folders. And to upload them back to the new server, I used the same option, but with a -R switch to reverse the process and upload files instead of downloading.
I wish I found this earlier!
Related posts:
- Recursively unlock files on Mac OS X I copied some songs from a CD and ended up...
- .bin and .cue files – combine to .iso on Mac OS X I got .bin and .cue files from a friend. And...
- Thunderbird Productivity Tip: Folder Views I was surprised when I discovered this feature! It helped...
- What will take you to the next level of greatness? I am in Ahmedabad for three days, working with Ashok...
- Introduction to Screencasting in Linux – recordMyDesktop Screencasting is a great way to share information. I use...
Take a look at rsync, its the perfect tool to maintain a sync.
Did i hear ftp
And oh yeah the mandatory link – http://rsync.samba.org/
Now what i used rsync was for maintaining an exact copy of 2 web hosts.
Kanti
10 Apr 07 at 1:11 pm
Try: sitecopy
Maintained by me
Kartik Mistry
10 Apr 07 at 6:54 pm
I wanted to use rsync, but it wouldn’t support FTP! And after using lftp a couple of more times after yesterday, I am liking it! It’s pretty neat!
Nirav
11 Apr 07 at 7:34 pm
How can I transfer my site from yahoo to another site?
Darlene Banks
15 Sep 07 at 7:58 pm
You can use a program like lftp, rsync, sitecopy – or simply FTP to transfer files. But I am not sure if you had scripting done with some Yahoo! specific language. I don’t know what Yahoo! is using for scripting now, should be PHP, but earlier their ecommerce solution etc had some Yahoo! specific things that wouldn’t work on other hosts unless ported.
Nirav
16 Sep 07 at 9:53 am