FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo User

 
 
LinkBack Thread Tools
 
Old 05-06-2008, 09:44 PM
David
 
Default back up gentoo system

Hi,

I was thinking on making regular backup of my gentoo partition. I'm not
interested in incremental backups, just a mirror image of the root
filesystem. I've prepared some scripts using dd for the first copy and
rsync to keep it updated. How do you make your backups?
Any improvements?.

Thanks in advance
 
Old 05-06-2008, 09:54 PM
"Andrew MacKenzie"
 
Default back up gentoo system

+++ David [gentoo-user] [Tue, May 06, 2008 at 11:44:46PM +0200]:
>
> Hi,
>
> I was thinking on making regular backup of my gentoo partition. I'm not
> interested in incremental backups, just a mirror image of the root
> filesystem. I've prepared some scripts using dd for the first copy and
> rsync to keep it updated. How do you make your backups?
> Any improvements?.
I've used bacula in the past to do backups. It's very full featured but
also rather complicated for simple backups.

These days I use an rsync-based backup script I wrote called 'yarbs' (yet
another rsync backup system).

It uses rsync and hard links to keep X days of backups. Easy to use, easy
to recover from, easy to setup. I can make it available if anyone's
interested.

If you're using 'dd' does that mean you're copying the entire filesystem
and not just the files? I believe that can run you into some issues if the
FS isn't read-only...

--
// Andrew MacKenzie | http://www.edespot.com
// GPG public key: http://www.edespot.com/~amackenz/public.key
// Some programming languages manage to absorb change, but withstand
// progress.
// - Alan Perlis
 
Old 05-06-2008, 09:55 PM
"Mark Knecht"
 
Default back up gentoo system

On Tue, May 6, 2008 at 2:44 PM, David <dcorraly@googlemail.com> wrote:
>
> Hi,
>
> I was thinking on making regular backup of my gentoo partition. I'm not
> interested in incremental backups, just a mirror image of the root
> filesystem. I've prepared some scripts using dd for the first copy and
> rsync to keep it updated. How do you make your backups?
> Any improvements?.
>
> Thanks in advance
>

See my recent (over the weekend) thread entitled "tar a brand new
Gentoo install to a USB drive for safe keeping?"

about using tar to save a brand new system.

In that thread one person pointed me toward this page:

http://blinkeye.ch/mediawiki/index.php/GNU/Linux_System_Backup_Script_(stage4)

which I tried out. It seemed to work OK for me. I had to edit jsut a
coupl eof lines to work with my setup
but other than that I got a number of backups created. Not too difficult.

- Mark
--
gentoo-user@lists.gentoo.org mailing list
 
Old 05-06-2008, 10:13 PM
Volker Armin Hemmann
 
Default back up gentoo system

On Dienstag, 6. Mai 2008, David wrote:
> Hi,
>
> I was thinking on making regular backup of my gentoo partition. I'm not
> interested in incremental backups, just a mirror image of the root
> filesystem. I've prepared some scripts using dd for the first copy and
> rsync to keep it updated. How do you make your backups?
> Any improvements?.
>
> Thanks in advance


tar -c -b 128 / --exclude=/proc --exclude=/dev --exclude=/sys | mbuffer -m
800M -p 95 -s 65536 -D 32G -A "mtx -f /dev/sg2 next" -f -o /dev/st0
--
gentoo-user@lists.gentoo.org mailing list
 
Old 05-06-2008, 10:18 PM
David
 
Default back up gentoo system

On Tuesday 06 May 2008 23:54:08 Andrew MacKenzie wrote:
> +++ David [gentoo-user] [Tue, May 06, 2008 at 11:44:46PM +0200]:
> > Hi,
> >
> > I was thinking on making regular backup of my gentoo partition. I'm
> > not interested in incremental backups, just a mirror image of the root
> > filesystem. I've prepared some scripts using dd for the first copy and
> > rsync to keep it updated. How do you make your backups?
> > Any improvements?.
>
> I've used bacula in the past to do backups. It's very full featured but
> also rather complicated for simple backups.
>
> These days I use an rsync-based backup script I wrote called 'yarbs' (yet
> another rsync backup system).
>
> It uses rsync and hard links to keep X days of backups. Easy to use, easy
> to recover from, easy to setup. I can make it available if anyone's
> interested.
>
> If you're using 'dd' does that mean you're copying the entire filesystem
> and not just the files? I believe that can run you into some issues if the
> FS isn't read-only...

What kind of issues? The idea is to copy the whole filesystem to another disk
and keep it sync. And in case of "crisis" use dd from the backup to the
original disk.
 
Old 05-06-2008, 10:32 PM
"Andrew MacKenzie"
 
Default back up gentoo system

+++ David [gentoo-user] [Wed, May 07, 2008 at 12:18:58AM +0200]:
> On Tuesday 06 May 2008 23:54:08 Andrew MacKenzie wrote:
> > If you're using 'dd' does that mean you're copying the entire filesystem
> > and not just the files? I believe that can run you into some issues if the
> > FS isn't read-only...
> What kind of issues? The idea is to copy the whole filesystem to another disk
> and keep it sync. And in case of "crisis" use dd from the backup to the
> original disk.
There is the possibility that something changes on disk and you've already
copied the 'references' to it in the journal or index. Thus making your
image inconsistent or corrupted. You also have files cached in memory not
yet written to disk, etc. It's also very inefficient copying all the empty
parts of your file system as well.

