Re: [Bacula-users] Fwd: Job copy question
On 2/26/22 03:48, Marcelo Slon wrote: > Thanks a lot for your answers. > I will analyze and do my tests. > I'm using Bacula Community version 9.6.7 with PostgreSQL, and in the database > I found a 'status' table with the following data: [...snip...] > As you can see it doesn't have the 'W' status that you use in the SQL query. > Does this jobstatus exist in my bacula version or is this table incomplete? Hello Marcelo, The 'W' was intended to mean what Josip said. Also, sometimes you will see a job terminate "Backup OK -- with warnings", and this is when one would expect the jobstatus in the catalog to be 'W', but it's not. These jobs will also have a 'T' (Terminated OK) in the catalog. However, if you check the "Non-fatal FD errors", or "Non-fatal SD errors" in the job's summary, you will see that one, or both are non-zero for them. The queries that Josip sent as well as all of them in the code looking for "OK" job statues contain ('T', 'W') because it was intended that the "Backup OK -- with warnings" jobs might one day be set to 'W' instead of 'T'. I have had several conversations about this with the developers, but unfortunately, this is not going to ever happen. These queries are OK with both letters because they are used in SQL "IN" clauses which is an "any of these characters" choice. So, even though 'W' will never be there, the 'T' will, so the queries are OK - albeit confusing since 'W' does not appear anywhere else. :) In the baculabackupreport.py script I mentioned to you earlier, I am able to flag these 'with warnings' jobs because I check for OK jobs having a jobstatus of 'T', but also take into account the number of non-fatal FD and SD errors. P.S. There are several other characters in the 'status' table that are never used either. :) Hope this helps! Bill -- Bill Arlofski w...@protonmail.com ___ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users
[Bacula-users] Fwd: Fwd: Job copy question
Thanks Josip. Regards, Marcelo -- Forwarded message - De: Josip Deanovic Date: sáb., 26 de fev. de 2022 às 08:38 Subject: Re: [Bacula-users] Fwd: Job copy question To: On Saturday 2022-02-26 07:48:52 Marcelo Slon wrote: > Thanks a lot for your answers. > I will analyze and do my tests. > I'm using Bacula Community version 9.6.7 with PostgreSQL, and in the > database I found a 'status' table with the following data: > |jobstatus|jobstatuslong |severity| > |-|---|| > |C|Created, not yet running |15 | > |R|Running|15 | > |B|Blocked|15 | > |T|Completed successfully |10 | > |E|Terminated with errors |25 | > |e|Non-fatal error|20 | > |f|Fatal error|100 | > |D|Verify found differences |15 | > |A|Canceled by user |90 | > |F|Waiting for Client |15 | > |S|Waiting for Storage daemon |15 | > |m|Waiting for new media || > |M|Waiting for media mount|15 | > |s|Waiting for storage resource |15 | > |j|Waiting for job resource |15 | > |c|Waiting for client resource|15 | > |d|Waiting on maximum jobs|15 | > |t|Waiting on start time |15 | > |p|Waiting on higher priority jobs|15 | > |a|SD despooling attributes |15 | > |i|Doing batch insert file records|15 | > |I|Incomplete Job |25 | > > As you can see it doesn't have the 'W' status that you use in the SQL > query. Does this jobstatus exist in my bacula version or is this table > incomplete? I am not sure what is that table used for but I found it can be found in Bacula documentation: # For 9.6.x https://www.bacula.org/9.6.x-manuals/en/developers/Catalog_Services.html#SECTION001014000 # For 11.0.x https://www.bacula.org/11.0.x-manuals/en/main/Job_status.html#blb:director:job:status JobStatus "W" means "Terminated normally with warnings". For example, it could happen when the job has normal status but some script produced an output (but still return 0). -- Josip Deanovic ___ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users ___ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users
Re: [Bacula-users] Fwd: Job copy question
On Saturday 2022-02-26 07:48:52 Marcelo Slon wrote: > Thanks a lot for your answers. > I will analyze and do my tests. > I'm using Bacula Community version 9.6.7 with PostgreSQL, and in the > database I found a 'status' table with the following data: > |jobstatus|jobstatuslong |severity| > |-|---|| > |C|Created, not yet running |15 | > |R|Running|15 | > |B|Blocked|15 | > |T|Completed successfully |10 | > |E|Terminated with errors |25 | > |e|Non-fatal error|20 | > |f|Fatal error|100 | > |D|Verify found differences |15 | > |A|Canceled by user |90 | > |F|Waiting for Client |15 | > |S|Waiting for Storage daemon |15 | > |m|Waiting for new media || > |M|Waiting for media mount|15 | > |s|Waiting for storage resource |15 | > |j|Waiting for job resource |15 | > |c|Waiting for client resource|15 | > |d|Waiting on maximum jobs|15 | > |t|Waiting on start time |15 | > |p|Waiting on higher priority jobs|15 | > |a|SD despooling attributes |15 | > |i|Doing batch insert file records|15 | > |I|Incomplete Job |25 | > > As you can see it doesn't have the 'W' status that you use in the SQL > query. Does this jobstatus exist in my bacula version or is this table > incomplete? I am not sure what is that table used for but I found it can be found in Bacula documentation: # For 9.6.x https://www.bacula.org/9.6.x-manuals/en/developers/Catalog_Services.html#SECTION001014000 # For 11.0.x https://www.bacula.org/11.0.x-manuals/en/main/Job_status.html#blb:director:job:status JobStatus "W" means "Terminated normally with warnings". For example, it could happen when the job has normal status but some script produced an output (but still return 0). -- Josip Deanovic ___ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users
[Bacula-users] Fwd: Job copy question
Thanks a lot for your answers. I will analyze and do my tests. I'm using Bacula Community version 9.6.7 with PostgreSQL, and in the database I found a 'status' table with the following data: |jobstatus|jobstatuslong |severity| |-|---|| |C|Created, not yet running |15 | |R|Running|15 | |B|Blocked|15 | |T|Completed successfully |10 | |E|Terminated with errors |25 | |e|Non-fatal error|20 | |f|Fatal error|100 | |D|Verify found differences |15 | |A|Canceled by user |90 | |F|Waiting for Client |15 | |S|Waiting for Storage daemon |15 | |m|Waiting for new media || |M|Waiting for media mount|15 | |s|Waiting for storage resource |15 | |j|Waiting for job resource |15 | |c|Waiting for client resource|15 | |d|Waiting on maximum jobs|15 | |t|Waiting on start time |15 | |p|Waiting on higher priority jobs|15 | |a|SD despooling attributes |15 | |i|Doing batch insert file records|15 | |I|Incomplete Job |25 | As you can see it doesn't have the 'W' status that you use in the SQL query. Does this jobstatus exist in my bacula version or is this table incomplete? Marcelo ___ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users