How to diagnose problems#
Finding the source of a problem with Bacula can sometimes be not that easy, especially for new Bacula users. Once we know what happened, we can fix it. In this chapter we have collected the most common practices used to find and solve problems with Bacula.
Jobs#
The most problems when working with Bacula occur while jobs working. Below you can find five basic steps you can use to check what is wrong with job if for example the job is stuck, ends with an error or works incorrectly.
Step 1: Job status#
The job status is the main indicator that determines at what stage the currently started job is and whether the status of that stage is healthy or not. In Bacularis, the job status can be found as an icon in the column of the job history table:
[Main menu] => [Page: Jobs] => [Tab: Job history]
There are four job stages:
job not running - this stage does not have the job status because the job has not been started yet.
job created but not yet running - this happens right after a job is started, when the job is added to the Bacula Director run queue but it is not running yet. The job is waiting and has status
C
.job is running - the job does the main work (backup, copy or verify …etc.). The job status is
R
.finished job - this is a job stage after stopping. The job status indicates whether the job finished successfully or not. The job status of healthy job is
T
, the status of a cancelled job isA
and other statuses such asE
,e
,f
mean errors orD
that means verify differences for verify jobs.
For a complete list of job statuses, see the this chapter of the Bacula documentation: Job status and error codes. Please note that some part of these job statuses appear internally in Bacula and are not displayed to users.
Jobs with warnings#
Jobs with warnings are a bit special in the job status meaning because in this case
the job status is T
(Job terminated normally) but in the job log we see some error
or warning messages and the final termination state is:
Termination: Backup OK -- with warnings
The job errors
property value for this type of jobs is greater than zero.
Step 2: Job log#
In the job log, Bacula reports details about jobs, warnings and errors. This is
the main source of knowledge about what happened with the job. The reporting levels
can be customized in the Messages
resource used in the job configuration.
Step 3: Director status#
There are situations when reading the job log is not enough to find out what is currently happening with a job. In this case, the status of the Bacula Director comes in very handy. We can find it in the following path:
[Main menu] => [Page: Director] => [Tab: Actions] => [Button: Status director]
In the running job section in this Bacula Director status we can read the current status, and after unfolding the job details we can also read the status description.
Step 4: Client status and storage status#
Client status and storage status can tell us if something is wrong on the client and storage side. For example, they may not be started or accessible, or there may be a problem with the backup storage device.
The client status:
[Main menu] => [Page: Clients] => [Tab: Clients] => [Table: Clients] => [Button: 'Details' for selected client] => [Tab: Actions] => [Button: Status client]
The storage status:
[Main menu] => [Page: Storage] => [Table: Storage] => [Button: 'Details' for selected storage] => [Tab: Actions] => [Button: Status storage]
Step 5: Bacula configuration#
In Bacula configuration we can find directives that will help us solve job problems. For example, if a job is waiting because some limits are reached, such as the maximum concurrent jobs limit for Bacula component has been reached, we can increase this limit in the Bacula configuration.
Video guide#
What to do if started job gets stuck#
In this video tutorial you will learn how to diagnose problems with a job, if after you start a job, it is not working properly but is waiting on something.