Click to See Complete Forum and Search --> : flexbackup 1.0.3


dtc
04-13-2003, 01:57 AM
Using flexbackup and need some help from anyone who may use it. I need help with what to enter in the conf file to exclude a directory.

For example on my full system backup I'm planning to backup:

$filesystems[0] = '/ /usr /var /home /boot';

But I want to exclude certian directories like /proc and some others. I'm guessing it needs to be entered in the exclude, but sorry to say I'm new at this and have no idea on what to put..

==================================
# Exclude files that match these *regular expressions* (not shell wildcards)
# from the backups (no affect on 'dump' archives). You can list more than one,
# just keep incrementing the index in the brackets for each. Also, strip off
# leading directories (the filesystem specs above or the "-fs" flag).
# Matches paths, not filenames, so put .* on the front/back as needed.
# Comment these out to exclude nothing.
$exclude_expr[0] = '.*/[Cc]ache/.*';
$exclude_expr[1] = '.*~$';

===================================

Thanks for any help!

bwkaz
04-13-2003, 09:33 AM
'^/proc/.*$' should match any file in /proc.

dtc
04-13-2003, 12:15 PM
Great..that did the trick bwkaz!!!

I also added the following to not backup my backup files:

'.*/backups/DB/.*$'
'.*/backups/server/.*$'

Being new, is there anything else I should exclude in my backups? Right now, I'll be backing up the following file systems using flexbackup, which is all of them. (with the above excludes):

/
/boot
/home
/usr
/var

Just want to make sure I'm covered in case of a catastrophy!

Thanks for all your help...Great site!!

bwkaz
04-13-2003, 01:12 PM
You'll probably want to exclude /dev as well. If you move to a 2.5/2.6 kernel, you'll also want to exclude /devices (if that's still what it's called then).

dtc
04-13-2003, 05:01 PM
Thanks again bwkaz!

Interesting though, after checking the backup logs, she excluded the /proc but not the /dev files...weird :confused:


# Exclude files that match these *regular expressions* (not shell wildcards)
# from the backups (no affect on 'dump' archives). You can list more than one,
# just keep incrementing the index in the brackets for each. Also, strip off
# leading directories (the filesystem specs above or the "-fs" flag).
# Matches paths, not filenames, so put .* on the front/back as needed.
# Comment these out to exclude nothing.
$exclude_expr[0] = '.*/backups/DB/.*$';
$exclude_expr[1] = '.*/backups/server/.*$';
$exclude_expr[2] = '^/proc/.*$';
$exclude_expr[3] = '^/dev/.*$';
$exclude_expr[4] = '^/devices/.*$';

craigad
01-13-2005, 02:56 PM
dtc,

to be correct, what you actually need to do is add the directories you want skipping to the string $prune.


/craigad

bwkaz
01-13-2005, 08:07 PM
Originally posted by bwkaz
you'll also want to exclude /devices (if that's still what it's called then). /devices? Why did I write that?!

The only extra thing that you'd want to exclude now would be /sys, not /devices. I actually don't remember a /devices ever existing in the development kernels...

Oh, that explains it -- this thread has been laying dead for about 2 years, only to be resurrected now. And that's right, way early in 2.5, there was a /devices tree used for hotplug and a couple other things -- it later renamed itself to sysfs, and was mounted on /sys.

(This is why I at least don't resurrect ancient threads. ;) It really confuses the people that posted in them! :o)