Apr 102011
 

Today is the first Sunday since I started using a scratch pool with Bacula. I was disappointed to see an email asking for a tape to be mounted. Why? With four tapes in the scratch pool, I shouldn’t be asked for a tape. Something is wrong. But there is no directive on a pool to say use the scratch pool. Bacula just uses the scratch pool if one is defined.

However, I checked the bacula-dir.conf file, searching for ‘scratch’. It occurred only once. OK. So, what’s up with that?

What tape is it asking for? ETU026. I check my magical website and see it is in the Differential. And in slot 1. So, why was I seeing all this:

10-Apr 09:40 kraken-sd JobId 58291: Ready to read from volume "DiffAuto-1409" on device "MegaFile" (/storage/compressed/bacula/volumes).
10-Apr 09:40 kraken-sd JobId 58291: 3301 Issuing autochanger "loaded? drive 0" command.
10-Apr 09:40 kraken-sd JobId 58291: 3302 Autochanger "loaded? drive 0", result: nothing loaded.
10-Apr 09:40 kraken-sd JobId 58291: 3304 Issuing autochanger "load slot 1, drive 0" command.
10-Apr 09:42 kraken-sd JobId 58291: 3305 Autochanger "load slot 1, drive 0", status is OK.
10-Apr 09:42 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Input/output error

10-Apr 09:42 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Input/output error

10-Apr 09:42 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Input/output error

10-Apr 09:42 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Input/output error

10-Apr 09:42 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Input/output error

10-Apr 09:42 kraken-sd JobId 58291: Please mount Volume "ETU026" or label a new one for:
    Job:          CopyToTape-Diff.2011-04-10_09.32.05_42
    Storage:      "DTL01" (/dev/nsa0)
    Pool:         Differentials
    Media type:   DLT
10-Apr 09:47 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 09:52 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 09:57 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:02 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:07 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:12 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:17 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:22 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:27 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:32 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:37 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:42 kraken-sd JobId 58291: Please mount Volume "ETU026" or label a new one for:
    Job:          CopyToTape-Diff.2011-04-10_09.32.05_42
    Storage:      "DTL01" (/dev/nsa0)
    Pool:         Differentials
    Media type:   DLT
10-Apr 10:47 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:52 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 10:57 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:02 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:07 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:12 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:17 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:22 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:27 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:32 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:37 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:42 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:47 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:52 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 11:57 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:02 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:07 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:12 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:17 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:22 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:27 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:32 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:37 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

10-Apr 12:42 kraken-sd JobId 58291: Please mount Volume "ETU026" or label a new one for:
    Job:          CopyToTape-Diff.2011-04-10_09.32.05_42
    Storage:      "DTL01" (/dev/nsa0)
    Pool:         Differentials
    Media type:   DLT
10-Apr 12:47 kraken-sd JobId 58291: Warning: mount.c:217 Open device "DTL01" (/dev/nsa0) Volume "ETU026" failed:
 ERR=dev.c:491 Unable to open device "DTL01" (/dev/nsa0): ERR=Device not configured

That’s rather, disturbing.

I logged into the bacula-sd machine and changed:

# /usr/local/sbin/mtx-changer /dev/pass11 loaded 1 /dev/sa0 0
1

OK, tape 1 is loaded, why can’t it use it?

What’s in each slot?

# /usr/local/sbin/mtx-changer /dev/pass11 list 
2:ETU047
3:ETU057
4:ETU058
5:ETU056
6:ETU045
7:ETU075
8:ETU076
9:ETU077
10:ETU078
1:

Oh, I know. See the empty label in slot 1? That’s a cleaning tape.

Earlier this week, I noticed my tape library asking for a cleaning tape. I pulled out the tape magazine, popped out a tape, and put in a cleaning tape. Then I used mtx-changer to load the tape, which automatically ran the cleaning tape. Then I unloaded that tape and left it there in slot 1.

But I did not run update slots, as I should have. So:

*update slots storage=DigitalTapeLibrary
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
Connecting to Storage daemon DigitalTapeLibrary at kraken.unixathome.org:9103 ...
3306 Issuing autochanger "slots" command.
Device "DTL01" has 10 slots.
Connecting to Storage daemon DigitalTapeLibrary at kraken.unixathome.org:9103 ...
3306 Issuing autochanger "list" command.
Catalog record for Volume "ETU047" updated to reference slot 2.
Catalog record for Volume "ETU057" updated to reference slot 3.
Catalog record for Volume "ETU058" updated to reference slot 4.
Catalog record for Volume "ETU056" updated to reference slot 5.
Catalog record for Volume "ETU045" updated to reference slot 6.
Catalog record for Volume "ETU075" updated to reference slot 7.
Catalog record for Volume "ETU076" updated to reference slot 8.
Catalog record for Volume "ETU077" updated to reference slot 9.
Catalog record for Volume "ETU078" updated to reference slot 10.
*m
10-Apr 12:52 bacula-dir JobId 58291: Using Volume "ETU058" from 'Scratch' pool.
10-Apr 12:52 kraken-sd JobId 58291: 3307 Issuing autochanger "unload slot 1, drive 0" command.
*m
10-Apr 12:53 kraken-sd JobId 58291: 3304 Issuing autochanger "load slot 4, drive 0" command.
10-Apr 12:54 kraken-sd JobId 58291: 3305 Autochanger "load slot 4, drive 0", status is OK.
10-Apr 12:55 kraken-sd JobId 58291: Wrote label to prelabeled Volume "ETU058" on device "DTL01" (/dev/nsa0)
10-Apr 12:55 kraken-sd JobId 58291: Forward spacing Volume "DiffAuto-1409" to file:block 0:2923854090.
10-Apr 12:55 kraken-sd JobId 58291: Sending spooled attrs to the Director. Despooling 15,563 bytes ...
10-Apr 12:55 bacula-dir JobId 58291: Bacula bacula-dir 5.0.3 (04Aug10): 10-Apr-2011 12:55:15
  Build OS:               i386-portbld-freebsd8.1 freebsd 8.1-STABLE
  Prev Backup JobId:      58243
  Prev Backup Job:        wocker.2011-04-10_05.55.00_28
.... and so on

Lesson: ALWAYS run update slots after exchanging tapes in the magazine. Even if it’s just a cleaning tape.

Website Pin Facebook Twitter Myspace Friendfeed Technorati del.icio.us Digg Google StumbleUpon Premium Responsive