Fileset update

46 views
Skip to first unread message

aeron...@gmail.com

unread,
Jan 1, 2020, 11:24:10 AM1/1/20
to bareos...@googlegroups.com
I have update my fileset to include a new exclude statement. I have
restarted Bareos (including reboot the server). Unfortunately, Bareos
continues to use the old version of the fileset definition for the
backup. I do not find an update statement in the manual to force Bareos
to use the new fileset definition. bconsole does show the updated
fileset I have created. So what is the correct way to get Bareos to use
the updated fileset in the backups.

I am on Ubuntu 18.04 server using Bareos 18.2.5-131.1 according to webui

tia

Spadajspadaj

unread,
Jan 1, 2020, 11:35:18 AM1/1/20
to bareos...@googlegroups.com
Question is how did you "update" the fileset and is it really used in
the job definition.

First things to check - do a "show job=<your-job-name>" and see what's
the fileset name and if it matches the fileset you were editing.

Example from my installation:

*show job=srv2-linux
Job {
  Name = "srv2-linux"
  Client = "srv2-fd"
  FileSet = "Linux-minimal-fileset"
  JobDefs = "DefaultJob"
}

(to be on the safe side you can also do the "show client" on the client
name to be sure you got the right machine configured for backup with
this job)


Now if you have a FileSet (in my case it's called
"Linux-minimal-fileset"), you do a "show fileset=<fileset-name>"
command. Like this:

*show fileset=Linux-minimal-fileset
FileSet {
  Name = "Linux-minimal-fileset"
  Include {
    Options {
      Signature = MD5
      Compression = GZIP6
      OneFS = No
      AclSupport = Yes
      XattrSupport = Yes
      Fs Type = "btrfs"
      Fs Type = "ext2"
      Fs Type = "ext3"
      Fs Type = "ext4"
      Fs Type = "reiserfs"
      Fs Type = "jfs"
      Fs Type = "xfs"
      Fs Type = "zfs"
    }
    File = "/root"
    File = "/etc"
    File = "/home"
    File = "/var"
    File = "/srv"
    Plugin = "bpipe:file=/_rpmlist_/rpm.lst:reader=/usr/bin/rpm
-qa:writer=/bin/bash -c ''xargs yum install -y''"
  }
  Exclude {
    File = "/var/lib/bareos"
    File = "/var/lib/bareos/storage"
    File = "/proc"
    File = "/tmp"
    File = "/var/tmp"
    File = "/.journal"
    File = "/.fsck"
    File = "/srv/backups"
  }
}

If the name of the fileset matches what you edited, but the contents
don't, it probably means that you edited a wrong file (try grepping for
the fileset name on your /etc, /opt, or /usr/local, depending on how you
installed and configured Bareos).

BTW, it's not necessary to restart director after configuration change.
It's enough to do a "reload" from bconsole.

Regards,

MK

spadaj

unread,
Jan 1, 2020, 12:41:41 PM1/1/20
to bareos...@googlegroups.com
Confusing.
I'd try "bareos-dir -t" with reasonably high debug level (-d900,
probably) to see which files are being read and which directives are
being parsed. I know, it dumps a lot of stuff (you definitely want to
redirect it to a file for reading with your favourite editor) but it
should show what's going on.

Regards,
MK

W dniu 01.01.2020 o 18:11, aeron...@gmail.com pisze:
> Thanks MK but I did do the show fileset="Full Laptop Set" and it
> displayed the correct information.
>
> I used webui to see the fileset used in the backup, But looking at the
> actual backups, It used a previous version of the file (one specifically
> date as 8 Jan 2019).
>
> The only way I could get it to update (shown below) was to change the
> resource name in the Job definition to "Full_Laptop_Set" and of course
> change the name of in the fileset definition in the fileset directory.
>
> before
>
> Job {
>   Name = "BEE-XPS15_1bkup"
>   Level = Incremental
>   Storage = "BEE-XPS15-storage"
>   Pool = "BEE-XPS15"
>   Client = "BEE-XPS15-fd"
>   FileSet = "Full Laptop Set"
>   JobDefs = "Common_Attributes"
> }
>
> After
>
> Job {
>   Name = "BEE-XPS15_1bkup"
>   Level = Incremental
>   Storage = "BEE-XPS15-storage"
>   Pool = "BEE-XPS15"
>   Client = "BEE-XPS15-fd"
>   FileSet = "Full_Laptop_Set"
>   JobDefs = "Common_Attributes"
> }
>
> and in fileset
>
> from
>
> FileSet {
>   Name = "Full Laptop Set"
>   Include {
>     Options {
>       Exclude = Yes
>
> ...
>
>    }
>
>     Options {
>       Signature = SHA1
>       Compression = GZIP6
>     }
>     File = "/home/bee"
>     File = "/media/windows/Users/bee"
>   }
> }
>
> to
>
> FileSet {
>   Name = "Full_Laptop_Set"
> ...
>
> bee

Spadajspadaj

unread,
Jan 4, 2020, 7:39:37 AM1/4/20
to bareos-users

Firstly, try to respond to the group, not to me personaly. (It's a common mistake :-))

Secondly, literarily taking the docs, it should just mean that it won't get upgraded to full backup because the fileset changed but the fileset itself should work as defined. But here someone more experienced with the bareos internals should shed some light.

On 01.01.2020 20:31, aeron...@gmail.com wrote:

So I found nothing wrong or at least obvious to the amature but

The changes I made were in the options section.

I get a hint from the manual that this may not cause an updated file to be used (under the fileset resource section). it says

"Any change to the list of the included files will cause Bareos to automatically create a new FileSet (defined by the name and an MD5 checksum of the Include/Exclude File directives contents). Each time a new FileSet is created Bareos will ensure that the next backup is always a full backup. However, this does only apply to changes in directives File (Dir->Fileset->Include) and File (Dir->Fileset->Exclude). Changes in other directives or the FileSet Options Ressource do not result in upgrade to a full backup."

Does this also mean that changes in the options sections of the fileset do not trigger usage of the updated fileset. I do not see in the test file a parameter for this but do find

bareos-dir (900): lib/parse_conf.cc:687-0 Item=IgnoreFileSetChanges def=yes defval=false

IgnoreFileSetChanges  I have never played with in my configuration files.

bee

aeron...@gmail.com

unread,
Jan 12, 2020, 4:44:12 PM1/12/20
to bareos...@googlegroups.com

So I have modified the fileset.

I have check with bconsole that the modified fileset before I did reload and it showed the unmodified fileset.

I then did the reload command and it then showed the modified fileset.

A  nightly backup ran (as an incremental) and the director show "FileSet: "Full Server Set" 2019-10-19 23:05:00" which is an old fileset.

What suggestions/guesses why Bareos continues to use an outdated fileset definition rather than the updated one?

--
You received this message because you are subscribed to the Google Groups "bareos-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bareos-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bareos-users/c6ef1d29-55cc-5f53-283f-a7632a8d2e5c%40gmail.com.
Reply all
Reply to author
Forward
0 new messages