I have been successfully deleting files from backups for some time. I use
basic a basic `find <dir> -iname <name> -exec rm {} \;` to hunt down files
and delete them. I have never had any problems recovering the data as the
restore process doesnt have a file list it goes off of but just processes
each file in the directory.
to delete all mp3 files from the pc directories
I like to use regular expressions as it reduces the chance of getting the
wrong files.
find /path/to/backuppc/pc/ -regex './.*\.mp3$ \*.mp3 -exec rm {} \;
be carefull with find and regex as you need the ./ at the front. ./ in this
circumstance is specifically "begins with a directory". then .* which is
anycharacter followed by any number of any characters, \.mp3 is saying use a
real period instead of the any wildcard that . represents followed by mp3,
the $ means the end of the line so you wont match a file like
/path/path/info_on.mp3.files.txt
but would match
/path/path/info_on.mp3
you dont need to do anything with the cpool/pool as the backuppc_nightly
will clean that up. Also, the file names there are mangled beyond
recognition so find would help you anyway.
I use -or and search for video files, mp3 files, temp files
abbr vers:
find /path/to/pc/ -regex './.*\.mp3$' -or -regex './.*\.avi$' -or -regex
'./.*\.mpg$' -or -regex './.*\.mpeg$' -exec rm{} \;
I run it in this way because then find only runs through the filesystem 1
time where running these seperately would run it over and over.
Also, you need to be aware of the filename mangling done so you cannot
search for /myfile.ext but instead must search for /.myfile.ext or
/.*myfile.ext (with regext) or /*myfile.ext if you are using the standard
wildcard *
good luck.
On Sun, Nov 22, 2009 at 11:53 AM, Justin Guenther <jguent...@gmail.com>wrote:
> [reposted from backuppc-devel due to lack of response]
>
> Hello all,
>
> I have come across this problem frequently -- backups are running
> great, then one day I notice that backups are bigger than they should
> be. I look into it, and a large file was copied somewhere that got
> backed up but shouldn't have. I've searched around and can't find an
> answer to this one, forgive me if I overlooked a solution.
>
> I can add an exclusion and wait for the file to expire from the pool,
> but for my configuration this takes months.
>
> 1) is there a current (safe) way to delete a file from the pool/cpool
> and from all backups
> 2) if not, what would this take? I would have to delete the entry in
> the pool/cpool, and the link(s) to it from the individual pc/backup#/
> subdirectories, but would this be all I would need to do? I am not too
> worried about updating backup stats (size, compressed size, etc) but
> for completeness sake it would be nice to know exactly where I would
> need to look to update that information.
>
> Thanks,
> Justin Guenther
>
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
> trial. Simplify your report design, integration and deployment - and focus
> on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now. http://p.sf.net/sfu/bobj-july
> _______________________________________________
> BackupPC-users mailing list
> BackupPC-users@lists.sourceforge.net
> List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
> Wiki: http://backuppc.wiki.sourceforge.net
> Project: http://backuppc.sourceforge.net/
>
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
BackupPC-users mailing list
BackupPC-users@lists.sourceforge.net
List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki: http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/