[toaster] Backups

2005-12-08 Thread Nikki Locke
Which files/directories should I include in my backup regime to avoid 
losing my hard-won qmail configuration? The idea is that, should the worst 
happen, I can apply the toaster to a new machine, then restore the backups, 
and everything will work as it used to.

I am currently backing up /var/qmail/users, /var/qmail/control, 
/var/qmail/alias and /home/vpopmail/domains, but excluding the Maildir 
directories. Anything else I should add? Anything I can remove (backup 
space costs money :-)?

Nikki

-- 
Nikki Locke, Trumphurst Ltd.  PC & Unix consultancy & programming
http://www.trumphurst.com/




RE: [toaster] Backups

2005-12-08 Thread Seferovic Edvin
Dont forget the vpopmail directory !

Regards,

Edvin

-Original Message-
From: Nikki Locke [mailto:[EMAIL PROTECTED] 
Sent: Donnerstag, 08. Dezember 2005 17:05
To: toaster@shupp.org
Subject: [toaster] Backups

Which files/directories should I include in my backup regime to avoid 
losing my hard-won qmail configuration? The idea is that, should the worst 
happen, I can apply the toaster to a new machine, then restore the backups, 
and everything will work as it used to.

I am currently backing up /var/qmail/users, /var/qmail/control, 
/var/qmail/alias and /home/vpopmail/domains, but excluding the Maildir 
directories. Anything else I should add? Anything I can remove (backup 
space costs money :-)?

Nikki

-- 
Nikki Locke, Trumphurst Ltd.  PC & Unix consultancy & programming
http://www.trumphurst.com/





Re: [toaster] Backups

2005-12-08 Thread Nikki Locke
Thanks!

Is that the /home/vpopmail directory? If so, do I need to back up anything 
outside /home/vpopmail/domains (which I already mentioned)?

Nikki

Seferovic Edvin wrote:
> Dont forget the vpopmail directory ! 
>  
> Regards, 
>  
> Edvin 
>  
> -Original Message- 
> From: Nikki Locke [mailto:[EMAIL PROTECTED] 
> Sent: Donnerstag, 08. Dezember 2005 17:05 
> To: toaster@shupp.org 
> Subject: [toaster] Backups 
>  
> Which files/directories should I include in my backup regime to avoid 
> losing my hard-won qmail configuration? The idea is that, should the worst 
> happen, I can apply the toaster to a new machine, then restore the backups, 
> and everything will work as it used to. 
>  
> I am currently backing up /var/qmail/users, /var/qmail/control, 
> /var/qmail/alias and /home/vpopmail/domains, but excluding the Maildir 
> directories. Anything else I should add? Anything I can remove (backup 
> space costs money :-)? 
>  
> Nikki



-- 
Nikki Locke, Trumphurst Ltd.  PC & Unix consultancy & programming
http://www.trumphurst.com/




Re: [toaster] Backups

2005-12-08 Thread eero

> I am currently backing up /var/qmail/users, /var/qmail/control,
> /var/qmail/alias and /home/vpopmail/domains, but excluding the Maildir

/var/qmail

> directories. Anything else I should add? Anything I can remove (backup
> space costs money :-)?

You can't be serious...

--
Eero


Re: [toaster] Backups

2005-12-08 Thread Nikki Locke
 wrote:
> > I am currently backing up /var/qmail/users, /var/qmail/control, 
> > /var/qmail/alias and /home/vpopmail/domains, but excluding the Maildir 
>  
> /var/qmail 
>  
> > directories. Anything else I should add? Anything I can remove (backup 
> > space costs money :-)? 
>  
> You can't be serious...

Why not? The server and a limited amount of space on a backup server comes 
at a fixed price. Additional backup space is extra.

Looking at the directories, /home/vpopmail wastes most of its space in the 
Trash folders, which I see no point in backing up.

-- 
Nikki Locke, Trumphurst Ltd.  PC & Unix consultancy & programming
http://www.trumphurst.com/




Re: [toaster] Backups

2005-12-08 Thread Alex Dean

On Dec 8, 2005, at 11:15 AM, Nikki Locke wrote:


You can't be serious...


Why not? The server and a limited amount of space on a backup  
server comes

at a fixed price. Additional backup space is extra.


Lost time rebuilding stuff due to inadequate backups also has a cost.

Are you using a commerical backup program, or just doing copies?  If  
you're using something like Arkiea or Retrospect, you can configure  
your backup sets to exclude the Trash folders but get everything else  
in ~vpopmail/domains.


regards,
alex
.





Re: [toaster] Backups

2005-12-08 Thread Nikki Locke
Alex Dean wrote:
> Lost time rebuilding stuff due to inadequate backups also has a cost. 

I agree, which is why I am trying to set up a script which backs up what is 
needed, without backing up unnecessary stuff.

> Are you using a commerical backup program, or just doing copies?  If   
> you're using something like Arkiea or Retrospect, you can configure   
> your backup sets to exclude the Trash folders but get everything else   
> in ~vpopmail/domains. 

I'm using a shell script which creates a compressed tar file. I've just 
changed it so it backs up /home/vpopmail/domains, but excludes */.Trash/* 
and */.Trash.

-- 
Nikki Locke, Trumphurst Ltd.  PC & Unix consultancy & programming
http://www.trumphurst.com/




Re: [toaster] Backups

2005-12-08 Thread Bob Hutchinson
On Thursday 08 Dec 2005 18:15, Nikki Locke wrote:
>  wrote:
> > > I am currently backing up /var/qmail/users, /var/qmail/control,
> > > /var/qmail/alias and /home/vpopmail/domains, but excluding the Maildir
> >
> > /var/qmail
> >
> > > directories. Anything else I should add? Anything I can remove (backup
> > > space costs money :-)?
> >
> > You can't be serious...
>
> Why not? The server and a limited amount of space on a backup server comes
> at a fixed price. Additional backup space is extra.
>
> Looking at the directories, /home/vpopmail wastes most of its space in the
> Trash folders, which I see no point in backing up.

If you don't want to backup actual mail, skip any folder called new/ cur/ or 
tmp/ under /home/vpopmail/domains/*. Skipping Maildir/ will also skip the 
imap or sqwebmail stuff, probably not what you want. This is pretty easy if 
you use rsync which will also minimise bandwidth and preserve permissions

HTH
-- 
-
Bob Hutchinson
Midwales dot com
-


Re: [toaster] Backups

2005-12-09 Thread GoodnGo.de \(R\) Zentrale
Hello Bob,

do this for tarring:

#> cd /;tar -c -z -P -V `date` -B -p -f
/where_you_want_to_tar/file_to_tar.tar.gz  /var/qmail/users
/var/qmail/control /var/qmail/alias /home/vpopmail/domains -X Maildir new
cur &

That´s all, Hope to help from merry old germany ...
-
Oliver Etzel
Hostmaster www.domainfex.de
now Tomcat - Serving



> On Thursday 08 Dec 2005 18:15, Nikki Locke wrote:
> >  wrote:
> > > > I am currently backing up /var/qmail/users, /var/qmail/control,
> > > > /var/qmail/alias and /home/vpopmail/domains, but excluding the
Maildir
> > >
> > > /var/qmail
> > >
> > > > directories. Anything else I should add? Anything I can remove
(backup
> > > > space costs money :-)?
> > >
> > > You can't be serious...
> >
> > Why not? The server and a limited amount of space on a backup server
comes
> > at a fixed price. Additional backup space is extra.
> >
> > Looking at the directories, /home/vpopmail wastes most of its space in
the
> > Trash folders, which I see no point in backing up.
>
> If you don't want to backup actual mail, skip any folder called new/ cur/
or
> tmp/ under /home/vpopmail/domains/*. Skipping Maildir/ will also skip the
> imap or sqwebmail stuff, probably not what you want. This is pretty easy
if
> you use rsync which will also minimise bandwidth and preserve permissions
>
> HTH
> -- 
> -
> Bob Hutchinson
> Midwales dot com
> -
>




Re: [toaster] Backups

2005-12-09 Thread Nikki Locke
GoodnGo.de (R) Zentrale wrote:
> Hello Bob, 
>  
> do this for tarring: 
>  
> #> cd /;tar -c -z -P -V `date` -B -p -f 
> /where_you_want_to_tar/file_to_tar.tar.gz  /var/qmail/users 
> /var/qmail/control /var/qmail/alias /home/vpopmail/domains -X Maildir new 
> cur & 

Thanks for the advice. I have a few questions...
Why -B [ reblock as we read (for reading 4.2BSD pipes)]?
How does "-X Maildir new cur" work? My manual page says -X means open the file 
given in the following argument, and use that as a list of patterns to ignore.

My script looks like this (sorry about any word wrap)...

#! /bin/sh

# Set up some variables
BACKUPLIST=./backup.include
EXCLUDELIST=./backup.exclude
DAILY=`date +%a`
DAILY=test
SQLBACK=/remotemount/sqldata.$DAILY.sql.z
FULLBACK=/remotemount/fullbackup.$DAILY.tar.z

# Dump the data to a ziped sql file
mysqldump -uroot -p --add-drop-table --add-locks --lock-tables --
all-databases | gzip > $SQLBACK

# Tar all the essential config files, plus the documents into a compressed tar
tar cpPzf $FULLBACK --exclude-from $EXCLUDELIST `cat $BACKUPLIST`

The backup.include file contains a list of files and directories I want backed 
up. It looks a bit like this...

/etc/my.cnf
/etc/httpd/conf/httpd.conf
/etc/passwd
/etc/group
/usr/sbin/fw_iptables
/var/qmail
/home/vpopmail/domains
/var/www

The backup.exclude file contains a list of patterns not to back up. It looks 
like this...

*/logs/*
*/backups/*
*/.Trash/*
*/.Trash
*/qmail/man/*
*/qmail/doc/*
*/qmail/bin/*

Obviously, I've done it this way so that the include and exclude lists can 
easily be changed without too much danger of messing up the script.

-- 
Nikki Locke, Trumphurst Ltd.  PC & Unix consultancy & programming
http://www.trumphurst.com/