Remove specific files from a job.

14 views
Skip to first unread message

Brock Palen

unread,
Apr 14, 2024, 10:44:16 PM4/14/24
to bareos-users
I have some personal machines I backup for family. I depend on AI as their uploads are not sufficient to do fulls.
I use a raspberry pi with a usb drive to do the initial full and then migrate the jobs.

Well that drive for a new system is throwing read errors. I’m lucky that the volumes are small 3gb total job is 145 gb

I’m wondering if there is a way to delete just the files on the bad volumes from the job. And grab them on the next incremental?

I’m not seeing an obvious way to and looks like volumes do byte not file boundaries.

Is it possible? Thanks.

Sent from my iPhone
Brock Palen

Spadajspadaj

unread,
Apr 15, 2024, 3:30:46 AM4/15/24
to bareos...@googlegroups.com
Obviously you cannot remove a file from a middle of the media. But I
suppose you want to scratch the whole media.

The only way I see would be to manipulate the database directly.

Question is do you know which files are those. If you do, I suppose the
way to do so would be to remove the entries from the "job" table (you'd
have to join the file and path entries to pinpoint the files to delete).

_Probably_ (I haven't tested that but that's what I deduce from the
database structure), you could find which files were on that particular
media file by correlating the fileindex field from the file table for a
given job with a jobmedia table (firstindex and lastindex field).

But of course test before applying in prod.

MK
Reply all
Reply to author
Forward
0 new messages