#868 Issue closed: bareos restore fails due to more then one restore jobs defined

Labels: enhancement, support / question, fixed / solved / done

gdha opened issue at 2016-06-07 13:33:

  • rear version (/usr/sbin/rear -V): 1.18
  • OS version (cat /etc/rear/os.conf or lsb_release -a): Centos 7.2
  • rear configuration files (cat /etc/rear/site.conf or cat /etc/rear/local.conf):
OUTPUT=ISO
OUTPUT_URL=nfs://host/exports/isos
ISO_DEFAULT=manual
BACKUP=BAREOS
  • Brief description of the issue: rear recover hangs during the restore client=client-fd where=/mnt/local select all done part:
Disk layout created.
Connecting to Director server:9101
1000 OK: server-dir Version: 15.2.2 (16 November 2015)
Enter a period to cancel a command.
restore client=client-fd  where=/mnt/local select all done
Using Catalog "MyCatalog"
Automatically selected FileSet: client-fileset
+-------+-------+----------+-------------+---------------------+-----------------------+
| jobid | level | jobfiles | jobbytes    | starttime           | volumename            |
+-------+-------+----------+-------------+---------------------+-----------------------+
|     1 | F     |   37,288 | 568,530,252 | 2016-06-03 12:33:45 | client-pool-Full-0001 |
+-------+-------+----------+-------------+---------------------+-----------------------+
You have selected the following JobId: 1

Building directory tree for JobId(s) 1 ...  ++++++++++++++++++++++++++++++++++++++++++++
33,363 files inserted into the tree and marked for extraction.
Bootstrap records written to /var/lib/bareos/server-dir.restore.2.bsr

The job will require the following
   Volume(s)                 Storage(s)                SD Device(s)
===========================================================================

    client-pool-Full-0001     File                      FileStorage

Volumes marked with "*" are online.


37,287 files selected to be restored.

The defined Restore Job resources are:
     1: client-restore
     2: client-restore-mysql
Select Restore Job (1-2): 
Expected a positive integer, got: 
Select Restore Job (1-2): 
Expected a positive integer, got: 
Select Restore Job (1-2): waiting for job to start

Is there a way to specify restorejob name via the restore/BAREOS/default/40_restore_backup.sh script?

gdha commented at 2016-06-07 13:34:

@abbbi Do you have an idea?

abbbi commented at 2016-06-08 07:10:

@gdha sorry, no ideas here as im not familiar with bareos :/

gdha commented at 2016-06-08 11:44:

@aussendorf Hi Maik - see the topic - is this something that we are currently missing in the restore code or is it something I missed in the configuration of the setup with bareos?

aussendorf commented at 2016-06-08 12:36:

I guess that case is not handled by rear / Bareos now. Most people just have a unique restore-job, then bconsole auto-selects that one.

So we need an optional configuration directive like RESTORE_JOB, then the bconsole-call needs to be extended by "restorejob=$RESTORE_JOB", if that variable is defined.

gdha commented at 2016-06-08 13:06:

@aussendorf Indeed I thought so too, but wanted to be sure that it was not my lack of knowledge of bareos ;-)

pcahyna commented at 2019-08-22 17:24:

Does BACULA need this fix as well? Cc @yontalcar

pcahyna commented at 2019-08-22 17:36:

Sorry, I see now that the problem was in the automatic recovery mode, which is not implemented for BACULA.


[Export of Github issue for rear/rear.]