Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filesets for files are not counted on "status subscriptions all" #1811

Open
tuxmaster5000 opened this issue May 12, 2024 · 4 comments
Open
Assignees
Labels
bug This addresses a bug wontfix

Comments

@tuxmaster5000
Copy link
Contributor

Bareos component version

all 23.0..2

Steps to reproduce

Call "status subscriptions all"

Expected results

A list of potentially required licence points.

Actual results

Only the PostgreSQL file sets are counted. The MariaDB (which I know that will be an bug) and simple file sets are not counted.

Environment

- OS: Fedora 39, Rock 9, CentOS 7

Relevant log output

status subscriptions all
Bareos version: 23.0.2 (Fedora 39)
Binary info: self-compiled
Report time: 2024-05-12 11:03:57

Detailed backup unit report:
+----------------------+------------+----------+----------+-------------+--------------+
| client               | fileset    | db_units | vm_units | filer_units | normal_units |
+----------------------+------------+----------+----------+-------------+--------------+
| server1_foo.foo.bar  | PostgreSQL |        1 |          |             |              |
| server2_foo.foo.bar  | PostgreSQL |        1 |          |             |              |
| TOTAL                |            |        2 |          |             |              |
+----------------------+------------+----------+----------+-------------+--------------+

Backup unit totals:
       used: 2
 configured: 0
  remaining: -2

Checksum: {SHA256}c9e3c3e55e3adf830bd4dfcabaff46ec55de0cba626833f2c6632276ebc5e23

Clients/Filesets that cannot be categorized for backup units yet:
+----------------------+----------+----------------------------------------------------------------------------------------------------+
| client               | fileset  | filesettext                                                                                          |
+----------------------+----------+----------------------------------------------------------------------------------------------------+
| server3_foo.foo.bar               | Standart | <empty>                                                                                              |
| server1_foo.foo.bar                 | Standart | <empty>                                                                                              |
| server4_foo.foo.bar                | server4_foo.foo.bar    | <empty>                                                                                              |
| server5_foo.foo.bar                 | Standart | <empty>                                                                                              |
| server6_foo.foo.bar               | Standart | <empty>                                                                                              |
| server7_foo.foo.bar            | Standart | <empty>                                                                                              |
| server8_foo.foo.bar           | Windows  | <empty>                                                                                              |
| server2_foo.foo.bar | MariaDB  | FileSet {
  Name = "MariaDB"
  Include {
    Options {
      Signature = "SHA512"
      Compression = "LZ4HC"
      HardLinks = No
      AclSupport = Yes
      XattrSupport = Yes
    }
    Plugin = "python:module_path=/usr/lib64/bareos/plugins:module_name=bareos-fd-mariabackup:mycnf=/etc/bareos/my.cnf:restorecommand=/bin/true"
  }
}

 |
| server2_foo.foo.bar | Standart | <empty>                                                                                              |
| server9_foo.foo.bar         | Standart | <empty>                                                                                              |
+----------------------+----------+----------------------------------------------------------------------------------------------------+

Amount of data that cannot be categorized for backup units yet:
         unknown_mb: 392746
 unknown_percentage: 99.99


Estimate only. Contact Bareos for actual quote https://www.bareos.com/contact/

Relevant traces output

No response

Anything else?

The director with its database was originally operated under MariaDB and then migrated to PostgreSQL (when MariaDB support was dropped). The original database was once a MariaDB under Bacula. This was migrated with the first Bareos version. Only the scripts supplied by Bareos were used for the migration. Maybe something got lost during all the migrations? Because the PostgreSQL filesets were only recently created under Bareos 23.

@tuxmaster5000 tuxmaster5000 added bug This addresses a bug needs triage Somebody needs to look at this labels May 12, 2024
@tuxmaster5000
Copy link
Contributor Author

What I find bizarre is the fact that only "empty" is displayed under "filesettext".
Because a "show filesets" showed the file sets correctly.

@bruno-at-bareos
Copy link
Contributor

bruno-at-bareos commented May 14, 2024

If I remember that was my case with a very old database migrated from version to version.
Could you check if running the following sqlquery
select * from fileset;
You have something in columns filesettext?

They maybe empty.
show fileset use the config file, while the subscription command use the database.
from memory changing one of the option (that doesn't trigger a full, like signature or compression) and a reload should update the fileset in the database : maybe a good idea to test on a experimental vm with a dump of the production is a good idea 😁

@tuxmaster5000
Copy link
Contributor Author

Very interesting, but yes only for the MariDB and PostgreSQL fileset the filesettext field is filled in the SQL database.
But changing the signature, compression or add description for the file set will not trigger an update to the database.

@bruno-at-bareos
Copy link
Contributor

Hello, so reviewed with the devs the problem with such old migrated db, the filesettext will not be updated until a significant changes is made to the fileset so the hash will be changed. But of course with the drawback of triggering a new full.

It may be considered as a bug, but we already know that not fixes will be done soonish, and quite rare.

Your best path to fix this is to update manually the content of filesettext with the content of the fileset resource directly in the database, then list filesets will show you the content, and of course subscription view will work.

@bruno-at-bareos bruno-at-bareos removed needs triage Somebody needs to look at this labels May 16, 2024
@bruno-at-bareos bruno-at-bareos self-assigned this May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This addresses a bug wontfix
Projects
None yet
Development

No branches or pull requests

2 participants