At the least you'll want to mount your file system read-only if you're
going to use dd to make a copy.


--
// Andrew MacKenzie | http://www.edespot.com
// GPG public key: http://www.edespot.com/~amackenz/public.key
// You have acquired a scroll entitled 'irk gleknow mizk'(n).--More--
//
// This is an IBM Manual scroll.--More--
//
// You are permanently confused.
// -- Dave Decot
 
Old 05-06-2008, 10:41 PM
"Andrew MacKenzie"
 
Default back up gentoo system

+++ David [gentoo-user] [Wed, May 07, 2008 at 12:18:58AM +0200]:
> What kind of issues? The idea is to copy the whole filesystem to another disk
> and keep it sync. And in case of "crisis" use dd from the backup to the
> original disk.
I should note I'm assuming you're backing up a mounted filesystem. If not
then there's nothing wrong with dd.

--
// Andrew MacKenzie | http://www.edespot.com
// GPG public key: http://www.edespot.com/~amackenz/public.key
// Whoever has lived long enough to find out what life is, knows how deep a debt
// of gratitude we owe to Adam, the first great benefactor of our race. He
// brought death into the world.
// -- Mark Twain, "Pudd'nhead Wilson's Calendar"
 
Old 05-06-2008, 10:52 PM
Volker Armin Hemmann
 
Default back up gentoo system

On Mittwoch, 7. Mai 2008, David wrote:
> On Tuesday 06 May 2008 23:54:08 Andrew MacKenzie wrote:
> > +++ David [gentoo-user] [Tue, May 06, 2008 at 11:44:46PM +0200]:
> > > Hi,
> > >
> > > I was thinking on making regular backup of my gentoo partition. I'm
> > > not interested in incremental backups, just a mirror image of the root
> > > filesystem. I've prepared some scripts using dd for the first copy and
> > > rsync to keep it updated. How do you make your backups?
> > > Any improvements?.
> >
> > I've used bacula in the past to do backups. It's very full featured but
> > also rather complicated for simple backups.
> >
> > These days I use an rsync-based backup script I wrote called 'yarbs' (yet
> > another rsync backup system).
> >
> > It uses rsync and hard links to keep X days of backups. Easy to use,
> > easy to recover from, easy to setup. I can make it available if anyone's
> > interested.
> >
> > If you're using 'dd' does that mean you're copying the entire filesystem
> > and not just the files? I believe that can run you into some issues if
> > the FS isn't read-only...
>
> What kind of issues? The idea is to copy the whole filesystem to another
> disk and keep it sync. And in case of "crisis" use dd from the backup to
> the original disk.

Andrew has a point. dd is not a good choice. FS don't like it if some parts of
them are in a different state than others.

Also, with dd, everytime you restore, you also restore fragmentation - oh and
a bigger partition? Can be tricky.

There is nothing wrong with tar. In fact tar is great for this job. dd not.
--
gentoo-user@lists.gentoo.org mailing list
 
Old 05-07-2008, 06:02 AM
Michael Schmarck
 
Default back up gentoo system

David <dcorraly@googlemail.com> wrote:

>
> Hi,
>
> I was thinking on making regular backup of my gentoo partition. I'm not
> interested in incremental backups, just a mirror image of the root
> filesystem. I've prepared some scripts using dd for the first copy and
> rsync to keep it updated. How do you make your backups?

I wouldn't do DD images. Too inflexible.

I do backups using rsnapshot, which basically just makes a copy with
rsync of all the files on all the filesystems.

> Any improvements?.

Dump dd.

Michael

--
gentoo-user@lists.gentoo.org mailing list
 
Old 05-07-2008, 06:05 AM
Michael Schmarck
 
Default back up gentoo system

David <dcorraly@googlemail.com> wrote:
> On Tuesday 06 May 2008 23:54:08 Andrew MacKenzie wrote:

>> If you're using 'dd' does that mean you're copying the entire filesystem
>> and not just the files? I believe that can run you into some issues if
>> the FS isn't read-only...
>
> What kind of issues?

If the fs is mounted read/write, it can very easily happen, that the
filesystem isn't "consistent"; ie. you start to read from the source
and when you get to the end, stuff has changed.

If you really must use dd (why?), I would *VERY* much urge to use LVM
snapshots.

But in reality, I'd rather use rsync to keep the two discs in sync.

> The idea is to copy the whole filesystem to another
> disk and keep it sync. And in case of "crisis" use dd from the backup to
> the original disk.

And why dd? What do you think you gain by using dd, compared to the
more traditional way of copying just all the files (be it with tar,
be it with rsync or even with plain cp)?

Michael

--
gentoo-user@lists.gentoo.org mailing list
 

Thread Tools




All times are GMT. The time now is 03:51 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org