Weblog Archive

Using sftp over ssh, and tar

Mon, 24 Mar 2008 at 13:08 • Chetan • Filed under Server side

As a WordPress user, most stuff I add or update towards my site content—pictures, themes, plugins—typically gets stored in wp-content; so this is a mighty important folder when it comes to backing-up. Here’s how I backup wp-content (as an alternative to rsync):

I login to my site via ssh, and navigate to the root of my WordPress installation, and run tar to archive (zip) the entire wp-content folder:

$ tar -zcvf allwpcontent.tar.gz wp-content/

This above creates a file named allwpcontent.tar.gz.

Now still over ssh, I start sftp and navigate to the root of my WordPress installation (again). From there, I download the zipped file:

sftp> get allwpcontent.tar.gz

Downloading the entire wp-content by zipping (or tarring) first is so much quicker than downloading the entire folder—file by file; and easy too.

, , ,

[ Ads ]

Related posts

Following list is auto-generated, based on this post's context as possibly related. You may, however, occasionally find some in this list unrelated, but nevertheless, we sincerely hope that you'll enjoy them too.

Respond privately

Comments are closed, but you may respond privately to “Using sftp over ssh, and tar.” (Your response will not be published.)

Nowhere § Snow in spring