Bacula-users

Re: [Bacula-users] Problem with unmounting a device

2016-02-26 04:23:39
Subject: Re: [Bacula-users] Problem with unmounting a device
From: Dietz Pröpper <dietz AT scanthis DOT de>
To: Kern Sibbald <kern AT sibbald DOT com>
Date: Fri, 26 Feb 2016 10:20:57 +0100
Kern Sibbald wrote:

Well, slap taken ;-). All the dirty little details follow.

Version: 7.0.5, own build
Storage device: Autochanger with two drives
Device config: see below

Expected behaviour:
After I unmount a tape drive, a "status sd" in bconsole should give the status 
"Device is BLOCKED. User unmounted.\nDrive 0 is not loaded.". If I unmount all 
devices attached to the changer, no backup should be able to start.

Observed behaviour:
If "Always Open = yes" in sd config:
(1) I unmount a "empty" device and get the response "3901 Device ""LTO0"
    (/dev/nst0)" is already unmounted.". But "status sd" yields only
    "Drive 0 is not loaded.", w/o the "BLOCKED" line.
(2) All devices are empty on sd startup and I unmount all of them. Status
    as in (1). Afterwards I start a backup and the first tape is happily used.
(3) To get a "BLOCKED" status from sd, I need to mount and unmount a device if 
the device is empty at sd startup.

If "Always Open = no" (as in the config snippet from below):
sd status always says "Drive 0 is not loaded." or "Slot xx was last loaded in 
drive 0.". Backups always start, regardless of device mount state.

For the "why" part - no idea. I can also attach complete bconsole output, but 
this would be quite a lot. But if it would help or if you need further infos, 
just ask.

Regards,
        Dietz

> It would probably help get a response if you give some details about
> "this seems to work no longer".
> 
> Why doesn't it work? What does it do?  What is the exact output?
> 
> On 02/24/2016 04:04 AM, Dietz Pröpper wrote:
> > Hi,
> > 
> > I have a little problem:
> > I have an autochanger with two devices. In former times, after I issued a
> > "unmount storage=blah drive=0" the sd status for that device was displayed
> > as "BLOCKED by user", which should still be the case, according to the
> > documentation.
> > 
> > Since some months, this seems to work no longer.
> > 
> > The bacula version is 7.0.5 and the device definition is as follows:
> > Device {
> > 
> >    Name = LTO0
> >    Media Type = LTO-3
> >    Device Type = Tape
> >    Archive Device = /dev/nst0
> >    drive index = 0
> >    AutomaticMount = yes;               # when device opened, read it
> >    AlwaysOpen = no;
> >    RemovableMedia = yes;
> >    RandomAccess = no;
> >    Offline On Unmount = no
> >    
> >    Autochanger = yes;
> >    Drive Index = 0;
> >    Alert Command = "sh -c 'tapeinfo -f /dev/sg0 |grep TapeAlert|cat'"
> >    Maximum Network Buffer Size = 655360
> >    
> >    Maximum Spool Size = 400g
> >    Spool Directory = /var/bacula/spool
> >    Maximum File Size=15g
> >    Maximum Block Size = 1290240
> >    Maximum Network Buffer Size = 655360
> >    
> >    Maximum Changer Wait = 300 s
> >    Maximum Open Wait = 180 s
> > 
> > }
> > 
> > Any idea?
> > 
> > Regards,
> > 
> >     Dietz

-- 
Name the Puppet Master

Attachment: signature.asc
Description: This is a digitally signed message part.

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users
<Prev in Thread] Current Thread [Next in Thread>