Sometimes I’ve had a BLOCKED device it has been due to a race condition in 
Bacula between 2 jobs requesting different media for the same drive.  Usually 
it can be corrected by canceling one of the jobs.  Other times it is due to a 
“failed” job that is not cleaned up completely leaving a reservation on a 
device.  There is no job to cancel, but the status on your autochanger will 
show its presence.  The only solution that I’ve found in this case is to stop 
the bacula-sd process that manages the devices in question.  A total pain if 
you have any jobs running.  Anyway, it releases the reservation and the 
bacula-sd process can be restarted and the device is now available.  Absolute 
worst case scenario is to reboot the storage server.

Patti Clark
Sr. Linux System Administrator
Oak Ridge National Laboratory

From: Jeffrey DiDomenico <jdidomen...@integrafin.co.uk>
Date: Wednesday, July 10, 2019 at 4:48 AM
To: "bacula-users@lists.sourceforge.net" <bacula-users@lists.sourceforge.net>
Subject: [EXTERNAL] [Bacula-users] Bacula fails with Blocked Drive.

Hi,

I know you guys are volunteers but any help would be greatly appreciated.

Please help me with the following problem. I have been working on this for some 
time but can't find a solution on the internet. I can understand if "Device is 
BLOCKED waiting for mount of volume" can mean several issues but here are all 
the details.


OS: CentOS Linux release 7.6.1810 (Core)
Bacula Version: 5.2.13
Problem: No backups will start as the drive is always blocked. The bacula 
environment was running fine, and had been for years, then just stopped one 
day, no config was changed.

Device "IBM0" (/dev/tape/by-id/scsi-35001438016019fad) open but no Bacula 
volume is currently mounted.
    Device is BLOCKED waiting for mount of volume "IPR962L5",
       Pool:        Default
       Media type:  LTO5
    Slot 10 is loaded in drive 0.
    Total Bytes Read=0 Blocks Read=0 Bytes/block=0
    Positioned at File=0 Block=0
Tape Drive: The tape library is a HP MSL 4048 with two HP Ultrium 5-SCSI drives 
attached to a Supermicro server. I had a HP engineer swap the drives out and 
the problem still persisted.

btape test: On the following website  
https://www.bacula.org/5.2.x-manuals/en/problems/problems/Testing_Your_Tape_Drive.html
 I reach point 5 successfully but the btape fill command fails with the 
following, this is after making sure there is a tape in the drive:

[root@union ~]# btape -c bacula-sd.conf /dev/tape/by-id/scsi-35001438016019fb0
Tape block granularity is 1024 bytes.
btape: butil.c:290-0 Using device: "/dev/tape/by-id/scsi-35001438016019fb0" for 
writing.
btape: btape.c:477-0 open device "IBM1" 
(/dev/tape/by-id/scsi-35001438016019fb0): OK
*fill

This command simulates Bacula writing to a tape.
It requires either one or two blank tapes, which it
will label and write.

If you have an autochanger configured, it will use
the tapes that are in slots 1 and 2, otherwise, you will
be prompted to insert the tapes when necessary.

It will print a status approximately
every 322 MB, and write an EOF every 53.68 G.  If you have
selected the simple test option, after writing the first tape
it will rewind it and re-read the last block written.

If you have selected the multiple tape test, when the first tape
fills, it will ask for a second, and after writing a few more
blocks, it will stop.  Then it will begin re-reading the
two tapes.

This may take a long time -- hours! ...

Do you want to run the simplified test (s) with one tape
or the complete multiple tape (m) test: (s/m) m
Multiple tape test selected.
02-Jul 16:26 btape JobId 0: 3307 Issuing autochanger "unload slot 10, drive 1" 
command.
02-Jul 16:27 btape JobId 0: 3304 Issuing autochanger "load slot 1, drive 1" 
command.
02-Jul 16:32 btape JobId 0: Fatal error: 3992 Bad autochanger "load slot 1, 
drive 1": ERR=Child died from signal 15: Termination.
Results=Program killed by Bacula (timeout)

btape: btape.c:3074-0 Autochanger returned: -1
Mount blank Volume on device "IBM1" (/dev/tape/by-id/scsi-35001438016019fb0) 
and press return when ready:
btape: btape.c:3079-0
Wrote Volume label for volume "TestVolume1".
02-Jul 16:42 btape JobId 0: Fatal error: Job 0 canceled.
*

thanks,

--

Jeffrey Di Domenico
Systems Administrator

Direct: +44 020 7608 7463

Email: jdidomen...@integrafin.co.uk<mailto:jdidomen...@integrafin.co.uk>
[Transact - take control]

Phone: +44 (0)20 7608 4900
Web: www.transact-online.co.uk<http://www.transact-online.co.uk>
Address: 29 Clement's Lane, London EC4N 7AE
Please consider the environment before printing this email

--

This message is intended only for the addressee and may contain confidential 
information. Unless you are that person, you may not disclose its contents or 
use it in any way and are requested to delete the message along with any 
attachments and notify us immediately. This email is not intended to, nor 
should it be taken to, constitute advice. The information provided is correct 
to our knowledge & belief and must not be used as a substitute for obtaining 
tax, regulatory, investment, legal or any other appropriate advice.

"Transact" is operated by Integrated Financial Arrangements Ltd. 29 Clement's 
Lane, London EC4N 7AE. Tel: (020) 7608 4900 Fax: (020) 7608 5300. (Registered 
office: as above; Registered in England and Wales under number: 3727592). 
Authorised and regulated by the Financial Conduct Authority (entered on the 
Financial Services Register; no. 190856).
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to