Front page

Backing up a server to a desktop

0dec044110ba406a8d4e1e8c7dfde265
ANCIENT UNICORN ADRIFT

From: Paul Waring <paul@xk7.net>
Date: Mon, 13 Jun 2016 17:26:27 +0100

   I have several servers which I'd like to backup to USB hard drives in
   the same way as I backup my desktop. They are all running Linux, and the
   only major difference is that the server is remote.
   
   Looking at the Obnam documentation, I notice that SFTP seems to come
   with warnings aobut performance, particularly when used on live data.
   
   How do other people get round this problem? The quick and dirty solution
   I can think of is to copy everything to my desktop using rsync, then
   back that up in the same way as my local directories.
From: Sharon Kimble <boudiccas@skimble.plus.com>
Date: Mon, 13 Jun 2016 18:36:52 +0100

   Paul Waring <paul@xk7.net> writes:
   
   > I have several servers which I'd like to backup to USB hard drives in
   > the same way as I backup my desktop. They are all running Linux, and the
   > only major difference is that the server is remote.
   >
   > Looking at the Obnam documentation, I notice that SFTP seems to come
   > with warnings aobut performance, particularly when used on live data.
   >
   > How do other people get round this problem? The quick and dirty solution
   > I can think of is to copy everything to my desktop using rsync, then
   > back that up in the same way as my local directories.
   
   I back up my blogs using obnam over SSH. I open a SSH-pathway to the
   server on start-up, and then the obnam backup just takes place using a
   cronjob. I use 'keychain' to create the SSH-pathway, and then it just
   happens as per cron.
   
   This happens over the normal phone lines and the server is possibly
   50-miles away, and its been happening now for about 5+ years with no
   problems at all.
   
   Thanks
   Sharon.
From: Lars Wirzenius <liw@liw.fi>
Date: Tue, 14 Jun 2016 10:07:02 +0300

   On Mon, Jun 13, 2016 at 05:26:27PM +0100, Paul Waring wrote:
   > I have several servers which I'd like to backup to USB hard drives in
   > the same way as I backup my desktop. They are all running Linux, and the
   > only major difference is that the server is remote.
   > 
   > Looking at the Obnam documentation, I notice that SFTP seems to come
   > with warnings aobut performance, particularly when used on live data.
   > 
   > How do other people get round this problem? The quick and dirty solution
   > I can think of is to copy everything to my desktop using rsync, then
   > back that up in the same way as my local directories.
   
   I rarely use sftp for live data. I usually rsync to a local disk and
   backup from there. The performance implication of sftp on live data
   are that every access results in a round trip across the network: one
   per directory (to get list of files), one for an lstat to see if the
   file has changed, at least one to read the file if it ha changed, etc.
   
   It's quite intricate to try to calculate how slow it will be. Try it
   and see and if the number of files is low enough, it might not be too
   bad.
   
   Another option is to mount the remote server with sshfs, which does
   some caching, I believe, and can be much faster.
From: Juergen Nickelsen <ni@w21.org>
Date: Tue, 14 Jun 2016 10:40:47 +0200

   On 14.06.2016 09:07, Lars Wirzenius wrote:
   
   > I usually rsync to a local disk and backup from there.
   
   Just as an aside, I backup to local disk (there is room to spare,
   fortunately) and rsync (with --delete) to a remote one. Liveness of data
   doesn't play such a big role here, and this has the advantage that the
   local backup is quite fast when I want to recover deleted files or the like.
   
   Only for disaster recovery I have to resort to the remote copy. I had to
   do this once, actually (magic smoke released, and I got a new server),
   so I rsynced the backup to local disk and restored from there.
   
   > Another option is to mount the remote server with sshfs, which does
   > some caching, I believe, and can be much faster.
   
   As that remote is hosted storage, I don't have ssh access (only rsync
   over ssh), but OTOH it has snapshots (ZFS), which could be helpful in
   case of e.g. an accidentally wiped obnam repository.
   
   I have learned to appreciate sshfs in other scenarios, though (accessing
   files on servers with a locally running Emacs etc.).
   
   Regards, Juergen.