Error talking to remote storage daemon

classic Classic list List threaded Threaded
17 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Error talking to remote storage daemon

Steve Garcia
OK, I've got my tape drive working (thanks Ana!) but I'm having trouble connecting to the autochanger it's in using the director.  This is the first time I've tried having a storage daemon on a different machine than the director.  The director is a slightly lower version (7.4.3 on Debian Jessie using backports) than the storage daemon (7.4.4 on stretch) but I had understood that those versions were close enough to work.

So I'm hoping this is another configuration issue.

Right now what I'm trying to do is label all the tapes in the new library.

When I try to access the new storage from the director, it is able to get a listing of all the tapes, but it fails when it tries to actually do the labeling.  I get a "3999 Device not found or could not be opened" error.  These errors show up quickly, there is no delay as it tries each slot, so it's obviously not getting far enough to try.  But it *is* obviously connecting to the remote storage, otherwise it wouldn't be able to obtain the slot list.

What am I missing?

root@sleipnir:/etc/bacula# bconsole
Connecting to Director sleipnir:9101
1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
Enter a period to cancel a command.
*label storage=Library2 barcodes
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "slots" command.
Device "AutochangerOdin" has 24 slots.
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "list" command.
The following Volumes will be labeled:
Slot  Volume
==============
   1  000015L6
   2  000018L6
   3  000021L6
   4  CLNU00L1
   5  000014L6
   6  000017L6
   7  000020L6
   8  CLN005L3
   9  000013L6
  10  000016L6
  11  000019L6
  12  000012L6
  13  000009L6
  14  000006L6
  15  000003L6
  16  000011L6
  17  000008L6
  18  000005L6
  19  000002L6
  20  000010L6
  21  000007L6
  22  000004L6
  23  000001L6
Do you want to label these Volumes? (yes|no):  yes
Defined Pools:
     1: Default
     2: OdinPool
Select the Pool (1-2): 2
Connecting to Storage daemon Library2 at odin:9103 ...
Sending label command for Volume "000015L6" Slot 1 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000015L6.
Sending label command for Volume "000018L6" Slot 2 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000018L6.
Sending label command for Volume "000021L6" Slot 3 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000021L6.
Media record for Slot 4 Volume "CLNU00L1" already exists.
Sending label command for Volume "000014L6" Slot 5 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000014L6.
Sending label command for Volume "000017L6" Slot 6 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000017L6.
Sending label command for Volume "000020L6" Slot 7 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000020L6.
Media record for Slot 8 Volume "CLN005L3" already exists.
Sending label command for Volume "000013L6" Slot 9 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000013L6.
Sending label command for Volume "000016L6" Slot 10 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000016L6.
Sending label command for Volume "000019L6" Slot 11 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000019L6.
Sending label command for Volume "000012L6" Slot 12 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000012L6.
Sending label command for Volume "000009L6" Slot 13 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000009L6.
Sending label command for Volume "000006L6" Slot 14 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000006L6.
Sending label command for Volume "000003L6" Slot 15 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000003L6.
Sending label command for Volume "000011L6" Slot 16 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000011L6.
Sending label command for Volume "000008L6" Slot 17 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000008L6.
Sending label command for Volume "000005L6" Slot 18 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000005L6.
Sending label command for Volume "000002L6" Slot 19 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000002L6.
Sending label command for Volume "000010L6" Slot 20 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000010L6.
Sending label command for Volume "000007L6" Slot 21 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000007L6.
Sending label command for Volume "000004L6" Slot 22 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000004L6.
Sending label command for Volume "000001L6" Slot 23 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000001L6.
You have messages.
*

From the bacula-sd.conf on odin (where the library is):
Autochanger {
  Name = AutochangerOdin
  Device = Drive-1
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
  Changer Device = /dev/autochanger1
}

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/nst0
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}

From bacula-dir.conf on sleipnir (where the director is):
Storage {
  Name = Library2
# Do not use "localhost" here    
  Address = odin                # N.B. Use a fully qualified name here
  SDPort = 9103
  Password = "*****************"
  Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device
}

From the /dev directory on odin:
lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3



--
Steve Garcia
Ignorance killed the cat, curiosity was framed.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
Hi steve,

It seems we have a configuration issue. It is not a good idea to have symlinks to sg devices. They can change after a server reboot.

**************
From the /dev directory on odin:
lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
**************

This can be very probably causing this issue with the label command. But I can't confirm this because I have never tried this.

It is better to use the /dev/tape/by-id names and even better to create udev rules based on the tape library specific charactheristics  such as serial number.

A "ls -lR /dev/tape" and "lsscsi -g" will help you.

Then you should chage:

Changer Device = /dev/autochanger1 with the by-id name for mediumx

And

Archive Device = /dev/nst0 with the by-id name for the tape drive (remember to use here the one that ends with -nst).

I noticed you have data spool configured. With an LTO6 It is very probably that you will slow down backups performance, unless you have clients with poor network performance.

Hope this helps you.

Best regards,
Ana

El 26 jul. 2017 20:25, "Steve Garcia" <[hidden email]> escribió:
OK, I've got my tape drive working (thanks Ana!) but I'm having trouble connecting to the autochanger it's in using the director.  This is the first time I've tried having a storage daemon on a different machine than the director.  The director is a slightly lower version (7.4.3 on Debian Jessie using backports) than the storage daemon (7.4.4 on stretch) but I had understood that those versions were close enough to work.

So I'm hoping this is another configuration issue.

Right now what I'm trying to do is label all the tapes in the new library.

When I try to access the new storage from the director, it is able to get a listing of all the tapes, but it fails when it tries to actually do the labeling.  I get a "3999 Device not found or could not be opened" error.  These errors show up quickly, there is no delay as it tries each slot, so it's obviously not getting far enough to try.  But it *is* obviously connecting to the remote storage, otherwise it wouldn't be able to obtain the slot list.

What am I missing?

root@sleipnir:/etc/bacula# bconsole
Connecting to Director sleipnir:9101
1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
Enter a period to cancel a command.
*label storage=Library2 barcodes
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "slots" command.
Device "AutochangerOdin" has 24 slots.
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "list" command.
The following Volumes will be labeled:
Slot  Volume
==============
   1  000015L6
   2  000018L6
   3  000021L6
   4  CLNU00L1
   5  000014L6
   6  000017L6
   7  000020L6
   8  CLN005L3
   9  000013L6
  10  000016L6
  11  000019L6
  12  000012L6
  13  000009L6
  14  000006L6
  15  000003L6
  16  000011L6
  17  000008L6
  18  000005L6
  19  000002L6
  20  000010L6
  21  000007L6
  22  000004L6
  23  000001L6
Do you want to label these Volumes? (yes|no):  yes
Defined Pools:
     1: Default
     2: OdinPool
Select the Pool (1-2): 2
Connecting to Storage daemon Library2 at odin:9103 ...
Sending label command for Volume "000015L6" Slot 1 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000015L6.
Sending label command for Volume "000018L6" Slot 2 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000018L6.
Sending label command for Volume "000021L6" Slot 3 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000021L6.
Media record for Slot 4 Volume "CLNU00L1" already exists.
Sending label command for Volume "000014L6" Slot 5 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000014L6.
Sending label command for Volume "000017L6" Slot 6 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000017L6.
Sending label command for Volume "000020L6" Slot 7 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000020L6.
Media record for Slot 8 Volume "CLN005L3" already exists.
Sending label command for Volume "000013L6" Slot 9 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000013L6.
Sending label command for Volume "000016L6" Slot 10 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000016L6.
Sending label command for Volume "000019L6" Slot 11 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000019L6.
Sending label command for Volume "000012L6" Slot 12 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000012L6.
Sending label command for Volume "000009L6" Slot 13 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000009L6.
Sending label command for Volume "000006L6" Slot 14 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000006L6.
Sending label command for Volume "000003L6" Slot 15 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000003L6.
Sending label command for Volume "000011L6" Slot 16 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000011L6.
Sending label command for Volume "000008L6" Slot 17 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000008L6.
Sending label command for Volume "000005L6" Slot 18 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000005L6.
Sending label command for Volume "000002L6" Slot 19 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000002L6.
Sending label command for Volume "000010L6" Slot 20 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000010L6.
Sending label command for Volume "000007L6" Slot 21 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000007L6.
Sending label command for Volume "000004L6" Slot 22 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000004L6.
Sending label command for Volume "000001L6" Slot 23 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000001L6.
You have messages.
*

From the bacula-sd.conf on odin (where the library is):
Autochanger {
  Name = AutochangerOdin
  Device = Drive-1
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
  Changer Device = /dev/autochanger1
}

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/nst0
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}

From bacula-dir.conf on sleipnir (where the director is):
Storage {
  Name = Library2
# Do not use "localhost" here
  Address = odin                # N.B. Use a fully qualified name here
  SDPort = 9103
  Password = "*****************"
  Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device
}




--
Steve Garcia
Ignorance killed the cat, curiosity was framed.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Steve Garcia

Steve Garcia
Ignorance killed the cat, curiosity was framed.

---- "Ana Emília M. Arruda" <[hidden email]> wrote:

> Hi steve,
>
> It seems we have a configuration issue. It is not a good idea to have
> symlinks to sg devices. They can change after a server reboot.
>
> **************
> From the /dev directory on odin:
> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> **************
>
> This can be very probably causing this issue with the label command. But I
> can't confirm this because I have never tried this.
>
> It is better to use the /dev/tape/by-id names and even better to create
> udev rules based on the tape library specific charactheristics  such as
> serial number.

Well, that symlink *is* generated by a udev rule:

SUBSYSTEM=="scsi_generic",ATTRS{vendor}=="IBM",ATTRS{model}=="3573-TL",SYMLINK+="autochanger1",GROUP="tape",MODE="0660"

I suppose I could put in a serial number to be more specific, but that would probably only matter if I were to have more than one changer.  

I *am* showing both the changer and the tape drive itself twice, but there is only one of each.  I notice that by-id they only show up once, but by path they come through twice:

root@odin:/etc/bacula# lsscsi -g
[0:2:0:0]    disk    DELL     PERC H730 Mini   4.27  /dev/sda   /dev/sg0
[1:0:0:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st0   /dev/sg2
[1:0:0:1]    mediumx IBM      3573-TL          E.30  /dev/sch0  /dev/sg3
[1:0:1:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st1   /dev/sg4
[1:0:1:1]    mediumx IBM      3573-TL          E.30  /dev/sch1  /dev/sg5
[6:2:0:0]    disk    DELL     PERC H830 Adp    4.27  /dev/sdb   /dev/sg1
[12:0:0:0]   cd/dvd  PLDS     DVD-ROM DS-8DBSH MD52  /dev/sr0   /dev/sg6

root@odin:/etc/bacula# ls -lR /dev/tape
/dev/tape:
total 0
drwxr-xr-x 2 root root 100 Jun  1 15:01 by-id
drwxr-xr-x 2 root root 120 Jun  1 15:01 by-path

/dev/tape/by-id:
total 0
lrwxrwxrwx 1 root root  9 Jun  1 15:01 scsi-1IBM_3573-TL_00X2U78BZ022_LL0 -> ../../sg3
lrwxrwxrwx 1 root root  9 Jun  1 15:01 scsi-35000e11164c42001 -> ../../st0
lrwxrwxrwx 1 root root 10 Jun  1 15:01 scsi-35000e11164c42001-nst -> ../../nst0

/dev/tape/by-path:
total 0
lrwxrwxrwx 1 root root  9 Jun  1 15:01 pci-0000:05:00.0-sas-phy2-lun-0 -> ../../st0
lrwxrwxrwx 1 root root 10 Jun  1 15:01 pci-0000:05:00.0-sas-phy2-lun-0-nst -> ../../nst0
lrwxrwxrwx 1 root root  9 Jun  1 15:01 pci-0000:05:00.0-sas-phy6-lun-0 -> ../../st1
lrwxrwxrwx 1 root root 10 Jun  1 15:01 pci-0000:05:00.0-sas-phy6-lun-0-nst -> ../../nst1


>
> A "ls -lR /dev/tape" and "lsscsi -g" will help you.
>
> Then you should chage:
>
> Changer Device = /dev/autochanger1 with the by-id name for mediumx
>
> And
>
> Archive Device = /dev/nst0 with the by-id name for the tape drive (remember
> to use here the one that ends with -nst).

OK, I've changed both to their by-id equivalents, but I get exactly the same error.  I can't say that's a big surprise, since the by-id mediumx points to /dev/sg3, just as /dev/autochanger1 did, and the by-id tape drive points to /dev/nst0.

I have a feeling this is in some way related to the fact that the director is connecting to the storage daemon remotely, but I can't see how that would make a difference.  It *is* able to retrieve an accurate listing of the cartridges in the library, it's only after I say "yes, start labeling" that it decides it can't connect to AutochangerOdin.  Note that it's not complaining about connecting to the physical device, but to the logical Autochanger device as defined in bacula-sd.conf.  Also note that the 3999 failures happen instantly -- there's no delay as if it were trying to connect to a hardware device and failing.

But wouldn't the listing have to come from a successful connection to AutochangerOdin?

Any other thoughts?  

>
> I noticed you have data spool configured. With an LTO6 It is very probably
> that you will slow down backups performance, unless you have clients with
> poor network performance.

I hadn't thought of that.  I'm used to much slower drives.  :-)  I'll test it, but you're probably right, so the spool directory will probably go away.

>
> Hope this helps you.
>
> Best regards,
> Ana
>
> El 26 jul. 2017 20:25, "Steve Garcia" <[hidden email]> escribió:
>
> OK, I've got my tape drive working (thanks Ana!) but I'm having trouble
> connecting to the autochanger it's in using the director.  This is the
> first time I've tried having a storage daemon on a different machine than
> the director.  The director is a slightly lower version (7.4.3 on Debian
> Jessie using backports) than the storage daemon (7.4.4 on stretch) but I
> had understood that those versions were close enough to work.
>
> So I'm hoping this is another configuration issue.
>
> Right now what I'm trying to do is label all the tapes in the new library.
>
> When I try to access the new storage from the director, it is able to get a
> listing of all the tapes, but it fails when it tries to actually do the
> labeling.  I get a "3999 Device not found or could not be opened" error.
> These errors show up quickly, there is no delay as it tries each slot, so
> it's obviously not getting far enough to try.  But it *is* obviously
> connecting to the remote storage, otherwise it wouldn't be able to obtain
> the slot list.
>
> What am I missing?
>
> root@sleipnir:/etc/bacula# bconsole
> Connecting to Director sleipnir:9101
> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> Enter a period to cancel a command.
> *label storage=Library2 barcodes
> Automatically selected Catalog: MyCatalog
> Using Catalog "MyCatalog"
> Connecting to Storage daemon Library2 at odin:9103 ...
> 3306 Issuing autochanger "slots" command.
> Device "AutochangerOdin" has 24 slots.
> Connecting to Storage daemon Library2 at odin:9103 ...
> 3306 Issuing autochanger "list" command.
> The following Volumes will be labeled:
> Slot  Volume
> ==============
>    1  000015L6
>    2  000018L6
>    3  000021L6
>    4  CLNU00L1
>    5  000014L6
>    6  000017L6
>    7  000020L6
>    8  CLN005L3
>    9  000013L6
>   10  000016L6
>   11  000019L6
>   12  000012L6
>   13  000009L6
>   14  000006L6
>   15  000003L6
>   16  000011L6
>   17  000008L6
>   18  000005L6
>   19  000002L6
>   20  000010L6
>   21  000007L6
>   22  000004L6
>   23  000001L6
> Do you want to label these Volumes? (yes|no):  yes
> Defined Pools:
>      1: Default
>      2: OdinPool
> Select the Pool (1-2): 2
> Connecting to Storage daemon Library2 at odin:9103 ...
> Sending label command for Volume "000015L6" Slot 1 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000015L6.
> Sending label command for Volume "000018L6" Slot 2 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000018L6.
> Sending label command for Volume "000021L6" Slot 3 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000021L6.
> Media record for Slot 4 Volume "CLNU00L1" already exists.
> Sending label command for Volume "000014L6" Slot 5 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000014L6.
> Sending label command for Volume "000017L6" Slot 6 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000017L6.
> Sending label command for Volume "000020L6" Slot 7 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000020L6.
> Media record for Slot 8 Volume "CLN005L3" already exists.
> Sending label command for Volume "000013L6" Slot 9 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000013L6.
> Sending label command for Volume "000016L6" Slot 10 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000016L6.
> Sending label command for Volume "000019L6" Slot 11 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000019L6.
> Sending label command for Volume "000012L6" Slot 12 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000012L6.
> Sending label command for Volume "000009L6" Slot 13 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000009L6.
> Sending label command for Volume "000006L6" Slot 14 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000006L6.
> Sending label command for Volume "000003L6" Slot 15 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000003L6.
> Sending label command for Volume "000011L6" Slot 16 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000011L6.
> Sending label command for Volume "000008L6" Slot 17 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000008L6.
> Sending label command for Volume "000005L6" Slot 18 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000005L6.
> Sending label command for Volume "000002L6" Slot 19 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000002L6.
> Sending label command for Volume "000010L6" Slot 20 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000010L6.
> Sending label command for Volume "000007L6" Slot 21 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000007L6.
> Sending label command for Volume "000004L6" Slot 22 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000004L6.
> Sending label command for Volume "000001L6" Slot 23 ...
> 3999 Device "AutochangerOdin" not found or could not be opened.
> Label command failed for Volume 000001L6.
> You have messages.
> *
>
> From the bacula-sd.conf on odin (where the library is):
> Autochanger {
>   Name = AutochangerOdin
>   Device = Drive-1
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/autochanger1
> }
>
> Device {
>   Name = Drive-1                      #
>   Description = "LT06 inside Dell TL2000 Library"
>   Drive Index = 0
>   Media Type = LT06
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>   SpoolDirectory = "/var/spool/bacula"
>   MaximumSpoolSize = 485G
>   Maximum Network Buffer Size = 65536
>   Offline On Unmount = no
>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> }
>
> From bacula-dir.conf on sleipnir (where the director is):
> Storage {
>   Name = Library2
> # Do not use "localhost" here
>   Address = odin                # N.B. Use a fully qualified name here
>   SDPort = 9103
>   Password = "*****************"
>   Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device
> }
>
>
>
>
> --
> Steve Garcia
> Ignorance killed the cat, curiosity was framed.
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Bacula-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/bacula-users


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
In reply to this post by Steve Garcia
Hi Steve,

Sorry, my mistake...

There is no problem in having a remote Storage Daemon with your tape library attached. This is a very usual configuration.

Before having a try with Bacula, I would recommend you to check if mtx and mt are properly working (please use /dev/tape/by-id names when running tests).

The error messages seems related to the tape drive and not to the tape library configuration. So I would try "/dev/tape/by-id/scsi-35000e11164c42001-nst" for the tape device:

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}

You should run btape tests before starting backups as well.

Best regards,

Ana


On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]> wrote:
OK, I've got my tape drive working (thanks Ana!) but I'm having trouble connecting to the autochanger it's in using the director.  This is the first time I've tried having a storage daemon on a different machine than the director.  The director is a slightly lower version (7.4.3 on Debian Jessie using backports) than the storage daemon (7.4.4 on stretch) but I had understood that those versions were close enough to work.

So I'm hoping this is another configuration issue.

Right now what I'm trying to do is label all the tapes in the new library.

When I try to access the new storage from the director, it is able to get a listing of all the tapes, but it fails when it tries to actually do the labeling.  I get a "3999 Device not found or could not be opened" error.  These errors show up quickly, there is no delay as it tries each slot, so it's obviously not getting far enough to try.  But it *is* obviously connecting to the remote storage, otherwise it wouldn't be able to obtain the slot list.

What am I missing?

root@sleipnir:/etc/bacula# bconsole
Connecting to Director sleipnir:9101
1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
Enter a period to cancel a command.
*label storage=Library2 barcodes
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "slots" command.
Device "AutochangerOdin" has 24 slots.
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "list" command.
The following Volumes will be labeled:
Slot  Volume
==============
   1  000015L6
   2  000018L6
   3  000021L6
   4  CLNU00L1
   5  000014L6
   6  000017L6
   7  000020L6
   8  CLN005L3
   9  000013L6
  10  000016L6
  11  000019L6
  12  000012L6
  13  000009L6
  14  000006L6
  15  000003L6
  16  000011L6
  17  000008L6
  18  000005L6
  19  000002L6
  20  000010L6
  21  000007L6
  22  000004L6
  23  000001L6
Do you want to label these Volumes? (yes|no):  yes
Defined Pools:
     1: Default
     2: OdinPool
Select the Pool (1-2): 2
Connecting to Storage daemon Library2 at odin:9103 ...
Sending label command for Volume "000015L6" Slot 1 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000015L6.
Sending label command for Volume "000018L6" Slot 2 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000018L6.
Sending label command for Volume "000021L6" Slot 3 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000021L6.
Media record for Slot 4 Volume "CLNU00L1" already exists.
Sending label command for Volume "000014L6" Slot 5 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000014L6.
Sending label command for Volume "000017L6" Slot 6 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000017L6.
Sending label command for Volume "000020L6" Slot 7 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000020L6.
Media record for Slot 8 Volume "CLN005L3" already exists.
Sending label command for Volume "000013L6" Slot 9 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000013L6.
Sending label command for Volume "000016L6" Slot 10 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000016L6.
Sending label command for Volume "000019L6" Slot 11 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000019L6.
Sending label command for Volume "000012L6" Slot 12 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000012L6.
Sending label command for Volume "000009L6" Slot 13 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000009L6.
Sending label command for Volume "000006L6" Slot 14 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000006L6.
Sending label command for Volume "000003L6" Slot 15 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000003L6.
Sending label command for Volume "000011L6" Slot 16 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000011L6.
Sending label command for Volume "000008L6" Slot 17 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000008L6.
Sending label command for Volume "000005L6" Slot 18 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000005L6.
Sending label command for Volume "000002L6" Slot 19 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000002L6.
Sending label command for Volume "000010L6" Slot 20 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000010L6.
Sending label command for Volume "000007L6" Slot 21 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000007L6.
Sending label command for Volume "000004L6" Slot 22 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000004L6.
Sending label command for Volume "000001L6" Slot 23 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000001L6.
You have messages.
*

From the bacula-sd.conf on odin (where the library is):
Autochanger {
  Name = AutochangerOdin
  Device = Drive-1
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
  Changer Device = /dev/autochanger1
}

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/nst0
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}

From bacula-dir.conf on sleipnir (where the director is):
Storage {
  Name = Library2
# Do not use "localhost" here
  Address = odin                # N.B. Use a fully qualified name here
  SDPort = 9103
  Password = "*****************"
  Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device
}

From the /dev directory on odin:
lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3



--
Steve Garcia
Ignorance killed the cat, curiosity was framed.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Darold Lucus
This is an example of my Autochanger listing in the bacula-sd.conf, this is only a partial list but you would follow that format. My autochanger has 16 slots and a drive, the drive-1 is the writing drive.

AutoChanger {
  Name = AutoChanger
  Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6, Drive-7, Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14, Drive-15, Drive-16, Drive-17
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
  Changer Device = /dev/sg1
}

Device {
  Name = Drive-1                      #
  Drive Index = 0
  Media Type = LTO5
  Archive Device = /dev/st0
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes

}

You also don't need this information in your storage section:

Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device


This is my example:

Storage {                             # definition of myself
  Name = nas-sd
  SDPort = 9103                  # Director's port     
  WorkingDirectory = "/var/lib/bacula"
  Pid Directory = "/var/run/bacula"
  Maximum Concurrent Jobs = 20
  SDAddress = IP.ADD.RE.SS
}


Hope this helps.


 

Sincerely,

Darold Lucus


cid:image002.png@01D06336.119F49E0

=====================
LAN Administrator

EMAC, Inc

618-529-4525 EXT:370

www.emacinc.com

=====================



This message is confidential. It may also be privileged or otherwise protected by work product immunity or other legal rules. If you have received it by mistake, please let us know by e-mail reply and delete it from your system; you may not copy this message or disclose its contents to anyone.


On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <[hidden email]> wrote:
Hi Steve,

Sorry, my mistake...

There is no problem in having a remote Storage Daemon with your tape library attached. This is a very usual configuration.

Before having a try with Bacula, I would recommend you to check if mtx and mt are properly working (please use /dev/tape/by-id names when running tests).

The error messages seems related to the tape drive and not to the tape library configuration. So I would try "/dev/tape/by-id/scsi-35000e11164c42001-nst" for the tape device:

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}

You should run btape tests before starting backups as well.

Best regards,

Ana


On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]> wrote:
OK, I've got my tape drive working (thanks Ana!) but I'm having trouble connecting to the autochanger it's in using the director.  This is the first time I've tried having a storage daemon on a different machine than the director.  The director is a slightly lower version (7.4.3 on Debian Jessie using backports) than the storage daemon (7.4.4 on stretch) but I had understood that those versions were close enough to work.

So I'm hoping this is another configuration issue.

Right now what I'm trying to do is label all the tapes in the new library.

When I try to access the new storage from the director, it is able to get a listing of all the tapes, but it fails when it tries to actually do the labeling.  I get a "3999 Device not found or could not be opened" error.  These errors show up quickly, there is no delay as it tries each slot, so it's obviously not getting far enough to try.  But it *is* obviously connecting to the remote storage, otherwise it wouldn't be able to obtain the slot list.

What am I missing?

root@sleipnir:/etc/bacula# bconsole
Connecting to Director sleipnir:9101
1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
Enter a period to cancel a command.
*label storage=Library2 barcodes
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "slots" command.
Device "AutochangerOdin" has 24 slots.
Connecting to Storage daemon Library2 at odin:9103 ...
3306 Issuing autochanger "list" command.
The following Volumes will be labeled:
Slot  Volume
==============
   1  000015L6
   2  000018L6
   3  000021L6
   4  CLNU00L1
   5  000014L6
   6  000017L6
   7  000020L6
   8  CLN005L3
   9  000013L6
  10  000016L6
  11  000019L6
  12  000012L6
  13  000009L6
  14  000006L6
  15  000003L6
  16  000011L6
  17  000008L6
  18  000005L6
  19  000002L6
  20  000010L6
  21  000007L6
  22  000004L6
  23  000001L6
Do you want to label these Volumes? (yes|no):  yes
Defined Pools:
     1: Default
     2: OdinPool
Select the Pool (1-2): 2
Connecting to Storage daemon Library2 at odin:9103 ...
Sending label command for Volume "000015L6" Slot 1 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000015L6.
Sending label command for Volume "000018L6" Slot 2 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000018L6.
Sending label command for Volume "000021L6" Slot 3 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000021L6.
Media record for Slot 4 Volume "CLNU00L1" already exists.
Sending label command for Volume "000014L6" Slot 5 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000014L6.
Sending label command for Volume "000017L6" Slot 6 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000017L6.
Sending label command for Volume "000020L6" Slot 7 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000020L6.
Media record for Slot 8 Volume "CLN005L3" already exists.
Sending label command for Volume "000013L6" Slot 9 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000013L6.
Sending label command for Volume "000016L6" Slot 10 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000016L6.
Sending label command for Volume "000019L6" Slot 11 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000019L6.
Sending label command for Volume "000012L6" Slot 12 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000012L6.
Sending label command for Volume "000009L6" Slot 13 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000009L6.
Sending label command for Volume "000006L6" Slot 14 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000006L6.
Sending label command for Volume "000003L6" Slot 15 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000003L6.
Sending label command for Volume "000011L6" Slot 16 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000011L6.
Sending label command for Volume "000008L6" Slot 17 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000008L6.
Sending label command for Volume "000005L6" Slot 18 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000005L6.
Sending label command for Volume "000002L6" Slot 19 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000002L6.
Sending label command for Volume "000010L6" Slot 20 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000010L6.
Sending label command for Volume "000007L6" Slot 21 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000007L6.
Sending label command for Volume "000004L6" Slot 22 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000004L6.
Sending label command for Volume "000001L6" Slot 23 ...
3999 Device "AutochangerOdin" not found or could not be opened.
Label command failed for Volume 000001L6.
You have messages.
*

From the bacula-sd.conf on odin (where the library is):
Autochanger {
  Name = AutochangerOdin
  Device = Drive-1
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
  Changer Device = /dev/autochanger1
}

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/nst0
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}

From bacula-dir.conf on sleipnir (where the director is):
Storage {
  Name = Library2
# Do not use "localhost" here
  Address = odin                # N.B. Use a fully qualified name here
  SDPort = 9103
  Password = "*****************"
  Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device
}

From the /dev directory on odin:
lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3



--
Steve Garcia
Ignorance killed the cat, curiosity was framed.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Steve Garcia
In reply to this post by Ana Emília M. Arruda

---- "Ana Emília M. Arruda" <[hidden email]> wrote:

> Hi Steve,
>
> Sorry, my mistake...
>
> There is no problem in having a remote Storage Daemon with your tape
> library attached. This is a very usual configuration.
>
> Before having a try with Bacula, I would recommend you to check if mtx and
> mt are properly working (please use /dev/tape/by-id names when running
> tests).

I've tested mt with both the by-id and with /dev/nst0, and it works identically.  Similarly, mtx-changer works perfectly with both the by-id and the /dev/autochanger1 names.  I haven't tested the naked mtx command, but since mtx-changer uses mtx, I figure that would be a valid test.

btest works perfectly with both the by-id name and with /dev/nst0

Unfortunately, bacula also works identically with both the by-id name and with /dev/nst0, and not in a good way.  I have altered my configuration to be identical with what you have suggested below, and it fails in exactly the same manner as before.

Since the by-id names are themselves symlinks to the same special files that I was using before, unless I change the hardware, I can't imagine any churn in those devices.  There will only ever be one /dev/nst0, since there will never be another tape drive added, and /dev/autochanger1 will always point to the correct changer device since it's set by udev based on the specifics of this changer.  Using the by-id name isn't a bad idea, but I don't think it's related to this problem.  

Is there maybe some way to generate a debug log that has more information than what shows up in the director?  "3999 Device "AutochangerOdin" not found or could not be opened" isn't very clear.

Could this be a permissions issue?  Both raw devices (/dev/sg3 and /dev/nst0) are owned by the "tape" group, and I double checked that the storage daemon *is* running as group "tape."

I'm still at a loss here.

>
> The error messages seems related to the tape drive and not to the tape
> library configuration. So I would try
> "/dev/tape/by-id/scsi-35000e11164c42001-nst"
> for the tape device:
>
> Device {
>   Name = Drive-1                      #
>   Description = "LT06 inside Dell TL2000 Library"
>   Drive Index = 0
>   Media Type = LT06
>   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>   SpoolDirectory = "/var/spool/bacula"
>   MaximumSpoolSize = 485G
>   Maximum Network Buffer Size = 65536
>   Offline On Unmount = no
>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> }
>
> You should run btape tests before starting backups as well.
>
> Best regards,
>
> Ana
>
>
> On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]> wrote:
>
> > OK, I've got my tape drive working (thanks Ana!) but I'm having trouble
> > connecting to the autochanger it's in using the director.  This is the
> > first time I've tried having a storage daemon on a different machine than
> > the director.  The director is a slightly lower version (7.4.3 on Debian
> > Jessie using backports) than the storage daemon (7.4.4 on stretch) but I
> > had understood that those versions were close enough to work.
> >
> > So I'm hoping this is another configuration issue.
> >
> > Right now what I'm trying to do is label all the tapes in the new library.
> >
> > When I try to access the new storage from the director, it is able to get
> > a listing of all the tapes, but it fails when it tries to actually do the
> > labeling.  I get a "3999 Device not found or could not be opened" error.
> > These errors show up quickly, there is no delay as it tries each slot, so
> > it's obviously not getting far enough to try.  But it *is* obviously
> > connecting to the remote storage, otherwise it wouldn't be able to obtain
> > the slot list.
> >
> > What am I missing?
> >
> > root@sleipnir:/etc/bacula# bconsole
> > Connecting to Director sleipnir:9101
> > 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> > Enter a period to cancel a command.
> > *label storage=Library2 barcodes
> > Automatically selected Catalog: MyCatalog
> > Using Catalog "MyCatalog"
> > Connecting to Storage daemon Library2 at odin:9103 ...
> > 3306 Issuing autochanger "slots" command.
> > Device "AutochangerOdin" has 24 slots.
> > Connecting to Storage daemon Library2 at odin:9103 ...
> > 3306 Issuing autochanger "list" command.
> > The following Volumes will be labeled:
> > Slot  Volume
> > ==============
> >    1  000015L6
> >    2  000018L6
> >    3  000021L6
> >    4  CLNU00L1
> >    5  000014L6
> >    6  000017L6
> >    7  000020L6
> >    8  CLN005L3
> >    9  000013L6
> >   10  000016L6
> >   11  000019L6
> >   12  000012L6
> >   13  000009L6
> >   14  000006L6
> >   15  000003L6
> >   16  000011L6
> >   17  000008L6
> >   18  000005L6
> >   19  000002L6
> >   20  000010L6
> >   21  000007L6
> >   22  000004L6
> >   23  000001L6
> > Do you want to label these Volumes? (yes|no):  yes
> > Defined Pools:
> >      1: Default
> >      2: OdinPool
> > Select the Pool (1-2): 2
> > Connecting to Storage daemon Library2 at odin:9103 ...
> > Sending label command for Volume "000015L6" Slot 1 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000015L6.
> > Sending label command for Volume "000018L6" Slot 2 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000018L6.
> > Sending label command for Volume "000021L6" Slot 3 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000021L6.
> > Media record for Slot 4 Volume "CLNU00L1" already exists.
> > Sending label command for Volume "000014L6" Slot 5 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000014L6.
> > Sending label command for Volume "000017L6" Slot 6 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000017L6.
> > Sending label command for Volume "000020L6" Slot 7 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000020L6.
> > Media record for Slot 8 Volume "CLN005L3" already exists.
> > Sending label command for Volume "000013L6" Slot 9 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000013L6.
> > Sending label command for Volume "000016L6" Slot 10 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000016L6.
> > Sending label command for Volume "000019L6" Slot 11 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000019L6.
> > Sending label command for Volume "000012L6" Slot 12 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000012L6.
> > Sending label command for Volume "000009L6" Slot 13 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000009L6.
> > Sending label command for Volume "000006L6" Slot 14 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000006L6.
> > Sending label command for Volume "000003L6" Slot 15 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000003L6.
> > Sending label command for Volume "000011L6" Slot 16 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000011L6.
> > Sending label command for Volume "000008L6" Slot 17 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000008L6.
> > Sending label command for Volume "000005L6" Slot 18 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000005L6.
> > Sending label command for Volume "000002L6" Slot 19 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000002L6.
> > Sending label command for Volume "000010L6" Slot 20 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000010L6.
> > Sending label command for Volume "000007L6" Slot 21 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000007L6.
> > Sending label command for Volume "000004L6" Slot 22 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000004L6.
> > Sending label command for Volume "000001L6" Slot 23 ...
> > 3999 Device "AutochangerOdin" not found or could not be opened.
> > Label command failed for Volume 000001L6.
> > You have messages.
> > *
> >
> > From the bacula-sd.conf on odin (where the library is):
> > Autochanger {
> >   Name = AutochangerOdin
> >   Device = Drive-1
> >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> >   Changer Device = /dev/autochanger1
> > }
> >
> > Device {
> >   Name = Drive-1                      #
> >   Description = "LT06 inside Dell TL2000 Library"
> >   Drive Index = 0
> >   Media Type = LT06
> >   Archive Device = /dev/nst0
> >   AutomaticMount = yes;               # when device opened, read it
> >   AlwaysOpen = yes;
> >   RemovableMedia = yes;
> >   RandomAccess = no;
> >   AutoChanger = yes
> >   SpoolDirectory = "/var/spool/bacula"
> >   MaximumSpoolSize = 485G
> >   Maximum Network Buffer Size = 65536
> >   Offline On Unmount = no
> >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > }
> >
> > From bacula-dir.conf on sleipnir (where the director is):
> > Storage {
> >   Name = Library2
> > # Do not use "localhost" here
> >   Address = odin                # N.B. Use a fully qualified name here
> >   SDPort = 9103
> >   Password = "*****************"
> >   Device = AutochangerOdin
> >   Media Type = LTO6
> >   Autochanger = yes                   # enable for autochanger device
> > }
> >
> > From the /dev directory on odin:
> > lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> > crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> >
> >
> >
> > --
> > Steve Garcia
> > Ignorance killed the cat, curiosity was framed.
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> >


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Steve Garcia
In reply to this post by Darold Lucus


---- Darold Lucus <[hidden email]> wrote:

> This is an example of my Autochanger listing in the bacula-sd.conf, this is
> only a partial list but you would follow that format. My autochanger has 16
> slots and a drive, the drive-1 is the writing drive.
>
> AutoChanger {
>   Name = AutoChanger
>   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6, Drive-7,
> Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> Drive-15, Drive-16, Drive-17
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/sg1
> }

So you're defining each slot as a drive, but only defining the actual drive as a device?

>
> Device {
>   Name = Drive-1                      #
>   Drive Index = 0
>   Media Type = LTO5
>   Archive Device = /dev/st0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>
> }
>
> You also don't need this information in your storage section:
>
> Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device

Well, I don't have those defined in the Storage resource of the bacula-sd.conf configuration (which is on the remote machine where the storage daemon lives) but I *do* have it in the Storage resource which is part of the bacula-dir.conf configuration.  The director gets quite cranky if you leave it out there.  :-)




>
> This is my example:
>
> Storage {                             # definition of myself
>   Name = nas-sd
>   SDPort = 9103                  # Director's port
>   WorkingDirectory = "/var/lib/bacula"
>   Pid Directory = "/var/run/bacula"
>   Maximum Concurrent Jobs = 20
>   SDAddress = IP.ADD.RE.SS
> }
>
>
> Hope this helps.
>
>
>
>
> Sincerely,
>
> Darold Lucus
>
>
> [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
>
> =====================
> LAN Administrator
> EMAC, Inc
> 618-529-4525 EXT:370
> www.emacinc.com
> =====================
>
>
>
> This message is confidential. It may also be privileged or otherwise
> protected by work product immunity or other legal rules. If you have
> received it by mistake, please let us know by e-mail reply and delete it
> from your system; you may not copy this message or disclose its contents to
> anyone.
>
> On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> [hidden email]> wrote:
>
> > Hi Steve,
> >
> > Sorry, my mistake...
> >
> > There is no problem in having a remote Storage Daemon with your tape
> > library attached. This is a very usual configuration.
> >
> > Before having a try with Bacula, I would recommend you to check if mtx and
> > mt are properly working (please use /dev/tape/by-id names when running
> > tests).
> >
> > The error messages seems related to the tape drive and not to the tape
> > library configuration. So I would try "/dev/tape/by-id/scsi-35000e11164c42001-nst"
> > for the tape device:
> >
> > Device {
> >   Name = Drive-1                      #
> >   Description = "LT06 inside Dell TL2000 Library"
> >   Drive Index = 0
> >   Media Type = LT06
> >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> >   AutomaticMount = yes;               # when device opened, read it
> >   AlwaysOpen = yes;
> >   RemovableMedia = yes;
> >   RandomAccess = no;
> >   AutoChanger = yes
> >   SpoolDirectory = "/var/spool/bacula"
> >   MaximumSpoolSize = 485G
> >   Maximum Network Buffer Size = 65536
> >   Offline On Unmount = no
> >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > }
> >
> > You should run btape tests before starting backups as well.
> >
> > Best regards,
> >
> > Ana
> >
> >
> > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]> wrote:
> >
> >> OK, I've got my tape drive working (thanks Ana!) but I'm having trouble
> >> connecting to the autochanger it's in using the director.  This is the
> >> first time I've tried having a storage daemon on a different machine than
> >> the director.  The director is a slightly lower version (7.4.3 on Debian
> >> Jessie using backports) than the storage daemon (7.4.4 on stretch) but I
> >> had understood that those versions were close enough to work.
> >>
> >> So I'm hoping this is another configuration issue.
> >>
> >> Right now what I'm trying to do is label all the tapes in the new library.
> >>
> >> When I try to access the new storage from the director, it is able to get
> >> a listing of all the tapes, but it fails when it tries to actually do the
> >> labeling.  I get a "3999 Device not found or could not be opened" error.
> >> These errors show up quickly, there is no delay as it tries each slot, so
> >> it's obviously not getting far enough to try.  But it *is* obviously
> >> connecting to the remote storage, otherwise it wouldn't be able to obtain
> >> the slot list.
> >>
> >> What am I missing?
> >>
> >> root@sleipnir:/etc/bacula# bconsole
> >> Connecting to Director sleipnir:9101
> >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> Enter a period to cancel a command.
> >> *label storage=Library2 barcodes
> >> Automatically selected Catalog: MyCatalog
> >> Using Catalog "MyCatalog"
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> 3306 Issuing autochanger "slots" command.
> >> Device "AutochangerOdin" has 24 slots.
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> 3306 Issuing autochanger "list" command.
> >> The following Volumes will be labeled:
> >> Slot  Volume
> >> ==============
> >>    1  000015L6
> >>    2  000018L6
> >>    3  000021L6
> >>    4  CLNU00L1
> >>    5  000014L6
> >>    6  000017L6
> >>    7  000020L6
> >>    8  CLN005L3
> >>    9  000013L6
> >>   10  000016L6
> >>   11  000019L6
> >>   12  000012L6
> >>   13  000009L6
> >>   14  000006L6
> >>   15  000003L6
> >>   16  000011L6
> >>   17  000008L6
> >>   18  000005L6
> >>   19  000002L6
> >>   20  000010L6
> >>   21  000007L6
> >>   22  000004L6
> >>   23  000001L6
> >> Do you want to label these Volumes? (yes|no):  yes
> >> Defined Pools:
> >>      1: Default
> >>      2: OdinPool
> >> Select the Pool (1-2): 2
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> Sending label command for Volume "000015L6" Slot 1 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000015L6.
> >> Sending label command for Volume "000018L6" Slot 2 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000018L6.
> >> Sending label command for Volume "000021L6" Slot 3 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000021L6.
> >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> >> Sending label command for Volume "000014L6" Slot 5 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000014L6.
> >> Sending label command for Volume "000017L6" Slot 6 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000017L6.
> >> Sending label command for Volume "000020L6" Slot 7 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000020L6.
> >> Media record for Slot 8 Volume "CLN005L3" already exists.
> >> Sending label command for Volume "000013L6" Slot 9 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000013L6.
> >> Sending label command for Volume "000016L6" Slot 10 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000016L6.
> >> Sending label command for Volume "000019L6" Slot 11 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000019L6.
> >> Sending label command for Volume "000012L6" Slot 12 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000012L6.
> >> Sending label command for Volume "000009L6" Slot 13 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000009L6.
> >> Sending label command for Volume "000006L6" Slot 14 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000006L6.
> >> Sending label command for Volume "000003L6" Slot 15 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000003L6.
> >> Sending label command for Volume "000011L6" Slot 16 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000011L6.
> >> Sending label command for Volume "000008L6" Slot 17 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000008L6.
> >> Sending label command for Volume "000005L6" Slot 18 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000005L6.
> >> Sending label command for Volume "000002L6" Slot 19 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000002L6.
> >> Sending label command for Volume "000010L6" Slot 20 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000010L6.
> >> Sending label command for Volume "000007L6" Slot 21 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000007L6.
> >> Sending label command for Volume "000004L6" Slot 22 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000004L6.
> >> Sending label command for Volume "000001L6" Slot 23 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000001L6.
> >> You have messages.
> >> *
> >>
> >> From the bacula-sd.conf on odin (where the library is):
> >> Autochanger {
> >>   Name = AutochangerOdin
> >>   Device = Drive-1
> >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> >>   Changer Device = /dev/autochanger1
> >> }
> >>
> >> Device {
> >>   Name = Drive-1                      #
> >>   Description = "LT06 inside Dell TL2000 Library"
> >>   Drive Index = 0
> >>   Media Type = LT06
> >>   Archive Device = /dev/nst0
> >>   AutomaticMount = yes;               # when device opened, read it
> >>   AlwaysOpen = yes;
> >>   RemovableMedia = yes;
> >>   RandomAccess = no;
> >>   AutoChanger = yes
> >>   SpoolDirectory = "/var/spool/bacula"
> >>   MaximumSpoolSize = 485G
> >>   Maximum Network Buffer Size = 65536
> >>   Offline On Unmount = no
> >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> }
> >>
> >> From bacula-dir.conf on sleipnir (where the director is):
> >> Storage {
> >>   Name = Library2
> >> # Do not use "localhost" here
> >>   Address = odin                # N.B. Use a fully qualified name here
> >>   SDPort = 9103
> >>   Password = "*****************"
> >>   Device = AutochangerOdin
> >>   Media Type = LTO6
> >>   Autochanger = yes                   # enable for autochanger device
> >> }
> >>
> >> From the /dev directory on odin:
> >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> >>
> >>
> >>
> >> --
> >> Steve Garcia
> >> Ignorance killed the cat, curiosity was framed.
> >>
> >> ------------------------------------------------------------
> >> ------------------
> >> Check out the vibrant tech community on one of the world's most
> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> _______________________________________________
> >> Bacula-users mailing list
> >> [hidden email]
> >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> >>
> >
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> >
> >


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
Hello Steve,

I think we will need to speak the same language here :-)

You have your Director running at:



On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]> wrote:


---- Darold Lucus <[hidden email]> wrote:
> This is an example of my Autochanger listing in the bacula-sd.conf, this is
> only a partial list but you would follow that format. My autochanger has 16
> slots and a drive, the drive-1 is the writing drive.
>
> AutoChanger {
>   Name = AutoChanger
>   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6, Drive-7,
> Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> Drive-15, Drive-16, Drive-17
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/sg1
> }

So you're defining each slot as a drive, but only defining the actual drive as a device?

>
> Device {
>   Name = Drive-1                      #
>   Drive Index = 0
>   Media Type = LTO5
>   Archive Device = /dev/st0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>
> }
>
> You also don't need this information in your storage section:
>
> Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device

Well, I don't have those defined in the Storage resource of the bacula-sd.conf configuration (which is on the remote machine where the storage daemon lives) but I *do* have it in the Storage resource which is part of the bacula-dir.conf configuration.  The director gets quite cranky if you leave it out there.  :-)




>
> This is my example:
>
> Storage {                             # definition of myself
>   Name = nas-sd
>   SDPort = 9103                  # Director's port
>   WorkingDirectory = "/var/lib/bacula"
>   Pid Directory = "/var/run/bacula"
>   Maximum Concurrent Jobs = 20
>   SDAddress = IP.ADD.RE.SS
> }
>
>
> Hope this helps.
>
>
>
>
> Sincerely,
>
> Darold Lucus
>
>
> [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
>
> =====================
> LAN Administrator
> EMAC, Inc
> <a href="tel:618-529-4525%20EXT%3A370" value="+16185294525">618-529-4525 EXT:370
> www.emacinc.com
> =====================
>
>
>
> This message is confidential. It may also be privileged or otherwise
> protected by work product immunity or other legal rules. If you have
> received it by mistake, please let us know by e-mail reply and delete it
> from your system; you may not copy this message or disclose its contents to
> anyone.
>
> On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> [hidden email]> wrote:
>
> > Hi Steve,
> >
> > Sorry, my mistake...
> >
> > There is no problem in having a remote Storage Daemon with your tape
> > library attached. This is a very usual configuration.
> >
> > Before having a try with Bacula, I would recommend you to check if mtx and
> > mt are properly working (please use /dev/tape/by-id names when running
> > tests).
> >
> > The error messages seems related to the tape drive and not to the tape
> > library configuration. So I would try "/dev/tape/by-id/scsi-35000e11164c42001-nst"
> > for the tape device:
> >
> > Device {
> >   Name = Drive-1                      #
> >   Description = "LT06 inside Dell TL2000 Library"
> >   Drive Index = 0
> >   Media Type = LT06
> >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> >   AutomaticMount = yes;               # when device opened, read it
> >   AlwaysOpen = yes;
> >   RemovableMedia = yes;
> >   RandomAccess = no;
> >   AutoChanger = yes
> >   SpoolDirectory = "/var/spool/bacula"
> >   MaximumSpoolSize = 485G
> >   Maximum Network Buffer Size = 65536
> >   Offline On Unmount = no
> >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > }
> >
> > You should run btape tests before starting backups as well.
> >
> > Best regards,
> >
> > Ana
> >
> >
> > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]> wrote:
> >
> >> OK, I've got my tape drive working (thanks Ana!) but I'm having trouble
> >> connecting to the autochanger it's in using the director.  This is the
> >> first time I've tried having a storage daemon on a different machine than
> >> the director.  The director is a slightly lower version (7.4.3 on Debian
> >> Jessie using backports) than the storage daemon (7.4.4 on stretch) but I
> >> had understood that those versions were close enough to work.
> >>
> >> So I'm hoping this is another configuration issue.
> >>
> >> Right now what I'm trying to do is label all the tapes in the new library.
> >>
> >> When I try to access the new storage from the director, it is able to get
> >> a listing of all the tapes, but it fails when it tries to actually do the
> >> labeling.  I get a "3999 Device not found or could not be opened" error.
> >> These errors show up quickly, there is no delay as it tries each slot, so
> >> it's obviously not getting far enough to try.  But it *is* obviously
> >> connecting to the remote storage, otherwise it wouldn't be able to obtain
> >> the slot list.
> >>
> >> What am I missing?
> >>
> >> root@sleipnir:/etc/bacula# bconsole
> >> Connecting to Director sleipnir:9101
> >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> Enter a period to cancel a command.
> >> *label storage=Library2 barcodes
> >> Automatically selected Catalog: MyCatalog
> >> Using Catalog "MyCatalog"
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> 3306 Issuing autochanger "slots" command.
> >> Device "AutochangerOdin" has 24 slots.
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> 3306 Issuing autochanger "list" command.
> >> The following Volumes will be labeled:
> >> Slot  Volume
> >> ==============
> >>    1  000015L6
> >>    2  000018L6
> >>    3  000021L6
> >>    4  CLNU00L1
> >>    5  000014L6
> >>    6  000017L6
> >>    7  000020L6
> >>    8  CLN005L3
> >>    9  000013L6
> >>   10  000016L6
> >>   11  000019L6
> >>   12  000012L6
> >>   13  000009L6
> >>   14  000006L6
> >>   15  000003L6
> >>   16  000011L6
> >>   17  000008L6
> >>   18  000005L6
> >>   19  000002L6
> >>   20  000010L6
> >>   21  000007L6
> >>   22  000004L6
> >>   23  000001L6
> >> Do you want to label these Volumes? (yes|no):  yes
> >> Defined Pools:
> >>      1: Default
> >>      2: OdinPool
> >> Select the Pool (1-2): 2
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> Sending label command for Volume "000015L6" Slot 1 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000015L6.
> >> Sending label command for Volume "000018L6" Slot 2 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000018L6.
> >> Sending label command for Volume "000021L6" Slot 3 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000021L6.
> >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> >> Sending label command for Volume "000014L6" Slot 5 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000014L6.
> >> Sending label command for Volume "000017L6" Slot 6 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000017L6.
> >> Sending label command for Volume "000020L6" Slot 7 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000020L6.
> >> Media record for Slot 8 Volume "CLN005L3" already exists.
> >> Sending label command for Volume "000013L6" Slot 9 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000013L6.
> >> Sending label command for Volume "000016L6" Slot 10 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000016L6.
> >> Sending label command for Volume "000019L6" Slot 11 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000019L6.
> >> Sending label command for Volume "000012L6" Slot 12 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000012L6.
> >> Sending label command for Volume "000009L6" Slot 13 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000009L6.
> >> Sending label command for Volume "000006L6" Slot 14 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000006L6.
> >> Sending label command for Volume "000003L6" Slot 15 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000003L6.
> >> Sending label command for Volume "000011L6" Slot 16 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000011L6.
> >> Sending label command for Volume "000008L6" Slot 17 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000008L6.
> >> Sending label command for Volume "000005L6" Slot 18 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000005L6.
> >> Sending label command for Volume "000002L6" Slot 19 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000002L6.
> >> Sending label command for Volume "000010L6" Slot 20 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000010L6.
> >> Sending label command for Volume "000007L6" Slot 21 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000007L6.
> >> Sending label command for Volume "000004L6" Slot 22 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000004L6.
> >> Sending label command for Volume "000001L6" Slot 23 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000001L6.
> >> You have messages.
> >> *
> >>
> >> From the bacula-sd.conf on odin (where the library is):
> >> Autochanger {
> >>   Name = AutochangerOdin
> >>   Device = Drive-1
> >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> >>   Changer Device = /dev/autochanger1
> >> }
> >>
> >> Device {
> >>   Name = Drive-1                      #
> >>   Description = "LT06 inside Dell TL2000 Library"
> >>   Drive Index = 0
> >>   Media Type = LT06
> >>   Archive Device = /dev/nst0
> >>   AutomaticMount = yes;               # when device opened, read it
> >>   AlwaysOpen = yes;
> >>   RemovableMedia = yes;
> >>   RandomAccess = no;
> >>   AutoChanger = yes
> >>   SpoolDirectory = "/var/spool/bacula"
> >>   MaximumSpoolSize = 485G
> >>   Maximum Network Buffer Size = 65536
> >>   Offline On Unmount = no
> >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> }
> >>
> >> From bacula-dir.conf on sleipnir (where the director is):
> >> Storage {
> >>   Name = Library2
> >> # Do not use "localhost" here
> >>   Address = odin                # N.B. Use a fully qualified name here
> >>   SDPort = 9103
> >>   Password = "*****************"
> >>   Device = AutochangerOdin
> >>   Media Type = LTO6
> >>   Autochanger = yes                   # enable for autochanger device
> >> }
> >>
> >> From the /dev directory on odin:
> >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> >>
> >>
> >>
> >> --
> >> Steve Garcia
> >> Ignorance killed the cat, curiosity was framed.
> >>
> >> ------------------------------------------------------------
> >> ------------------
> >> Check out the vibrant tech community on one of the world's most
> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> _______________________________________________
> >> Bacula-users mailing list
> >> [hidden email]
> >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> >>
> >
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> >
> >



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
In reply to this post by Steve Garcia
Hello Steve,

Sorry, I sent an incomplete message.

I think we will need to speak the same language here :-)

You have your Director running at sleipnir host:

root@sleipnir:/etc/bacula# bconsole
Connecting to Director sleipnir:9101
1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)

with the Autochanger configuration on Director:

From bacula-dir.conf on sleipnir (where the director is):
Storage {
  Name = Library2
# Do not use "localhost" here
  Address = odin                # N.B. Use a fully qualified name here
  SDPort = 9103
  Password = "*****************"
  Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device
}

And you have your remote Storage Daemon installed in a host called odin with the following configuration:

From the bacula-sd.conf on odin (where the library is):
Autochanger {
  Name = AutochangerOdin
  Device = Drive-1
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
  Changer Device = /dev/autochanger1
}

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
  Archive Device = /dev/nst0
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}
This is perfect.

You are right, the permission needs to be checked.

If you have bacula-sd runnig as bacula user, the bacula user must be member of tape group.

Also, you can start the bacula-sd daemon in debug mode to get some debug output and maybe help in this case. The following command should be run on odin host:

* sudo -u bacula -g tape /opt/ bacula/bin/bacula-sd -d200

This will produce debug information on the Storage Daemon host and maybe we can have more information about this problem.

Best,
Ana

On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]> wrote:


---- Darold Lucus <[hidden email]> wrote:
> This is an example of my Autochanger listing in the bacula-sd.conf, this is
> only a partial list but you would follow that format. My autochanger has 16
> slots and a drive, the drive-1 is the writing drive.
>
> AutoChanger {
>   Name = AutoChanger
>   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6, Drive-7,
> Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> Drive-15, Drive-16, Drive-17
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/sg1
> }

So you're defining each slot as a drive, but only defining the actual drive as a device?

>
> Device {
>   Name = Drive-1                      #
>   Drive Index = 0
>   Media Type = LTO5
>   Archive Device = /dev/st0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>
> }
>
> You also don't need this information in your storage section:
>
> Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device

Well, I don't have those defined in the Storage resource of the bacula-sd.conf configuration (which is on the remote machine where the storage daemon lives) but I *do* have it in the Storage resource which is part of the bacula-dir.conf configuration.  The director gets quite cranky if you leave it out there.  :-)




>
> This is my example:
>
> Storage {                             # definition of myself
>   Name = nas-sd
>   SDPort = 9103                  # Director's port
>   WorkingDirectory = "/var/lib/bacula"
>   Pid Directory = "/var/run/bacula"
>   Maximum Concurrent Jobs = 20
>   SDAddress = IP.ADD.RE.SS
> }
>
>
> Hope this helps.
>
>
>
>
> Sincerely,
>
> Darold Lucus
>
>
> [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
>
> =====================
> LAN Administrator
> EMAC, Inc
> <a href="tel:618-529-4525%20EXT%3A370" value="+16185294525">618-529-4525 EXT:370
> www.emacinc.com
> =====================
>
>
>
> This message is confidential. It may also be privileged or otherwise
> protected by work product immunity or other legal rules. If you have
> received it by mistake, please let us know by e-mail reply and delete it
> from your system; you may not copy this message or disclose its contents to
> anyone.
>
> On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> [hidden email]> wrote:
>
> > Hi Steve,
> >
> > Sorry, my mistake...
> >
> > There is no problem in having a remote Storage Daemon with your tape
> > library attached. This is a very usual configuration.
> >
> > Before having a try with Bacula, I would recommend you to check if mtx and
> > mt are properly working (please use /dev/tape/by-id names when running
> > tests).
> >
> > The error messages seems related to the tape drive and not to the tape
> > library configuration. So I would try "/dev/tape/by-id/scsi-35000e11164c42001-nst"
> > for the tape device:
> >
> > Device {
> >   Name = Drive-1                      #
> >   Description = "LT06 inside Dell TL2000 Library"
> >   Drive Index = 0
> >   Media Type = LT06
> >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> >   AutomaticMount = yes;               # when device opened, read it
> >   AlwaysOpen = yes;
> >   RemovableMedia = yes;
> >   RandomAccess = no;
> >   AutoChanger = yes
> >   SpoolDirectory = "/var/spool/bacula"
> >   MaximumSpoolSize = 485G
> >   Maximum Network Buffer Size = 65536
> >   Offline On Unmount = no
> >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > }
> >
> > You should run btape tests before starting backups as well.
> >
> > Best regards,
> >
> > Ana
> >
> >
> > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]> wrote:
> >
> >> OK, I've got my tape drive working (thanks Ana!) but I'm having trouble
> >> connecting to the autochanger it's in using the director.  This is the
> >> first time I've tried having a storage daemon on a different machine than
> >> the director.  The director is a slightly lower version (7.4.3 on Debian
> >> Jessie using backports) than the storage daemon (7.4.4 on stretch) but I
> >> had understood that those versions were close enough to work.
> >>
> >> So I'm hoping this is another configuration issue.
> >>
> >> Right now what I'm trying to do is label all the tapes in the new library.
> >>
> >> When I try to access the new storage from the director, it is able to get
> >> a listing of all the tapes, but it fails when it tries to actually do the
> >> labeling.  I get a "3999 Device not found or could not be opened" error.
> >> These errors show up quickly, there is no delay as it tries each slot, so
> >> it's obviously not getting far enough to try.  But it *is* obviously
> >> connecting to the remote storage, otherwise it wouldn't be able to obtain
> >> the slot list.
> >>
> >> What am I missing?
> >>
> >> root@sleipnir:/etc/bacula# bconsole
> >> Connecting to Director sleipnir:9101
> >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> Enter a period to cancel a command.
> >> *label storage=Library2 barcodes
> >> Automatically selected Catalog: MyCatalog
> >> Using Catalog "MyCatalog"
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> 3306 Issuing autochanger "slots" command.
> >> Device "AutochangerOdin" has 24 slots.
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> 3306 Issuing autochanger "list" command.
> >> The following Volumes will be labeled:
> >> Slot  Volume
> >> ==============
> >>    1  000015L6
> >>    2  000018L6
> >>    3  000021L6
> >>    4  CLNU00L1
> >>    5  000014L6
> >>    6  000017L6
> >>    7  000020L6
> >>    8  CLN005L3
> >>    9  000013L6
> >>   10  000016L6
> >>   11  000019L6
> >>   12  000012L6
> >>   13  000009L6
> >>   14  000006L6
> >>   15  000003L6
> >>   16  000011L6
> >>   17  000008L6
> >>   18  000005L6
> >>   19  000002L6
> >>   20  000010L6
> >>   21  000007L6
> >>   22  000004L6
> >>   23  000001L6
> >> Do you want to label these Volumes? (yes|no):  yes
> >> Defined Pools:
> >>      1: Default
> >>      2: OdinPool
> >> Select the Pool (1-2): 2
> >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> Sending label command for Volume "000015L6" Slot 1 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000015L6.
> >> Sending label command for Volume "000018L6" Slot 2 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000018L6.
> >> Sending label command for Volume "000021L6" Slot 3 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000021L6.
> >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> >> Sending label command for Volume "000014L6" Slot 5 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000014L6.
> >> Sending label command for Volume "000017L6" Slot 6 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000017L6.
> >> Sending label command for Volume "000020L6" Slot 7 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000020L6.
> >> Media record for Slot 8 Volume "CLN005L3" already exists.
> >> Sending label command for Volume "000013L6" Slot 9 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000013L6.
> >> Sending label command for Volume "000016L6" Slot 10 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000016L6.
> >> Sending label command for Volume "000019L6" Slot 11 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000019L6.
> >> Sending label command for Volume "000012L6" Slot 12 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000012L6.
> >> Sending label command for Volume "000009L6" Slot 13 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000009L6.
> >> Sending label command for Volume "000006L6" Slot 14 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000006L6.
> >> Sending label command for Volume "000003L6" Slot 15 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000003L6.
> >> Sending label command for Volume "000011L6" Slot 16 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000011L6.
> >> Sending label command for Volume "000008L6" Slot 17 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000008L6.
> >> Sending label command for Volume "000005L6" Slot 18 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000005L6.
> >> Sending label command for Volume "000002L6" Slot 19 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000002L6.
> >> Sending label command for Volume "000010L6" Slot 20 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000010L6.
> >> Sending label command for Volume "000007L6" Slot 21 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000007L6.
> >> Sending label command for Volume "000004L6" Slot 22 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000004L6.
> >> Sending label command for Volume "000001L6" Slot 23 ...
> >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> Label command failed for Volume 000001L6.
> >> You have messages.
> >> *
> >>
> >> From the bacula-sd.conf on odin (where the library is):
> >> Autochanger {
> >>   Name = AutochangerOdin
> >>   Device = Drive-1
> >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> >>   Changer Device = /dev/autochanger1
> >> }
> >>
> >> Device {
> >>   Name = Drive-1                      #
> >>   Description = "LT06 inside Dell TL2000 Library"
> >>   Drive Index = 0
> >>   Media Type = LT06
> >>   Archive Device = /dev/nst0
> >>   AutomaticMount = yes;               # when device opened, read it
> >>   AlwaysOpen = yes;
> >>   RemovableMedia = yes;
> >>   RandomAccess = no;
> >>   AutoChanger = yes
> >>   SpoolDirectory = "/var/spool/bacula"
> >>   MaximumSpoolSize = 485G
> >>   Maximum Network Buffer Size = 65536
> >>   Offline On Unmount = no
> >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> }
> >>
> >> From bacula-dir.conf on sleipnir (where the director is):
> >> Storage {
> >>   Name = Library2
> >> # Do not use "localhost" here
> >>   Address = odin                # N.B. Use a fully qualified name here
> >>   SDPort = 9103
> >>   Password = "*****************"
> >>   Device = AutochangerOdin
> >>   Media Type = LTO6
> >>   Autochanger = yes                   # enable for autochanger device
> >> }
> >>
> >> From the /dev directory on odin:
> >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> >>
> >>
> >>
> >> --
> >> Steve Garcia
> >> Ignorance killed the cat, curiosity was framed.
> >>
> >> ------------------------------------------------------------
> >> ------------------
> >> Check out the vibrant tech community on one of the world's most
> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> _______________________________________________
> >> Bacula-users mailing list
> >> [hidden email]
> >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> >>
> >
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> >
> >



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Steve Garcia
In reply to this post by Ana Emília M. Arruda



---- "Ana Emília M. Arruda" <[hidden email]> wrote:
> Hello Steve,
>
> I think we will need to speak the same language here :-)
>
> You have your Director running at:

Good plan.  I think we're getting someone else's configuration mixed up in here, and that's confusing...  :-)

My director is running on sleipnir (Debian 8 Jessie, bacula 7.4.3), with the following settings:

Storage {
  Name = Library2
  Address = odin                # N.B. Use a fully qualified name here
  SDPort = 9103
  Device = AutochangerOdin
  Media Type = LTO6
  Autochanger = yes                   # enable for autochanger device
}

Pool {
  Name = OdinPool
  Pool Type = Backup
  Storage = Library2
  Recycle = yes                       # Bacula can automatically recycle Volumes
  AutoPrune = yes                     # Prune expired volumes
  Volume Retention = 180 days         # one year
  Recycle Oldest Volume = yes
  Cleaning Prefix = "CLN"
}


The storage daemon is running on odin (Debian 9.0 Stretch, bacula 7.4.4), with the following settings:

Autochanger {
  Name = AutochangerOdin
  Device = Drive-1
  Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
#  Changer Device = /dev/autochanger1
  Changer Device = /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0
}

Device {
  Name = Drive-1                      #
  Description = "LT06 inside Dell TL2000 Library"
  Drive Index = 0
  Media Type = LT06
#  Archive Device = /dev/nst0
  Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
  AutomaticMount = yes;               # when device opened, read it
  AlwaysOpen = yes;
  RemovableMedia = yes;
  RandomAccess = no;
  AutoChanger = yes
  SpoolDirectory = "/var/spool/bacula"
  MaximumSpoolSize = 485G
  Maximum Network Buffer Size = 65536
  Offline On Unmount = no
  Alert Command = "sh -c 'smartctl -H -l error %c'"
}



>
>
>
> On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]> wrote:
>
> >
> >
> > ---- Darold Lucus <[hidden email]> wrote:
> > > This is an example of my Autochanger listing in the bacula-sd.conf, this
> > is
> > > only a partial list but you would follow that format. My autochanger has
> > 16
> > > slots and a drive, the drive-1 is the writing drive.
> > >
> > > AutoChanger {
> > >   Name = AutoChanger
> > >   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6,
> > Drive-7,
> > > Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> > > Drive-15, Drive-16, Drive-17
> > >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > >   Changer Device = /dev/sg1
> > > }
> >
> > So you're defining each slot as a drive, but only defining the actual
> > drive as a device?
> >
> > >
> > > Device {
> > >   Name = Drive-1                      #
> > >   Drive Index = 0
> > >   Media Type = LTO5
> > >   Archive Device = /dev/st0
> > >   AutomaticMount = yes;               # when device opened, read it
> > >   AlwaysOpen = yes;
> > >   RemovableMedia = yes;
> > >   RandomAccess = no;
> > >   AutoChanger = yes
> > >
> > > }
> > >
> > > You also don't need this information in your storage section:
> > >
> > > Device = AutochangerOdin
> > >   Media Type = LTO6
> > >   Autochanger = yes                   # enable for autochanger device
> >
> > Well, I don't have those defined in the Storage resource of the
> > bacula-sd.conf configuration (which is on the remote machine where the
> > storage daemon lives) but I *do* have it in the Storage resource which is
> > part of the bacula-dir.conf configuration.  The director gets quite cranky
> > if you leave it out there.  :-)
> >
> >
> >
> >
> > >
> > > This is my example:
> > >
> > > Storage {                             # definition of myself
> > >   Name = nas-sd
> > >   SDPort = 9103                  # Director's port
> > >   WorkingDirectory = "/var/lib/bacula"
> > >   Pid Directory = "/var/run/bacula"
> > >   Maximum Concurrent Jobs = 20
> > >   SDAddress = IP.ADD.RE.SS
> > > }
> > >
> > >
> > > Hope this helps.
> > >
> > >
> > >
> > >
> > > Sincerely,
> > >
> > > Darold Lucus
> > >
> > >
> > > [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
> > >
> > > =====================
> > > LAN Administrator
> > > EMAC, Inc
> > > 618-529-4525 EXT:370
> > > www.emacinc.com
> > > =====================
> > >
> > >
> > >
> > > This message is confidential. It may also be privileged or otherwise
> > > protected by work product immunity or other legal rules. If you have
> > > received it by mistake, please let us know by e-mail reply and delete it
> > > from your system; you may not copy this message or disclose its contents
> > to
> > > anyone.
> > >
> > > On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> > > [hidden email]> wrote:
> > >
> > > > Hi Steve,
> > > >
> > > > Sorry, my mistake...
> > > >
> > > > There is no problem in having a remote Storage Daemon with your tape
> > > > library attached. This is a very usual configuration.
> > > >
> > > > Before having a try with Bacula, I would recommend you to check if mtx
> > and
> > > > mt are properly working (please use /dev/tape/by-id names when running
> > > > tests).
> > > >
> > > > The error messages seems related to the tape drive and not to the tape
> > > > library configuration. So I would try "/dev/tape/by-id/scsi-
> > 35000e11164c42001-nst"
> > > > for the tape device:
> > > >
> > > > Device {
> > > >   Name = Drive-1                      #
> > > >   Description = "LT06 inside Dell TL2000 Library"
> > > >   Drive Index = 0
> > > >   Media Type = LT06
> > > >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> > > >   AutomaticMount = yes;               # when device opened, read it
> > > >   AlwaysOpen = yes;
> > > >   RemovableMedia = yes;
> > > >   RandomAccess = no;
> > > >   AutoChanger = yes
> > > >   SpoolDirectory = "/var/spool/bacula"
> > > >   MaximumSpoolSize = 485G
> > > >   Maximum Network Buffer Size = 65536
> > > >   Offline On Unmount = no
> > > >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > > }
> > > >
> > > > You should run btape tests before starting backups as well.
> > > >
> > > > Best regards,
> > > >
> > > > Ana
> > > >
> > > >
> > > > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]>
> > wrote:
> > > >
> > > >> OK, I've got my tape drive working (thanks Ana!) but I'm having
> > trouble
> > > >> connecting to the autochanger it's in using the director.  This is the
> > > >> first time I've tried having a storage daemon on a different machine
> > than
> > > >> the director.  The director is a slightly lower version (7.4.3 on
> > Debian
> > > >> Jessie using backports) than the storage daemon (7.4.4 on stretch)
> > but I
> > > >> had understood that those versions were close enough to work.
> > > >>
> > > >> So I'm hoping this is another configuration issue.
> > > >>
> > > >> Right now what I'm trying to do is label all the tapes in the new
> > library.
> > > >>
> > > >> When I try to access the new storage from the director, it is able to
> > get
> > > >> a listing of all the tapes, but it fails when it tries to actually do
> > the
> > > >> labeling.  I get a "3999 Device not found or could not be opened"
> > error.
> > > >> These errors show up quickly, there is no delay as it tries each
> > slot, so
> > > >> it's obviously not getting far enough to try.  But it *is* obviously
> > > >> connecting to the remote storage, otherwise it wouldn't be able to
> > obtain
> > > >> the slot list.
> > > >>
> > > >> What am I missing?
> > > >>
> > > >> root@sleipnir:/etc/bacula# bconsole
> > > >> Connecting to Director sleipnir:9101
> > > >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> > > >> Enter a period to cancel a command.
> > > >> *label storage=Library2 barcodes
> > > >> Automatically selected Catalog: MyCatalog
> > > >> Using Catalog "MyCatalog"
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "slots" command.
> > > >> Device "AutochangerOdin" has 24 slots.
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "list" command.
> > > >> The following Volumes will be labeled:
> > > >> Slot  Volume
> > > >> ==============
> > > >>    1  000015L6
> > > >>    2  000018L6
> > > >>    3  000021L6
> > > >>    4  CLNU00L1
> > > >>    5  000014L6
> > > >>    6  000017L6
> > > >>    7  000020L6
> > > >>    8  CLN005L3
> > > >>    9  000013L6
> > > >>   10  000016L6
> > > >>   11  000019L6
> > > >>   12  000012L6
> > > >>   13  000009L6
> > > >>   14  000006L6
> > > >>   15  000003L6
> > > >>   16  000011L6
> > > >>   17  000008L6
> > > >>   18  000005L6
> > > >>   19  000002L6
> > > >>   20  000010L6
> > > >>   21  000007L6
> > > >>   22  000004L6
> > > >>   23  000001L6
> > > >> Do you want to label these Volumes? (yes|no):  yes
> > > >> Defined Pools:
> > > >>      1: Default
> > > >>      2: OdinPool
> > > >> Select the Pool (1-2): 2
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> Sending label command for Volume "000015L6" Slot 1 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000015L6.
> > > >> Sending label command for Volume "000018L6" Slot 2 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000018L6.
> > > >> Sending label command for Volume "000021L6" Slot 3 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000021L6.
> > > >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> > > >> Sending label command for Volume "000014L6" Slot 5 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000014L6.
> > > >> Sending label command for Volume "000017L6" Slot 6 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000017L6.
> > > >> Sending label command for Volume "000020L6" Slot 7 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000020L6.
> > > >> Media record for Slot 8 Volume "CLN005L3" already exists.
> > > >> Sending label command for Volume "000013L6" Slot 9 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000013L6.
> > > >> Sending label command for Volume "000016L6" Slot 10 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000016L6.
> > > >> Sending label command for Volume "000019L6" Slot 11 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000019L6.
> > > >> Sending label command for Volume "000012L6" Slot 12 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000012L6.
> > > >> Sending label command for Volume "000009L6" Slot 13 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000009L6.
> > > >> Sending label command for Volume "000006L6" Slot 14 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000006L6.
> > > >> Sending label command for Volume "000003L6" Slot 15 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000003L6.
> > > >> Sending label command for Volume "000011L6" Slot 16 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000011L6.
> > > >> Sending label command for Volume "000008L6" Slot 17 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000008L6.
> > > >> Sending label command for Volume "000005L6" Slot 18 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000005L6.
> > > >> Sending label command for Volume "000002L6" Slot 19 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000002L6.
> > > >> Sending label command for Volume "000010L6" Slot 20 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000010L6.
> > > >> Sending label command for Volume "000007L6" Slot 21 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000007L6.
> > > >> Sending label command for Volume "000004L6" Slot 22 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000004L6.
> > > >> Sending label command for Volume "000001L6" Slot 23 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000001L6.
> > > >> You have messages.
> > > >> *
> > > >>
> > > >> From the bacula-sd.conf on odin (where the library is):
> > > >> Autochanger {
> > > >>   Name = AutochangerOdin
> > > >>   Device = Drive-1
> > > >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > > >>   Changer Device = /dev/autochanger1
> > > >> }
> > > >>
> > > >> Device {
> > > >>   Name = Drive-1                      #
> > > >>   Description = "LT06 inside Dell TL2000 Library"
> > > >>   Drive Index = 0
> > > >>   Media Type = LT06
> > > >>   Archive Device = /dev/nst0
> > > >>   AutomaticMount = yes;               # when device opened, read it
> > > >>   AlwaysOpen = yes;
> > > >>   RemovableMedia = yes;
> > > >>   RandomAccess = no;
> > > >>   AutoChanger = yes
> > > >>   SpoolDirectory = "/var/spool/bacula"
> > > >>   MaximumSpoolSize = 485G
> > > >>   Maximum Network Buffer Size = 65536
> > > >>   Offline On Unmount = no
> > > >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > >> }
> > > >>
> > > >> From bacula-dir.conf on sleipnir (where the director is):
> > > >> Storage {
> > > >>   Name = Library2
> > > >> # Do not use "localhost" here
> > > >>   Address = odin                # N.B. Use a fully qualified name here
> > > >>   SDPort = 9103
> > > >>   Password = "*****************"
> > > >>   Device = AutochangerOdin
> > > >>   Media Type = LTO6
> > > >>   Autochanger = yes                   # enable for autochanger device
> > > >> }
> > > >>
> > > >> From the /dev directory on odin:
> > > >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> > > >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> > > >>
> > > >>
> > > >>
> > > >> --
> > > >> Steve Garcia
> > > >> Ignorance killed the cat, curiosity was framed.
> > > >>
> > > >> ------------------------------------------------------------
> > > >> ------------------
> > > >> Check out the vibrant tech community on one of the world's most
> > > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > >> _______________________________________________
> > > >> Bacula-users mailing list
> > > >> [hidden email]
> > > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >>
> > > >
> > > >
> > > > ------------------------------------------------------------
> > > > ------------------
> > > > Check out the vibrant tech community on one of the world's most
> > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > > _______________________________________________
> > > > Bacula-users mailing list
> > > > [hidden email]
> > > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >
> > > >
> >
> >


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Steve Garcia
In reply to this post by Ana Emília M. Arruda

OK, now we may be getting somewhere -- at least I have a dump of messages...

It does look like the problem is with the tape drive, but that's after it working fine at first.  It successfully opens the drive and determines (correctly) that the volume in the drive is an unlabeled tape.  As a result?  the tape drive is opened in a read-only state -- or maybe that's because it start by trying to read the existing label and you only need read-only for that.

# sudo -u bacula -g tape /usr/sbin/bacula-sd -d200
bacula-sd: address_conf.c:274-0 Initaddr 0.0.0.0:9103
bacula-sd: stored_conf.c:698-0 Inserting Director res: sleipnir-mon
root@odin:/etc/bacula# odin-sd: bsys.c:726-0 Could not open state file. sfd=-1 size=192: ERR=No such file or directory
odin-sd: stored.c:572-0 calling init_dev /dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: dev.c:342-0 init_dev: tape=1 dev_name=/dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: stored.c:574-0 SD init done /dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe350002170
odin-sd: bnet_server.c:86-0 Addresses 136.168.201.110:9103
odin-sd: acquire.c:673-0 Attach 0x50001c68 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0
odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: stored.c:588-0 calling first_open_device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: device.c:279-0 start open_output_device()
odin-sd: device.c:298-0 Opening device.
odin-sd: tape_dev.c:958-0 Enter tape mount
odin-sd: tape_dev.c:84-0 Open dev: device is tape
odin-sd: autochanger.c:260-0 Return cached slot=1
odin-sd: tape_dev.c:99-0 Try open "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) mode=OPEN_READ_ONLY
odin-sd: tape_dev.c:121-0 Rewind after open
odin-sd: os.c:58-0 In set_os_device_parameters
odin-sd: os.c:64-0 Set block size to zero
odin-sd: tape_dev.c:176-0 open dev: tape 5 opened
odin-sd: dev.c:391-0 preserve=0x0 fd=5
odin-sd: dev.c:394-0 open dev: fd=5 dev=7fe350001476 dcr=7fe350001098 vol= type=2 dev_name="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) mode=OPEN_READ_ONLY
odin-sd: device.c:304-0 open dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) OK
odin-sd: label.c:72-0 Enter: int read_dev_volume_label(DCR*)
odin-sd: label.c:75-0 Enter read_volume_label res=0 device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) vol= dev_Vol=*NULL*
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: label.c:126-0 Big if statement in read_volume_label
odin-sd: block.c:458-0 Read() vol= nbytes=0 addr=-1
odin-sd: block.c:487-0 block.c:480 The Volume= on device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
odin-sd: block.c:493-0 ==== Read zero bytes. vol= at -1
odin-sd: label.c:131-0 Requested Volume "" on tape device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) is not a Bacula labeled Volume, because: ERR=block.c:480 The Volume= on device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
odin-sd: label.c:160-0 No volume label - bailing out
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: label.c:251-0 return 3
odin-sd: label.c:252-0 Leave: int read_dev_volume_label(DCR*)
odin-sd: stored.c:613-0 Could not mount device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:24
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1587823263.1501531104@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <839623232.1501531104@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: P7tmG2+KsR/8M7YfplspnD
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: autochanger slots AutochangerOdin

odin-sd: dircmd.c:225-0 Do command: autochanger
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:837-0 Found changer device Drive-1
odin-sd: dircmd.c:850-0 Found device Drive-1
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350012830 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe350012830
odin-sd: acquire.c:673-0 Attach 0x50012f38 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:670-0 <stored: slots=24
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:25
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1792316614.1501531105@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <1290223807.1501531105@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: u+RSe94jz4UptzNhM8+toC
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: autochanger list AutochangerOdin

odin-sd: dircmd.c:225-0 Do command: autochanger
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:837-0 Found changer device Drive-1
odin-sd: dircmd.c:850-0 Found device Drive-1
odin-sd: block_util.c:206-0 empty len=64512 block=7fe348001500 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe348001500
odin-sd: acquire.c:673-0 Attach 0x48000ff8 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0
odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:657-0 <stored: 2:000018L6

odin-sd: autochanger.c:657-0 <stored: 3:000021L6

odin-sd: autochanger.c:657-0 <stored: 4:CLNU00L1

odin-sd: autochanger.c:657-0 <stored: 5:000014L6

odin-sd: autochanger.c:657-0 <stored: 6:000017L6

odin-sd: autochanger.c:657-0 <stored: 7:000020L6

odin-sd: autochanger.c:657-0 <stored: 8:CLN005L3

odin-sd: autochanger.c:657-0 <stored: 9:000013L6

odin-sd: autochanger.c:657-0 <stored: 10:000016L6

odin-sd: autochanger.c:657-0 <stored: 11:000019L6

odin-sd: autochanger.c:657-0 <stored: 12:000012L6

odin-sd: autochanger.c:657-0 <stored: 13:000009L6

odin-sd: autochanger.c:657-0 <stored: 14:000006L6

odin-sd: autochanger.c:657-0 <stored: 15:000003L6

odin-sd: autochanger.c:657-0 <stored: 16:000011L6

odin-sd: autochanger.c:657-0 <stored: 17:000008L6

odin-sd: autochanger.c:657-0 <stored: 18:000005L6

odin-sd: autochanger.c:657-0 <stored: 19:000002L6

odin-sd: autochanger.c:657-0 <stored: 20:000010L6

odin-sd: autochanger.c:657-0 <stored: 21:000007L6

odin-sd: autochanger.c:657-0 <stored: 22:000004L6

odin-sd: autochanger.c:657-0 <stored: 23:000001L6

odin-sd: autochanger.c:657-0 <stored: 1:000015L6


odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:35
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1434613563.1501531115@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <734308377.1501531115@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: GA/q4g/uIH/DvkJfC/+UwA
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000015L6 PoolName=OdinPool MediaType=LTO6 Slot=1 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000018L6 PoolName=OdinPool MediaType=LTO6 Slot=2 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000021L6 PoolName=OdinPool MediaType=LTO6 Slot=3 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000014L6 PoolName=OdinPool MediaType=LTO6 Slot=5 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000017L6 PoolName=OdinPool MediaType=LTO6 Slot=6 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000020L6 PoolName=OdinPool MediaType=LTO6 Slot=7 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000013L6 PoolName=OdinPool MediaType=LTO6 Slot=9 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000016L6 PoolName=OdinPool MediaType=LTO6 Slot=10 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000019L6 PoolName=OdinPool MediaType=LTO6 Slot=11 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000012L6 PoolName=OdinPool MediaType=LTO6 Slot=12 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000009L6 PoolName=OdinPool MediaType=LTO6 Slot=13 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000006L6 PoolName=OdinPool MediaType=LTO6 Slot=14 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000003L6 PoolName=OdinPool MediaType=LTO6 Slot=15 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000011L6 PoolName=OdinPool MediaType=LTO6 Slot=16 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000008L6 PoolName=OdinPool MediaType=LTO6 Slot=17 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000005L6 PoolName=OdinPool MediaType=LTO6 Slot=18 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000002L6 PoolName=OdinPool MediaType=LTO6 Slot=19 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000010L6 PoolName=OdinPool MediaType=LTO6 Slot=20 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000007L6 PoolName=OdinPool MediaType=LTO6 Slot=21 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000004L6 PoolName=OdinPool MediaType=LTO6 Slot=22 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000001L6 PoolName=OdinPool MediaType=LTO6 Slot=23 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping



Steve Garcia
Ignorance killed the cat, curiosity was framed.

---- "Ana Emília M. Arruda" <[hidden email]> wrote:

> Hello Steve,
>
> Sorry, I sent an incomplete message.
>
> I think we will need to speak the same language here :-)
>
> You have your Director running at sleipnir host:
>
> root@sleipnir:/etc/bacula# bconsole
> Connecting to Director sleipnir:9101
> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
>
> with the Autochanger configuration on Director:
>
> From bacula-dir.conf on sleipnir (where the director is):
> Storage {
>   Name = Library2
> # Do not use "localhost" here
>   Address = odin                # N.B. Use a fully qualified name here
>   SDPort = 9103
>   Password = "*****************"
>   Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device
> }
>
> And you have your remote Storage Daemon installed in a host called
> odin with the following configuration:
>
> From the bacula-sd.conf on odin (where the library is):
> Autochanger {
>   Name = AutochangerOdin
>   Device = Drive-1
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/autochanger1
> }
>
> Device {
>   Name = Drive-1                      #
>   Description = "LT06 inside Dell TL2000 Library"
>   Drive Index = 0
>   Media Type = LT06
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>   SpoolDirectory = "/var/spool/bacula"
>   MaximumSpoolSize = 485G
>   Maximum Network Buffer Size = 65536
>   Offline On Unmount = no
>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> }
> This is perfect.
>
> You are right, the permission needs to be checked.
>
> If you have bacula-sd runnig as bacula user, the bacula user must be member
> of tape group.
>
> Also, you can start the bacula-sd daemon in debug mode to get some debug
> output and maybe help in this case. The following command should be run on
> odin host:
>
> * sudo -u bacula -g tape /opt/ bacula/bin/bacula-sd -d200
>
> This will produce debug information on the Storage Daemon host and maybe we
> can have more information about this problem.
>
> Best,
> Ana
>
> On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]> wrote:
>
> >
> >
> > ---- Darold Lucus <[hidden email]> wrote:
> > > This is an example of my Autochanger listing in the bacula-sd.conf, this
> > is
> > > only a partial list but you would follow that format. My autochanger has
> > 16
> > > slots and a drive, the drive-1 is the writing drive.
> > >
> > > AutoChanger {
> > >   Name = AutoChanger
> > >   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6,
> > Drive-7,
> > > Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> > > Drive-15, Drive-16, Drive-17
> > >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > >   Changer Device = /dev/sg1
> > > }
> >
> > So you're defining each slot as a drive, but only defining the actual
> > drive as a device?
> >
> > >
> > > Device {
> > >   Name = Drive-1                      #
> > >   Drive Index = 0
> > >   Media Type = LTO5
> > >   Archive Device = /dev/st0
> > >   AutomaticMount = yes;               # when device opened, read it
> > >   AlwaysOpen = yes;
> > >   RemovableMedia = yes;
> > >   RandomAccess = no;
> > >   AutoChanger = yes
> > >
> > > }
> > >
> > > You also don't need this information in your storage section:
> > >
> > > Device = AutochangerOdin
> > >   Media Type = LTO6
> > >   Autochanger = yes                   # enable for autochanger device
> >
> > Well, I don't have those defined in the Storage resource of the
> > bacula-sd.conf configuration (which is on the remote machine where the
> > storage daemon lives) but I *do* have it in the Storage resource which is
> > part of the bacula-dir.conf configuration.  The director gets quite cranky
> > if you leave it out there.  :-)
> >
> >
> >
> >
> > >
> > > This is my example:
> > >
> > > Storage {                             # definition of myself
> > >   Name = nas-sd
> > >   SDPort = 9103                  # Director's port
> > >   WorkingDirectory = "/var/lib/bacula"
> > >   Pid Directory = "/var/run/bacula"
> > >   Maximum Concurrent Jobs = 20
> > >   SDAddress = IP.ADD.RE.SS
> > > }
> > >
> > >
> > > Hope this helps.
> > >
> > >
> > >
> > >
> > > Sincerely,
> > >
> > > Darold Lucus
> > >
> > >
> > > [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
> > >
> > > =====================
> > > LAN Administrator
> > > EMAC, Inc
> > > 618-529-4525 EXT:370
> > > www.emacinc.com
> > > =====================
> > >
> > >
> > >
> > > This message is confidential. It may also be privileged or otherwise
> > > protected by work product immunity or other legal rules. If you have
> > > received it by mistake, please let us know by e-mail reply and delete it
> > > from your system; you may not copy this message or disclose its contents
> > to
> > > anyone.
> > >
> > > On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> > > [hidden email]> wrote:
> > >
> > > > Hi Steve,
> > > >
> > > > Sorry, my mistake...
> > > >
> > > > There is no problem in having a remote Storage Daemon with your tape
> > > > library attached. This is a very usual configuration.
> > > >
> > > > Before having a try with Bacula, I would recommend you to check if mtx
> > and
> > > > mt are properly working (please use /dev/tape/by-id names when running
> > > > tests).
> > > >
> > > > The error messages seems related to the tape drive and not to the tape
> > > > library configuration. So I would try "/dev/tape/by-id/scsi-
> > 35000e11164c42001-nst"
> > > > for the tape device:
> > > >
> > > > Device {
> > > >   Name = Drive-1                      #
> > > >   Description = "LT06 inside Dell TL2000 Library"
> > > >   Drive Index = 0
> > > >   Media Type = LT06
> > > >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> > > >   AutomaticMount = yes;               # when device opened, read it
> > > >   AlwaysOpen = yes;
> > > >   RemovableMedia = yes;
> > > >   RandomAccess = no;
> > > >   AutoChanger = yes
> > > >   SpoolDirectory = "/var/spool/bacula"
> > > >   MaximumSpoolSize = 485G
> > > >   Maximum Network Buffer Size = 65536
> > > >   Offline On Unmount = no
> > > >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > > }
> > > >
> > > > You should run btape tests before starting backups as well.
> > > >
> > > > Best regards,
> > > >
> > > > Ana
> > > >
> > > >
> > > > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]>
> > wrote:
> > > >
> > > >> OK, I've got my tape drive working (thanks Ana!) but I'm having
> > trouble
> > > >> connecting to the autochanger it's in using the director.  This is the
> > > >> first time I've tried having a storage daemon on a different machine
> > than
> > > >> the director.  The director is a slightly lower version (7.4.3 on
> > Debian
> > > >> Jessie using backports) than the storage daemon (7.4.4 on stretch)
> > but I
> > > >> had understood that those versions were close enough to work.
> > > >>
> > > >> So I'm hoping this is another configuration issue.
> > > >>
> > > >> Right now what I'm trying to do is label all the tapes in the new
> > library.
> > > >>
> > > >> When I try to access the new storage from the director, it is able to
> > get
> > > >> a listing of all the tapes, but it fails when it tries to actually do
> > the
> > > >> labeling.  I get a "3999 Device not found or could not be opened"
> > error.
> > > >> These errors show up quickly, there is no delay as it tries each
> > slot, so
> > > >> it's obviously not getting far enough to try.  But it *is* obviously
> > > >> connecting to the remote storage, otherwise it wouldn't be able to
> > obtain
> > > >> the slot list.
> > > >>
> > > >> What am I missing?
> > > >>
> > > >> root@sleipnir:/etc/bacula# bconsole
> > > >> Connecting to Director sleipnir:9101
> > > >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> > > >> Enter a period to cancel a command.
> > > >> *label storage=Library2 barcodes
> > > >> Automatically selected Catalog: MyCatalog
> > > >> Using Catalog "MyCatalog"
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "slots" command.
> > > >> Device "AutochangerOdin" has 24 slots.
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "list" command.
> > > >> The following Volumes will be labeled:
> > > >> Slot  Volume
> > > >> ==============
> > > >>    1  000015L6
> > > >>    2  000018L6
> > > >>    3  000021L6
> > > >>    4  CLNU00L1
> > > >>    5  000014L6
> > > >>    6  000017L6
> > > >>    7  000020L6
> > > >>    8  CLN005L3
> > > >>    9  000013L6
> > > >>   10  000016L6
> > > >>   11  000019L6
> > > >>   12  000012L6
> > > >>   13  000009L6
> > > >>   14  000006L6
> > > >>   15  000003L6
> > > >>   16  000011L6
> > > >>   17  000008L6
> > > >>   18  000005L6
> > > >>   19  000002L6
> > > >>   20  000010L6
> > > >>   21  000007L6
> > > >>   22  000004L6
> > > >>   23  000001L6
> > > >> Do you want to label these Volumes? (yes|no):  yes
> > > >> Defined Pools:
> > > >>      1: Default
> > > >>      2: OdinPool
> > > >> Select the Pool (1-2): 2
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> Sending label command for Volume "000015L6" Slot 1 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000015L6.
> > > >> Sending label command for Volume "000018L6" Slot 2 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000018L6.
> > > >> Sending label command for Volume "000021L6" Slot 3 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000021L6.
> > > >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> > > >> Sending label command for Volume "000014L6" Slot 5 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000014L6.
> > > >> Sending label command for Volume "000017L6" Slot 6 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000017L6.
> > > >> Sending label command for Volume "000020L6" Slot 7 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000020L6.
> > > >> Media record for Slot 8 Volume "CLN005L3" already exists.
> > > >> Sending label command for Volume "000013L6" Slot 9 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000013L6.
> > > >> Sending label command for Volume "000016L6" Slot 10 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000016L6.
> > > >> Sending label command for Volume "000019L6" Slot 11 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000019L6.
> > > >> Sending label command for Volume "000012L6" Slot 12 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000012L6.
> > > >> Sending label command for Volume "000009L6" Slot 13 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000009L6.
> > > >> Sending label command for Volume "000006L6" Slot 14 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000006L6.
> > > >> Sending label command for Volume "000003L6" Slot 15 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000003L6.
> > > >> Sending label command for Volume "000011L6" Slot 16 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000011L6.
> > > >> Sending label command for Volume "000008L6" Slot 17 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000008L6.
> > > >> Sending label command for Volume "000005L6" Slot 18 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000005L6.
> > > >> Sending label command for Volume "000002L6" Slot 19 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000002L6.
> > > >> Sending label command for Volume "000010L6" Slot 20 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000010L6.
> > > >> Sending label command for Volume "000007L6" Slot 21 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000007L6.
> > > >> Sending label command for Volume "000004L6" Slot 22 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000004L6.
> > > >> Sending label command for Volume "000001L6" Slot 23 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000001L6.
> > > >> You have messages.
> > > >> *
> > > >>
> > > >> From the bacula-sd.conf on odin (where the library is):
> > > >> Autochanger {
> > > >>   Name = AutochangerOdin
> > > >>   Device = Drive-1
> > > >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > > >>   Changer Device = /dev/autochanger1
> > > >> }
> > > >>
> > > >> Device {
> > > >>   Name = Drive-1                      #
> > > >>   Description = "LT06 inside Dell TL2000 Library"
> > > >>   Drive Index = 0
> > > >>   Media Type = LT06
> > > >>   Archive Device = /dev/nst0
> > > >>   AutomaticMount = yes;               # when device opened, read it
> > > >>   AlwaysOpen = yes;
> > > >>   RemovableMedia = yes;
> > > >>   RandomAccess = no;
> > > >>   AutoChanger = yes
> > > >>   SpoolDirectory = "/var/spool/bacula"
> > > >>   MaximumSpoolSize = 485G
> > > >>   Maximum Network Buffer Size = 65536
> > > >>   Offline On Unmount = no
> > > >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > >> }
> > > >>
> > > >> From bacula-dir.conf on sleipnir (where the director is):
> > > >> Storage {
> > > >>   Name = Library2
> > > >> # Do not use "localhost" here
> > > >>   Address = odin                # N.B. Use a fully qualified name here
> > > >>   SDPort = 9103
> > > >>   Password = "*****************"
> > > >>   Device = AutochangerOdin
> > > >>   Media Type = LTO6
> > > >>   Autochanger = yes                   # enable for autochanger device
> > > >> }
> > > >>
> > > >> From the /dev directory on odin:
> > > >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> > > >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> > > >>
> > > >>
> > > >>
> > > >> --
> > > >> Steve Garcia
> > > >> Ignorance killed the cat, curiosity was framed.
> > > >>
> > > >> ------------------------------------------------------------
> > > >> ------------------
> > > >> Check out the vibrant tech community on one of the world's most
> > > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > >> _______________________________________________
> > > >> Bacula-users mailing list
> > > >> [hidden email]
> > > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >>
> > > >
> > > >
> > > > ------------------------------------------------------------
> > > > ------------------
> > > > Check out the vibrant tech community on one of the world's most
> > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > > _______________________________________________
> > > > Bacula-users mailing list
> > > > [hidden email]
> > > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >
> > > >
> >
> >


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Phil Stracchino-2
The message that this is a reply to arrived here trashed, with all Ana's
reply text missing.  So I'm answering here with my questions.


On 07/31/17 16:22, Steve Garcia wrote:

> ---- "Ana Emília M. Arruda" <[hidden email]> wrote:
>>
>> You have your Director running at sleipnir host:
>>
>> root@sleipnir:/etc/bacula# bconsole
>> Connecting to Director sleipnir:9101
>> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
>>
>> with the Autochanger configuration on Director:
>>
>> From bacula-dir.conf on sleipnir (where the director is):
>> Storage {
>>   Name = Library2
>> # Do not use "localhost" here
>>   Address = odin                # N.B. Use a fully qualified name here
>>   SDPort = 9103
>>   Password = "*****************"
>>   Device = AutochangerOdin
>>   Media Type = LTO6
>>   Autochanger = yes                   # enable for autochanger device
>> }
>>
>> And you have your remote Storage Daemon installed in a host called
>> odin with the following configuration:
>>
>> From the bacula-sd.conf on odin (where the library is):
>> Autochanger {
>>   Name = AutochangerOdin
>>   Device = Drive-1
>>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>>   Changer Device = /dev/autochanger1
>> }
>>
>> Device {
>>   Name = Drive-1                      #
>>   Description = "LT06 inside Dell TL2000 Library"
>>   Drive Index = 0
>>   Media Type = LT06
>>   Archive Device = /dev/nst0
>>   AutomaticMount = yes;               # when device opened, read it
>>   AlwaysOpen = yes;
>>   RemovableMedia = yes;
>>   RandomAccess = no;
>>   AutoChanger = yes
>>   SpoolDirectory = "/var/spool/bacula"
>>   MaximumSpoolSize = 485G
>>   Maximum Network Buffer Size = 65536
>>   Offline On Unmount = no
>>   Alert Command = "sh -c 'smartctl -H -l error %c'"
>> }
>> This is perfect.


So with the pretend-single-drive-is-an-autochanger hack, I'm supposed to
give the *DIRECTOR* a Storage resource pointed to the "autochanger", and
I give the *STORAGE daemon* an Autochanger resource pointing to its
standalone drive as a Device?

If so, then I currently have it configured wrong.


--
  Phil Stracchino
  Babylon Communications
  [hidden email]
  [hidden email]
  Landline: +1.603.293.8485
  Mobile:   +1.603.998.6958

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Phil Stracchino-2
On 07/31/17 17:30, Phil Stracchino wrote:
>
> So with the pretend-single-drive-is-an-autochanger hack, I'm supposed to
> give the *DIRECTOR* a Storage resource pointed to the "autochanger", and
> I give the *STORAGE daemon* an Autochanger resource pointing to its
> standalone drive as a Device?


Oops.  Premature send.

I meant to also ask:
If I'm only PRETENDING to have an autochanger, what do I use as the
changer command and changer device?


--
  Phil Stracchino
  Babylon Communications
  [hidden email]
  [hidden email]
  Landline: +1.603.293.8485
  Mobile:   +1.603.998.6958

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
In reply to this post by Steve Garcia
Hello Steve,

Yes, it looks we have something here.

From one of your previous emails, we have the error "3999 Device "AutochangerOdin" not found or could not be opened." when Bacula issues the label command for the tapes.

This "not found or could not be opened" message usually refers to the wrong "device name" configured for an "Archive Device" or "Changer Device".

From another post, you have only one tape library with one tape drive, but two paths for each of them:



On Mon, Jul 31, 2017 at 5:22 PM, Steve Garcia <[hidden email]> wrote:

OK, now we may be getting somewhere -- at least I have a dump of messages...

It does look like the problem is with the tape drive, but that's after it working fine at first.  It successfully opens the drive and determines (correctly) that the volume in the drive is an unlabeled tape.  As a result?  the tape drive is opened in a read-only state -- or maybe that's because it start by trying to read the existing label and you only need read-only for that.

# sudo -u bacula -g tape /usr/sbin/bacula-sd -d200
bacula-sd: address_conf.c:274-0 Initaddr 0.0.0.0:9103
bacula-sd: stored_conf.c:698-0 Inserting Director res: sleipnir-mon
root@odin:/etc/bacula# odin-sd: bsys.c:726-0 Could not open state file. sfd=-1 size=192: ERR=No such file or directory
odin-sd: stored.c:572-0 calling init_dev /dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: dev.c:342-0 init_dev: tape=1 dev_name=/dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: stored.c:574-0 SD init done /dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe350002170
odin-sd: bnet_server.c:86-0 Addresses 136.168.201.110:9103
odin-sd: acquire.c:673-0 Attach 0x50001c68 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0
odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: stored.c:588-0 calling first_open_device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: device.c:279-0 start open_output_device()
odin-sd: device.c:298-0 Opening device.
odin-sd: tape_dev.c:958-0 Enter tape mount
odin-sd: tape_dev.c:84-0 Open dev: device is tape
odin-sd: autochanger.c:260-0 Return cached slot=1
odin-sd: tape_dev.c:99-0 Try open "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) mode=OPEN_READ_ONLY
odin-sd: tape_dev.c:121-0 Rewind after open
odin-sd: os.c:58-0 In set_os_device_parameters
odin-sd: os.c:64-0 Set block size to zero
odin-sd: tape_dev.c:176-0 open dev: tape 5 opened
odin-sd: dev.c:391-0 preserve=0x0 fd=5
odin-sd: dev.c:394-0 open dev: fd=5 dev=7fe350001476 dcr=7fe350001098 vol= type=2 dev_name="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) mode=OPEN_READ_ONLY
odin-sd: device.c:304-0 open dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) OK
odin-sd: label.c:72-0 Enter: int read_dev_volume_label(DCR*)
odin-sd: label.c:75-0 Enter read_volume_label res=0 device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) vol= dev_Vol=*NULL*
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: label.c:126-0 Big if statement in read_volume_label
odin-sd: block.c:458-0 Read() vol= nbytes=0 addr=-1
odin-sd: block.c:487-0 block.c:480 The Volume= on device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
odin-sd: block.c:493-0 ==== Read zero bytes. vol= at -1
odin-sd: label.c:131-0 Requested Volume "" on tape device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) is not a Bacula labeled Volume, because: ERR=block.c:480 The Volume= on device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
odin-sd: label.c:160-0 No volume label - bailing out
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: label.c:251-0 return 3
odin-sd: label.c:252-0 Leave: int read_dev_volume_label(DCR*)
odin-sd: stored.c:613-0 Could not mount device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:24
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1587823263.1501531104@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <839623232.1501531104@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: P7tmG2+KsR/8M7YfplspnD
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: autochanger slots AutochangerOdin

odin-sd: dircmd.c:225-0 Do command: autochanger
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:837-0 Found changer device Drive-1
odin-sd: dircmd.c:850-0 Found device Drive-1
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350012830 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe350012830
odin-sd: acquire.c:673-0 Attach 0x50012f38 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:670-0 <stored: slots=24
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:25
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1792316614.1501531105@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <1290223807.1501531105@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: u+RSe94jz4UptzNhM8+toC
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: autochanger list AutochangerOdin

odin-sd: dircmd.c:225-0 Do command: autochanger
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:837-0 Found changer device Drive-1
odin-sd: dircmd.c:850-0 Found device Drive-1
odin-sd: block_util.c:206-0 empty len=64512 block=7fe348001500 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe348001500
odin-sd: acquire.c:673-0 Attach 0x48000ff8 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0
odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:657-0 <stored: 2:000018L6

odin-sd: autochanger.c:657-0 <stored: 3:000021L6

odin-sd: autochanger.c:657-0 <stored: 4:CLNU00L1

odin-sd: autochanger.c:657-0 <stored: 5:000014L6

odin-sd: autochanger.c:657-0 <stored: 6:000017L6

odin-sd: autochanger.c:657-0 <stored: 7:000020L6

odin-sd: autochanger.c:657-0 <stored: 8:CLN005L3

odin-sd: autochanger.c:657-0 <stored: 9:000013L6

odin-sd: autochanger.c:657-0 <stored: 10:000016L6

odin-sd: autochanger.c:657-0 <stored: 11:000019L6

odin-sd: autochanger.c:657-0 <stored: 12:000012L6

odin-sd: autochanger.c:657-0 <stored: 13:000009L6

odin-sd: autochanger.c:657-0 <stored: 14:000006L6

odin-sd: autochanger.c:657-0 <stored: 15:000003L6

odin-sd: autochanger.c:657-0 <stored: 16:000011L6

odin-sd: autochanger.c:657-0 <stored: 17:000008L6

odin-sd: autochanger.c:657-0 <stored: 18:000005L6

odin-sd: autochanger.c:657-0 <stored: 19:000002L6

odin-sd: autochanger.c:657-0 <stored: 20:000010L6

odin-sd: autochanger.c:657-0 <stored: 21:000007L6

odin-sd: autochanger.c:657-0 <stored: 22:000004L6

odin-sd: autochanger.c:657-0 <stored: 23:000001L6

odin-sd: autochanger.c:657-0 <stored: 1:000015L6


odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:35
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1434613563.1501531115@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <734308377.1501531115@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: GA/q4g/uIH/DvkJfC/+UwA
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000015L6 PoolName=OdinPool MediaType=LTO6 Slot=1 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000018L6 PoolName=OdinPool MediaType=LTO6 Slot=2 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000021L6 PoolName=OdinPool MediaType=LTO6 Slot=3 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000014L6 PoolName=OdinPool MediaType=LTO6 Slot=5 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000017L6 PoolName=OdinPool MediaType=LTO6 Slot=6 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000020L6 PoolName=OdinPool MediaType=LTO6 Slot=7 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000013L6 PoolName=OdinPool MediaType=LTO6 Slot=9 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000016L6 PoolName=OdinPool MediaType=LTO6 Slot=10 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000019L6 PoolName=OdinPool MediaType=LTO6 Slot=11 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000012L6 PoolName=OdinPool MediaType=LTO6 Slot=12 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000009L6 PoolName=OdinPool MediaType=LTO6 Slot=13 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000006L6 PoolName=OdinPool MediaType=LTO6 Slot=14 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000003L6 PoolName=OdinPool MediaType=LTO6 Slot=15 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000011L6 PoolName=OdinPool MediaType=LTO6 Slot=16 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000008L6 PoolName=OdinPool MediaType=LTO6 Slot=17 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000005L6 PoolName=OdinPool MediaType=LTO6 Slot=18 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000002L6 PoolName=OdinPool MediaType=LTO6 Slot=19 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000010L6 PoolName=OdinPool MediaType=LTO6 Slot=20 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000007L6 PoolName=OdinPool MediaType=LTO6 Slot=21 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000004L6 PoolName=OdinPool MediaType=LTO6 Slot=22 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000001L6 PoolName=OdinPool MediaType=LTO6 Slot=23 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping



Steve Garcia
Ignorance killed the cat, curiosity was framed.

---- "Ana Emília M. Arruda" <[hidden email]> wrote:
> Hello Steve,
>
> Sorry, I sent an incomplete message.
>
> I think we will need to speak the same language here :-)
>
> You have your Director running at sleipnir host:
>
> root@sleipnir:/etc/bacula# bconsole
> Connecting to Director sleipnir:9101
> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
>
> with the Autochanger configuration on Director:
>
> From bacula-dir.conf on sleipnir (where the director is):
> Storage {
>   Name = Library2
> # Do not use "localhost" here
>   Address = odin                # N.B. Use a fully qualified name here
>   SDPort = 9103
>   Password = "*****************"
>   Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device
> }
>
> And you have your remote Storage Daemon installed in a host called
> odin with the following configuration:
>
> From the bacula-sd.conf on odin (where the library is):
> Autochanger {
>   Name = AutochangerOdin
>   Device = Drive-1
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/autochanger1
> }
>
> Device {
>   Name = Drive-1                      #
>   Description = "LT06 inside Dell TL2000 Library"
>   Drive Index = 0
>   Media Type = LT06
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>   SpoolDirectory = "/var/spool/bacula"
>   MaximumSpoolSize = 485G
>   Maximum Network Buffer Size = 65536
>   Offline On Unmount = no
>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> }
> This is perfect.
>
> You are right, the permission needs to be checked.
>
> If you have bacula-sd runnig as bacula user, the bacula user must be member
> of tape group.
>
> Also, you can start the bacula-sd daemon in debug mode to get some debug
> output and maybe help in this case. The following command should be run on
> odin host:
>
> * sudo -u bacula -g tape /opt/ bacula/bin/bacula-sd -d200
>
> This will produce debug information on the Storage Daemon host and maybe we
> can have more information about this problem.
>
> Best,
> Ana
>
> On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]> wrote:
>
> >
> >
> > ---- Darold Lucus <[hidden email]> wrote:
> > > This is an example of my Autochanger listing in the bacula-sd.conf, this
> > is
> > > only a partial list but you would follow that format. My autochanger has
> > 16
> > > slots and a drive, the drive-1 is the writing drive.
> > >
> > > AutoChanger {
> > >   Name = AutoChanger
> > >   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6,
> > Drive-7,
> > > Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> > > Drive-15, Drive-16, Drive-17
> > >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > >   Changer Device = /dev/sg1
> > > }
> >
> > So you're defining each slot as a drive, but only defining the actual
> > drive as a device?
> >
> > >
> > > Device {
> > >   Name = Drive-1                      #
> > >   Drive Index = 0
> > >   Media Type = LTO5
> > >   Archive Device = /dev/st0
> > >   AutomaticMount = yes;               # when device opened, read it
> > >   AlwaysOpen = yes;
> > >   RemovableMedia = yes;
> > >   RandomAccess = no;
> > >   AutoChanger = yes
> > >
> > > }
> > >
> > > You also don't need this information in your storage section:
> > >
> > > Device = AutochangerOdin
> > >   Media Type = LTO6
> > >   Autochanger = yes                   # enable for autochanger device
> >
> > Well, I don't have those defined in the Storage resource of the
> > bacula-sd.conf configuration (which is on the remote machine where the
> > storage daemon lives) but I *do* have it in the Storage resource which is
> > part of the bacula-dir.conf configuration.  The director gets quite cranky
> > if you leave it out there.  :-)
> >
> >
> >
> >
> > >
> > > This is my example:
> > >
> > > Storage {                             # definition of myself
> > >   Name = nas-sd
> > >   SDPort = 9103                  # Director's port
> > >   WorkingDirectory = "/var/lib/bacula"
> > >   Pid Directory = "/var/run/bacula"
> > >   Maximum Concurrent Jobs = 20
> > >   SDAddress = IP.ADD.RE.SS
> > > }
> > >
> > >
> > > Hope this helps.
> > >
> > >
> > >
> > >
> > > Sincerely,
> > >
> > > Darold Lucus
> > >
> > >
> > > [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
> > >
> > > =====================
> > > LAN Administrator
> > > EMAC, Inc
> > > <a href="tel:618-529-4525%20EXT%3A370" value="+16185294525">618-529-4525 EXT:370
> > > www.emacinc.com
> > > =====================
> > >
> > >
> > >
> > > This message is confidential. It may also be privileged or otherwise
> > > protected by work product immunity or other legal rules. If you have
> > > received it by mistake, please let us know by e-mail reply and delete it
> > > from your system; you may not copy this message or disclose its contents
> > to
> > > anyone.
> > >
> > > On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> > > [hidden email]> wrote:
> > >
> > > > Hi Steve,
> > > >
> > > > Sorry, my mistake...
> > > >
> > > > There is no problem in having a remote Storage Daemon with your tape
> > > > library attached. This is a very usual configuration.
> > > >
> > > > Before having a try with Bacula, I would recommend you to check if mtx
> > and
> > > > mt are properly working (please use /dev/tape/by-id names when running
> > > > tests).
> > > >
> > > > The error messages seems related to the tape drive and not to the tape
> > > > library configuration. So I would try "/dev/tape/by-id/scsi-
> > 35000e11164c42001-nst"
> > > > for the tape device:
> > > >
> > > > Device {
> > > >   Name = Drive-1                      #
> > > >   Description = "LT06 inside Dell TL2000 Library"
> > > >   Drive Index = 0
> > > >   Media Type = LT06
> > > >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> > > >   AutomaticMount = yes;               # when device opened, read it
> > > >   AlwaysOpen = yes;
> > > >   RemovableMedia = yes;
> > > >   RandomAccess = no;
> > > >   AutoChanger = yes
> > > >   SpoolDirectory = "/var/spool/bacula"
> > > >   MaximumSpoolSize = 485G
> > > >   Maximum Network Buffer Size = 65536
> > > >   Offline On Unmount = no
> > > >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > > }
> > > >
> > > > You should run btape tests before starting backups as well.
> > > >
> > > > Best regards,
> > > >
> > > > Ana
> > > >
> > > >
> > > > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]>
> > wrote:
> > > >
> > > >> OK, I've got my tape drive working (thanks Ana!) but I'm having
> > trouble
> > > >> connecting to the autochanger it's in using the director.  This is the
> > > >> first time I've tried having a storage daemon on a different machine
> > than
> > > >> the director.  The director is a slightly lower version (7.4.3 on
> > Debian
> > > >> Jessie using backports) than the storage daemon (7.4.4 on stretch)
> > but I
> > > >> had understood that those versions were close enough to work.
> > > >>
> > > >> So I'm hoping this is another configuration issue.
> > > >>
> > > >> Right now what I'm trying to do is label all the tapes in the new
> > library.
> > > >>
> > > >> When I try to access the new storage from the director, it is able to
> > get
> > > >> a listing of all the tapes, but it fails when it tries to actually do
> > the
> > > >> labeling.  I get a "3999 Device not found or could not be opened"
> > error.
> > > >> These errors show up quickly, there is no delay as it tries each
> > slot, so
> > > >> it's obviously not getting far enough to try.  But it *is* obviously
> > > >> connecting to the remote storage, otherwise it wouldn't be able to
> > obtain
> > > >> the slot list.
> > > >>
> > > >> What am I missing?
> > > >>
> > > >> root@sleipnir:/etc/bacula# bconsole
> > > >> Connecting to Director sleipnir:9101
> > > >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> > > >> Enter a period to cancel a command.
> > > >> *label storage=Library2 barcodes
> > > >> Automatically selected Catalog: MyCatalog
> > > >> Using Catalog "MyCatalog"
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "slots" command.
> > > >> Device "AutochangerOdin" has 24 slots.
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "list" command.
> > > >> The following Volumes will be labeled:
> > > >> Slot  Volume
> > > >> ==============
> > > >>    1  000015L6
> > > >>    2  000018L6
> > > >>    3  000021L6
> > > >>    4  CLNU00L1
> > > >>    5  000014L6
> > > >>    6  000017L6
> > > >>    7  000020L6
> > > >>    8  CLN005L3
> > > >>    9  000013L6
> > > >>   10  000016L6
> > > >>   11  000019L6
> > > >>   12  000012L6
> > > >>   13  000009L6
> > > >>   14  000006L6
> > > >>   15  000003L6
> > > >>   16  000011L6
> > > >>   17  000008L6
> > > >>   18  000005L6
> > > >>   19  000002L6
> > > >>   20  000010L6
> > > >>   21  000007L6
> > > >>   22  000004L6
> > > >>   23  000001L6
> > > >> Do you want to label these Volumes? (yes|no):  yes
> > > >> Defined Pools:
> > > >>      1: Default
> > > >>      2: OdinPool
> > > >> Select the Pool (1-2): 2
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> Sending label command for Volume "000015L6" Slot 1 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000015L6.
> > > >> Sending label command for Volume "000018L6" Slot 2 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000018L6.
> > > >> Sending label command for Volume "000021L6" Slot 3 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000021L6.
> > > >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> > > >> Sending label command for Volume "000014L6" Slot 5 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000014L6.
> > > >> Sending label command for Volume "000017L6" Slot 6 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000017L6.
> > > >> Sending label command for Volume "000020L6" Slot 7 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000020L6.
> > > >> Media record for Slot 8 Volume "CLN005L3" already exists.
> > > >> Sending label command for Volume "000013L6" Slot 9 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000013L6.
> > > >> Sending label command for Volume "000016L6" Slot 10 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000016L6.
> > > >> Sending label command for Volume "000019L6" Slot 11 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000019L6.
> > > >> Sending label command for Volume "000012L6" Slot 12 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000012L6.
> > > >> Sending label command for Volume "000009L6" Slot 13 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000009L6.
> > > >> Sending label command for Volume "000006L6" Slot 14 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000006L6.
> > > >> Sending label command for Volume "000003L6" Slot 15 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000003L6.
> > > >> Sending label command for Volume "000011L6" Slot 16 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000011L6.
> > > >> Sending label command for Volume "000008L6" Slot 17 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000008L6.
> > > >> Sending label command for Volume "000005L6" Slot 18 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000005L6.
> > > >> Sending label command for Volume "000002L6" Slot 19 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000002L6.
> > > >> Sending label command for Volume "000010L6" Slot 20 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000010L6.
> > > >> Sending label command for Volume "000007L6" Slot 21 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000007L6.
> > > >> Sending label command for Volume "000004L6" Slot 22 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000004L6.
> > > >> Sending label command for Volume "000001L6" Slot 23 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000001L6.
> > > >> You have messages.
> > > >> *
> > > >>
> > > >> From the bacula-sd.conf on odin (where the library is):
> > > >> Autochanger {
> > > >>   Name = AutochangerOdin
> > > >>   Device = Drive-1
> > > >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > > >>   Changer Device = /dev/autochanger1
> > > >> }
> > > >>
> > > >> Device {
> > > >>   Name = Drive-1                      #
> > > >>   Description = "LT06 inside Dell TL2000 Library"
> > > >>   Drive Index = 0
> > > >>   Media Type = LT06
> > > >>   Archive Device = /dev/nst0
> > > >>   AutomaticMount = yes;               # when device opened, read it
> > > >>   AlwaysOpen = yes;
> > > >>   RemovableMedia = yes;
> > > >>   RandomAccess = no;
> > > >>   AutoChanger = yes
> > > >>   SpoolDirectory = "/var/spool/bacula"
> > > >>   MaximumSpoolSize = 485G
> > > >>   Maximum Network Buffer Size = 65536
> > > >>   Offline On Unmount = no
> > > >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > >> }
> > > >>
> > > >> From bacula-dir.conf on sleipnir (where the director is):
> > > >> Storage {
> > > >>   Name = Library2
> > > >> # Do not use "localhost" here
> > > >>   Address = odin                # N.B. Use a fully qualified name here
> > > >>   SDPort = 9103
> > > >>   Password = "*****************"
> > > >>   Device = AutochangerOdin
> > > >>   Media Type = LTO6
> > > >>   Autochanger = yes                   # enable for autochanger device
> > > >> }
> > > >>
> > > >> From the /dev directory on odin:
> > > >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> > > >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> > > >>
> > > >>
> > > >>
> > > >> --
> > > >> Steve Garcia
> > > >> Ignorance killed the cat, curiosity was framed.
> > > >>
> > > >> ------------------------------------------------------------
> > > >> ------------------
> > > >> Check out the vibrant tech community on one of the world's most
> > > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > >> _______________________________________________
> > > >> Bacula-users mailing list
> > > >> [hidden email]
> > > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >>
> > > >
> > > >
> > > > ------------------------------------------------------------
> > > > ------------------
> > > > Check out the vibrant tech community on one of the world's most
> > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > > _______________________________________________
> > > > Bacula-users mailing list
> > > > [hidden email]
> > > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >
> > > >
> >
> >



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
Hello Steve,

Sorry, incomplete email again...

Yes, it looks we have something here.

From one of your previous emails, we have the error "3999 Device "AutochangerOdin" not found or could not be opened." when Bacula issues the label command for the tapes.

This "not found or could not be opened" message usually refers to the wrong "device name" configured for an "Archive Device" or "Changer Device".

The below two messages in the debug output also indicates this problem:
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping

From another post, you have only one tape library with one tape drive, but two paths for each of them:

root@odin:/etc/bacula# lsscsi -g
[0:2:0:0]    disk    DELL     PERC H730 Mini   4.27  /dev/sda   /dev/sg0
[1:0:0:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st0   /dev/sg2
[1:0:0:1]    mediumx IBM      3573-TL          E.30  /dev/sch0  /dev/sg3
[1:0:1:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st1   /dev/sg4
[1:0:1:1]    mediumx IBM      3573-TL          E.30  /dev/sch1  /dev/sg5
[6:2:0:0]    disk    DELL     PERC H830 Adp    4.27  /dev/sdb   /dev/sg1
[12:0:0:0]   cd/dvd  PLDS     DVD-ROM DS-8DBSH MD52  /dev/sr0   /dev/sg6

This seems to me you have a tape library/drive configured with physical multipath (zoning, two HBAs, etc.) for fail over?

If so, you don't have multipath configured in this linux system? This explains that your system sees two different device names for each one of your tape library and tape drive.

If this is the case, I'm afraid you will have problems to use the "/dev/tape/by-id" or "/dev/nst" device names for the tape drives. Maybe it would be better, in this case, to use "/dev/tape/by-path". Even better, to not have this physical multipath if you are not going to use it with the tape library...

Hope this helps.

Best regards,
Ana


On Tue, Aug 1, 2017 at 9:56 PM, Ana Emília M. Arruda <[hidden email]> wrote:
Hello Steve,

Yes, it looks we have something here.

From one of your previous emails, we have the error "3999 Device "AutochangerOdin" not found or could not be opened." when Bacula issues the label command for the tapes.

This "not found or could not be opened" message usually refers to the wrong "device name" configured for an "Archive Device" or "Changer Device".

From another post, you have only one tape library with one tape drive, but two paths for each of them:



On Mon, Jul 31, 2017 at 5:22 PM, Steve Garcia <[hidden email]> wrote:

OK, now we may be getting somewhere -- at least I have a dump of messages...

It does look like the problem is with the tape drive, but that's after it working fine at first.  It successfully opens the drive and determines (correctly) that the volume in the drive is an unlabeled tape.  As a result?  the tape drive is opened in a read-only state -- or maybe that's because it start by trying to read the existing label and you only need read-only for that.

# sudo -u bacula -g tape /usr/sbin/bacula-sd -d200
bacula-sd: address_conf.c:274-0 Initaddr 0.0.0.0:9103
bacula-sd: stored_conf.c:698-0 Inserting Director res: sleipnir-mon
root@odin:/etc/bacula# odin-sd: bsys.c:726-0 Could not open state file. sfd=-1 size=192: ERR=No such file or directory
odin-sd: stored.c:572-0 calling init_dev /dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: dev.c:342-0 init_dev: tape=1 dev_name=/dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: stored.c:574-0 SD init done /dev/tape/by-id/scsi-35000e11164c42001-nst
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe350002170
odin-sd: bnet_server.c:86-0 Addresses 136.168.201.110:9103
odin-sd: acquire.c:673-0 Attach 0x50001c68 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0
odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: stored.c:588-0 calling first_open_device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: device.c:279-0 start open_output_device()
odin-sd: device.c:298-0 Opening device.
odin-sd: tape_dev.c:958-0 Enter tape mount
odin-sd: tape_dev.c:84-0 Open dev: device is tape
odin-sd: autochanger.c:260-0 Return cached slot=1
odin-sd: tape_dev.c:99-0 Try open "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) mode=OPEN_READ_ONLY
odin-sd: tape_dev.c:121-0 Rewind after open
odin-sd: os.c:58-0 In set_os_device_parameters
odin-sd: os.c:64-0 Set block size to zero
odin-sd: tape_dev.c:176-0 open dev: tape 5 opened
odin-sd: dev.c:391-0 preserve=0x0 fd=5
odin-sd: dev.c:394-0 open dev: fd=5 dev=7fe350001476 dcr=7fe350001098 vol= type=2 dev_name="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) mode=OPEN_READ_ONLY
odin-sd: device.c:304-0 open dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) OK
odin-sd: label.c:72-0 Enter: int read_dev_volume_label(DCR*)
odin-sd: label.c:75-0 Enter read_volume_label res=0 device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) vol= dev_Vol=*NULL*
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: label.c:126-0 Big if statement in read_volume_label
odin-sd: block.c:458-0 Read() vol= nbytes=0 addr=-1
odin-sd: block.c:487-0 block.c:480 The Volume= on device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
odin-sd: block.c:493-0 ==== Read zero bytes. vol= at -1
odin-sd: label.c:131-0 Requested Volume "" on tape device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) is not a Bacula labeled Volume, because: ERR=block.c:480 The Volume= on device="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
odin-sd: label.c:160-0 No volume label - bailing out
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set binbuf=24
odin-sd: label.c:251-0 return 3
odin-sd: label.c:252-0 Leave: int read_dev_volume_label(DCR*)
odin-sd: stored.c:613-0 Could not mount device "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:24
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1587823263.1501531104@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <839623232.1501531104@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: P7tmG2+KsR/8M7YfplspnD
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: autochanger slots AutochangerOdin

odin-sd: dircmd.c:225-0 Do command: autochanger
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:837-0 Found changer device Drive-1
odin-sd: dircmd.c:850-0 Found device Drive-1
odin-sd: block_util.c:206-0 empty len=64512 block=7fe350012830 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe350012830
odin-sd: acquire.c:673-0 Attach 0x50012f38 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:670-0 <stored: slots=24
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:25
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1792316614.1501531105@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <1290223807.1501531105@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: u+RSe94jz4UptzNhM8+toC
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: autochanger list AutochangerOdin

odin-sd: dircmd.c:225-0 Do command: autochanger
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:837-0 Found changer device Drive-1
odin-sd: dircmd.c:850-0 Found device Drive-1
odin-sd: block_util.c:206-0 empty len=64512 block=7fe348001500 set binbuf=24
odin-sd: block_util.c:143-0 New block len=64512 block=7fe348001500
odin-sd: acquire.c:673-0 Attach 0x48000ff8 to dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0
odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0 /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
odin-sd: autochanger.c:657-0 <stored: 2:000018L6

odin-sd: autochanger.c:657-0 <stored: 3:000021L6

odin-sd: autochanger.c:657-0 <stored: 4:CLNU00L1

odin-sd: autochanger.c:657-0 <stored: 5:000014L6

odin-sd: autochanger.c:657-0 <stored: 6:000017L6

odin-sd: autochanger.c:657-0 <stored: 7:000020L6

odin-sd: autochanger.c:657-0 <stored: 8:CLN005L3

odin-sd: autochanger.c:657-0 <stored: 9:000013L6

odin-sd: autochanger.c:657-0 <stored: 10:000016L6

odin-sd: autochanger.c:657-0 <stored: 11:000019L6

odin-sd: autochanger.c:657-0 <stored: 12:000012L6

odin-sd: autochanger.c:657-0 <stored: 13:000009L6

odin-sd: autochanger.c:657-0 <stored: 14:000006L6

odin-sd: autochanger.c:657-0 <stored: 15:000003L6

odin-sd: autochanger.c:657-0 <stored: 16:000011L6

odin-sd: autochanger.c:657-0 <stored: 17:000008L6

odin-sd: autochanger.c:657-0 <stored: 18:000005L6

odin-sd: autochanger.c:657-0 <stored: 19:000002L6

odin-sd: autochanger.c:657-0 <stored: 20:000010L6

odin-sd: autochanger.c:657-0 <stored: 21:000007L6

odin-sd: autochanger.c:657-0 <stored: 22:000004L6

odin-sd: autochanger.c:657-0 <stored: 23:000001L6

odin-sd: autochanger.c:657-0 <stored: 1:000015L6


odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:35
odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge <1434613563.1501531115@odin-sd> ssl=0
odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5 <734308377.1501531115@sleipnir-dir> ssl=0
odin-sd: cram-md5.c:157-0 sending resp to challenge: GA/q4g/uIH/DvkJfC/+UwA
odin-sd: dircmd.c:204-0 Message channel init completed.
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000015L6 PoolName=OdinPool MediaType=LTO6 Slot=1 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000018L6 PoolName=OdinPool MediaType=LTO6 Slot=2 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000021L6 PoolName=OdinPool MediaType=LTO6 Slot=3 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000014L6 PoolName=OdinPool MediaType=LTO6 Slot=5 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000017L6 PoolName=OdinPool MediaType=LTO6 Slot=6 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000020L6 PoolName=OdinPool MediaType=LTO6 Slot=7 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000013L6 PoolName=OdinPool MediaType=LTO6 Slot=9 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000016L6 PoolName=OdinPool MediaType=LTO6 Slot=10 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000019L6 PoolName=OdinPool MediaType=LTO6 Slot=11 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000012L6 PoolName=OdinPool MediaType=LTO6 Slot=12 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000009L6 PoolName=OdinPool MediaType=LTO6 Slot=13 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000006L6 PoolName=OdinPool MediaType=LTO6 Slot=14 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000003L6 PoolName=OdinPool MediaType=LTO6 Slot=15 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000011L6 PoolName=OdinPool MediaType=LTO6 Slot=16 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000008L6 PoolName=OdinPool MediaType=LTO6 Slot=17 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000005L6 PoolName=OdinPool MediaType=LTO6 Slot=18 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000002L6 PoolName=OdinPool MediaType=LTO6 Slot=19 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000010L6 PoolName=OdinPool MediaType=LTO6 Slot=20 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000007L6 PoolName=OdinPool MediaType=LTO6 Slot=21 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000004L6 PoolName=OdinPool MediaType=LTO6 Slot=22 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping
odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000001L6 PoolName=OdinPool MediaType=LTO6 Slot=23 drive=0
odin-sd: dircmd.c:225-0 Do command: label
odin-sd: dircmd.c:817-0 Try changer device Drive-1
odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0 skipping



Steve Garcia
Ignorance killed the cat, curiosity was framed.

---- "Ana Emília M. Arruda" <[hidden email]> wrote:
> Hello Steve,
>
> Sorry, I sent an incomplete message.
>
> I think we will need to speak the same language here :-)
>
> You have your Director running at sleipnir host:
>
> root@sleipnir:/etc/bacula# bconsole
> Connecting to Director sleipnir:9101
> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
>
> with the Autochanger configuration on Director:
>
> From bacula-dir.conf on sleipnir (where the director is):
> Storage {
>   Name = Library2
> # Do not use "localhost" here
>   Address = odin                # N.B. Use a fully qualified name here
>   SDPort = 9103
>   Password = "*****************"
>   Device = AutochangerOdin
>   Media Type = LTO6
>   Autochanger = yes                   # enable for autochanger device
> }
>
> And you have your remote Storage Daemon installed in a host called
> odin with the following configuration:
>
> From the bacula-sd.conf on odin (where the library is):
> Autochanger {
>   Name = AutochangerOdin
>   Device = Drive-1
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/autochanger1
> }
>
> Device {
>   Name = Drive-1                      #
>   Description = "LT06 inside Dell TL2000 Library"
>   Drive Index = 0
>   Media Type = LT06
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;               # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   RandomAccess = no;
>   AutoChanger = yes
>   SpoolDirectory = "/var/spool/bacula"
>   MaximumSpoolSize = 485G
>   Maximum Network Buffer Size = 65536
>   Offline On Unmount = no
>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> }
> This is perfect.
>
> You are right, the permission needs to be checked.
>
> If you have bacula-sd runnig as bacula user, the bacula user must be member
> of tape group.
>
> Also, you can start the bacula-sd daemon in debug mode to get some debug
> output and maybe help in this case. The following command should be run on
> odin host:
>
> * sudo -u bacula -g tape /opt/ bacula/bin/bacula-sd -d200
>
> This will produce debug information on the Storage Daemon host and maybe we
> can have more information about this problem.
>
> Best,
> Ana
>
> On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]> wrote:
>
> >
> >
> > ---- Darold Lucus <[hidden email]> wrote:
> > > This is an example of my Autochanger listing in the bacula-sd.conf, this
> > is
> > > only a partial list but you would follow that format. My autochanger has
> > 16
> > > slots and a drive, the drive-1 is the writing drive.
> > >
> > > AutoChanger {
> > >   Name = AutoChanger
> > >   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6,
> > Drive-7,
> > > Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> > > Drive-15, Drive-16, Drive-17
> > >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > >   Changer Device = /dev/sg1
> > > }
> >
> > So you're defining each slot as a drive, but only defining the actual
> > drive as a device?
> >
> > >
> > > Device {
> > >   Name = Drive-1                      #
> > >   Drive Index = 0
> > >   Media Type = LTO5
> > >   Archive Device = /dev/st0
> > >   AutomaticMount = yes;               # when device opened, read it
> > >   AlwaysOpen = yes;
> > >   RemovableMedia = yes;
> > >   RandomAccess = no;
> > >   AutoChanger = yes
> > >
> > > }
> > >
> > > You also don't need this information in your storage section:
> > >
> > > Device = AutochangerOdin
> > >   Media Type = LTO6
> > >   Autochanger = yes                   # enable for autochanger device
> >
> > Well, I don't have those defined in the Storage resource of the
> > bacula-sd.conf configuration (which is on the remote machine where the
> > storage daemon lives) but I *do* have it in the Storage resource which is
> > part of the bacula-dir.conf configuration.  The director gets quite cranky
> > if you leave it out there.  :-)
> >
> >
> >
> >
> > >
> > > This is my example:
> > >
> > > Storage {                             # definition of myself
> > >   Name = nas-sd
> > >   SDPort = 9103                  # Director's port
> > >   WorkingDirectory = "/var/lib/bacula"
> > >   Pid Directory = "/var/run/bacula"
> > >   Maximum Concurrent Jobs = 20
> > >   SDAddress = IP.ADD.RE.SS
> > > }
> > >
> > >
> > > Hope this helps.
> > >
> > >
> > >
> > >
> > > Sincerely,
> > >
> > > Darold Lucus
> > >
> > >
> > > [image: cid:image002.png@01D06336.119F49E0] <http://www.emacinc.com/>
> > >
> > > =====================
> > > LAN Administrator
> > > EMAC, Inc
> > > <a href="tel:618-529-4525%20EXT%3A370" value="+16185294525" target="_blank">618-529-4525 EXT:370
> > > www.emacinc.com
> > > =====================
> > >
> > >
> > >
> > > This message is confidential. It may also be privileged or otherwise
> > > protected by work product immunity or other legal rules. If you have
> > > received it by mistake, please let us know by e-mail reply and delete it
> > > from your system; you may not copy this message or disclose its contents
> > to
> > > anyone.
> > >
> > > On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> > > [hidden email]> wrote:
> > >
> > > > Hi Steve,
> > > >
> > > > Sorry, my mistake...
> > > >
> > > > There is no problem in having a remote Storage Daemon with your tape
> > > > library attached. This is a very usual configuration.
> > > >
> > > > Before having a try with Bacula, I would recommend you to check if mtx
> > and
> > > > mt are properly working (please use /dev/tape/by-id names when running
> > > > tests).
> > > >
> > > > The error messages seems related to the tape drive and not to the tape
> > > > library configuration. So I would try "/dev/tape/by-id/scsi-
> > 35000e11164c42001-nst"
> > > > for the tape device:
> > > >
> > > > Device {
> > > >   Name = Drive-1                      #
> > > >   Description = "LT06 inside Dell TL2000 Library"
> > > >   Drive Index = 0
> > > >   Media Type = LT06
> > > >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> > > >   AutomaticMount = yes;               # when device opened, read it
> > > >   AlwaysOpen = yes;
> > > >   RemovableMedia = yes;
> > > >   RandomAccess = no;
> > > >   AutoChanger = yes
> > > >   SpoolDirectory = "/var/spool/bacula"
> > > >   MaximumSpoolSize = 485G
> > > >   Maximum Network Buffer Size = 65536
> > > >   Offline On Unmount = no
> > > >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > > }
> > > >
> > > > You should run btape tests before starting backups as well.
> > > >
> > > > Best regards,
> > > >
> > > > Ana
> > > >
> > > >
> > > > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]>
> > wrote:
> > > >
> > > >> OK, I've got my tape drive working (thanks Ana!) but I'm having
> > trouble
> > > >> connecting to the autochanger it's in using the director.  This is the
> > > >> first time I've tried having a storage daemon on a different machine
> > than
> > > >> the director.  The director is a slightly lower version (7.4.3 on
> > Debian
> > > >> Jessie using backports) than the storage daemon (7.4.4 on stretch)
> > but I
> > > >> had understood that those versions were close enough to work.
> > > >>
> > > >> So I'm hoping this is another configuration issue.
> > > >>
> > > >> Right now what I'm trying to do is label all the tapes in the new
> > library.
> > > >>
> > > >> When I try to access the new storage from the director, it is able to
> > get
> > > >> a listing of all the tapes, but it fails when it tries to actually do
> > the
> > > >> labeling.  I get a "3999 Device not found or could not be opened"
> > error.
> > > >> These errors show up quickly, there is no delay as it tries each
> > slot, so
> > > >> it's obviously not getting far enough to try.  But it *is* obviously
> > > >> connecting to the remote storage, otherwise it wouldn't be able to
> > obtain
> > > >> the slot list.
> > > >>
> > > >> What am I missing?
> > > >>
> > > >> root@sleipnir:/etc/bacula# bconsole
> > > >> Connecting to Director sleipnir:9101
> > > >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> > > >> Enter a period to cancel a command.
> > > >> *label storage=Library2 barcodes
> > > >> Automatically selected Catalog: MyCatalog
> > > >> Using Catalog "MyCatalog"
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "slots" command.
> > > >> Device "AutochangerOdin" has 24 slots.
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> 3306 Issuing autochanger "list" command.
> > > >> The following Volumes will be labeled:
> > > >> Slot  Volume
> > > >> ==============
> > > >>    1  000015L6
> > > >>    2  000018L6
> > > >>    3  000021L6
> > > >>    4  CLNU00L1
> > > >>    5  000014L6
> > > >>    6  000017L6
> > > >>    7  000020L6
> > > >>    8  CLN005L3
> > > >>    9  000013L6
> > > >>   10  000016L6
> > > >>   11  000019L6
> > > >>   12  000012L6
> > > >>   13  000009L6
> > > >>   14  000006L6
> > > >>   15  000003L6
> > > >>   16  000011L6
> > > >>   17  000008L6
> > > >>   18  000005L6
> > > >>   19  000002L6
> > > >>   20  000010L6
> > > >>   21  000007L6
> > > >>   22  000004L6
> > > >>   23  000001L6
> > > >> Do you want to label these Volumes? (yes|no):  yes
> > > >> Defined Pools:
> > > >>      1: Default
> > > >>      2: OdinPool
> > > >> Select the Pool (1-2): 2
> > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> > > >> Sending label command for Volume "000015L6" Slot 1 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000015L6.
> > > >> Sending label command for Volume "000018L6" Slot 2 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000018L6.
> > > >> Sending label command for Volume "000021L6" Slot 3 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000021L6.
> > > >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> > > >> Sending label command for Volume "000014L6" Slot 5 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000014L6.
> > > >> Sending label command for Volume "000017L6" Slot 6 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000017L6.
> > > >> Sending label command for Volume "000020L6" Slot 7 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000020L6.
> > > >> Media record for Slot 8 Volume "CLN005L3" already exists.
> > > >> Sending label command for Volume "000013L6" Slot 9 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000013L6.
> > > >> Sending label command for Volume "000016L6" Slot 10 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000016L6.
> > > >> Sending label command for Volume "000019L6" Slot 11 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000019L6.
> > > >> Sending label command for Volume "000012L6" Slot 12 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000012L6.
> > > >> Sending label command for Volume "000009L6" Slot 13 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000009L6.
> > > >> Sending label command for Volume "000006L6" Slot 14 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000006L6.
> > > >> Sending label command for Volume "000003L6" Slot 15 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000003L6.
> > > >> Sending label command for Volume "000011L6" Slot 16 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000011L6.
> > > >> Sending label command for Volume "000008L6" Slot 17 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000008L6.
> > > >> Sending label command for Volume "000005L6" Slot 18 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000005L6.
> > > >> Sending label command for Volume "000002L6" Slot 19 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000002L6.
> > > >> Sending label command for Volume "000010L6" Slot 20 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000010L6.
> > > >> Sending label command for Volume "000007L6" Slot 21 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000007L6.
> > > >> Sending label command for Volume "000004L6" Slot 22 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000004L6.
> > > >> Sending label command for Volume "000001L6" Slot 23 ...
> > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> > > >> Label command failed for Volume 000001L6.
> > > >> You have messages.
> > > >> *
> > > >>
> > > >> From the bacula-sd.conf on odin (where the library is):
> > > >> Autochanger {
> > > >>   Name = AutochangerOdin
> > > >>   Device = Drive-1
> > > >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> > > >>   Changer Device = /dev/autochanger1
> > > >> }
> > > >>
> > > >> Device {
> > > >>   Name = Drive-1                      #
> > > >>   Description = "LT06 inside Dell TL2000 Library"
> > > >>   Drive Index = 0
> > > >>   Media Type = LT06
> > > >>   Archive Device = /dev/nst0
> > > >>   AutomaticMount = yes;               # when device opened, read it
> > > >>   AlwaysOpen = yes;
> > > >>   RemovableMedia = yes;
> > > >>   RandomAccess = no;
> > > >>   AutoChanger = yes
> > > >>   SpoolDirectory = "/var/spool/bacula"
> > > >>   MaximumSpoolSize = 485G
> > > >>   Maximum Network Buffer Size = 65536
> > > >>   Offline On Unmount = no
> > > >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> > > >> }
> > > >>
> > > >> From bacula-dir.conf on sleipnir (where the director is):
> > > >> Storage {
> > > >>   Name = Library2
> > > >> # Do not use "localhost" here
> > > >>   Address = odin                # N.B. Use a fully qualified name here
> > > >>   SDPort = 9103
> > > >>   Password = "*****************"
> > > >>   Device = AutochangerOdin
> > > >>   Media Type = LTO6
> > > >>   Autochanger = yes                   # enable for autochanger device
> > > >> }
> > > >>
> > > >> From the /dev directory on odin:
> > > >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 -> sg3
> > > >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> > > >>
> > > >>
> > > >>
> > > >> --
> > > >> Steve Garcia
> > > >> Ignorance killed the cat, curiosity was framed.
> > > >>
> > > >> ------------------------------------------------------------
> > > >> ------------------
> > > >> Check out the vibrant tech community on one of the world's most
> > > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > >> _______________________________________________
> > > >> Bacula-users mailing list
> > > >> [hidden email]
> > > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >>
> > > >
> > > >
> > > > ------------------------------------------------------------
> > > > ------------------
> > > > Check out the vibrant tech community on one of the world's most
> > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > > _______________________________________________
> > > > Bacula-users mailing list
> > > > [hidden email]
> > > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > > >
> > > >
> >
> >




------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Steve Garcia



---- "Ana Emília M. Arruda" <[hidden email]> wrote:

> Hello Steve,
>
> Sorry, incomplete email again...
>
> Yes, it looks we have something here.
>
> From one of your previous emails, we have the error "3999 Device
> "AutochangerOdin" not found or could not be opened." when Bacula issues the
> label command for the tapes.
>
> This "not found or could not be opened" message usually refers to the wrong
> "device name" configured for an "Archive Device" or "Changer Device".
>
> The below two messages in the debug output also indicates this problem:
> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> skipping
>
> From another post, you have only one tape library with one tape drive, but
> two paths for each of them:
>
> root@odin:/etc/bacula# lsscsi -g
> [0:2:0:0]    disk    DELL     PERC H730 Mini   4.27  /dev/sda   /dev/sg0
> [1:0:0:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st0   /dev/sg2
> [1:0:0:1]    mediumx IBM      3573-TL          E.30  /dev/sch0  /dev/sg3
> [1:0:1:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st1   /dev/sg4
> [1:0:1:1]    mediumx IBM      3573-TL          E.30  /dev/sch1  /dev/sg5
> [6:2:0:0]    disk    DELL     PERC H830 Adp    4.27  /dev/sdb   /dev/sg1
> [12:0:0:0]   cd/dvd  PLDS     DVD-ROM DS-8DBSH MD52  /dev/sr0   /dev/sg6
>
> This seems to me you have a tape library/drive configured with physical
> multipath (zoning, two HBAs, etc.) for fail over?

Well, this machine *does* have physical multipathing, but not for the library or tape drive.  The PERC H830 listed above is a single HBA/RAID controller, but with two interfaces that go to separate controllers on my disk array.  Multipath is configured for the system, but only intended for the disk array.

The library is connected to a different HBA (which apparently doesn't rate an entry in the above table, being a simple SCSI HBA) which also has two interfaces.  One goes to the tape drive and one to the changer, so there is no actual physical multipath in that chain.

Is it possible that having the multipath libraries loaded could be confusing the system about the tape path?  I can't get rid of the multipath, but maybe there is a way to exclude the tape systems?

Redefining the tape to its by-path designation doesn't look like it will work:

02-Aug 09:59 bacula-sd: ERROR TERMINATION at parse_conf.c:393
Config error: Attempt to redefine "ArchiveDevice" from "/dev/tape/by-id/scsi-35000e11164c42001-nst" to "/dev/tape/by-path/pci-0000:05:00.0-sas-phy2-lun-0-nst" referenced on line 78 :   Archive Device = /dev/tape/by-path/pci-0000:05:00.0-sas-phy2-lun-0-nst


            : line 78, col 72 of file /etc/bacula/bacula-sd.conf
  Archive Device = /dev/tape/by-path/pci-0000:05:00.0-sas-phy2-lun-0-nst

> If so, you don't have multipath configured in this linux system? This
> explains that your system sees two different device names for each one of
> your tape library and tape drive.
>
> If this is the case, I'm afraid you will have problems to use the
> "/dev/tape/by-id" or "/dev/nst" device names for the tape drives. Maybe it
> would be better, in this case, to use "/dev/tape/by-path". Even better, to
> not have this physical multipath if you are not going to use it with the
> tape library...
>
> Hope this helps.
>
> Best regards,
> Ana
>
>
> On Tue, Aug 1, 2017 at 9:56 PM, Ana Emília M. Arruda <[hidden email]
> > wrote:
>
> > Hello Steve,
> >
> > Yes, it looks we have something here.
> >
> > From one of your previous emails, we have the error "3999 Device
> > "AutochangerOdin" not found or could not be opened." when Bacula issues the
> > label command for the tapes.
> >
> > This "not found or could not be opened" message usually refers to the
> > wrong "device name" configured for an "Archive Device" or "Changer Device".
> >
> > From another post, you have only one tape library with one tape drive, but
> > two paths for each of them:
> >
> >
> >
> > On Mon, Jul 31, 2017 at 5:22 PM, Steve Garcia <[hidden email]> wrote:
> >
> >>
> >> OK, now we may be getting somewhere -- at least I have a dump of
> >> messages...
> >>
> >> It does look like the problem is with the tape drive, but that's after it
> >> working fine at first.  It successfully opens the drive and determines
> >> (correctly) that the volume in the drive is an unlabeled tape.  As a
> >> result?  the tape drive is opened in a read-only state -- or maybe that's
> >> because it start by trying to read the existing label and you only need
> >> read-only for that.
> >>
> >> # sudo -u bacula -g tape /usr/sbin/bacula-sd -d200
> >> bacula-sd: address_conf.c:274-0 Initaddr 0.0.0.0:9103
> >> bacula-sd: stored_conf.c:698-0 Inserting Director res: sleipnir-mon
> >> root@odin:/etc/bacula# odin-sd: bsys.c:726-0 Could not open state file.
> >> sfd=-1 size=192: ERR=No such file or directory
> >> odin-sd: stored.c:572-0 calling init_dev /dev/tape/by-id/scsi-35000e111
> >> 64c42001-nst
> >> odin-sd: dev.c:342-0 init_dev: tape=1 dev_name=/dev/tape/by-id/scsi-
> >> 35000e11164c42001-nst
> >> odin-sd: stored.c:574-0 SD init done /dev/tape/by-id/scsi-35000e111
> >> 64c42001-nst
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set
> >> binbuf=24
> >> odin-sd: block_util.c:143-0 New block len=64512 block=7fe350002170
> >> odin-sd: bnet_server.c:86-0 Addresses 136.168.201.110:9103
> >> odin-sd: acquire.c:673-0 Attach 0x50001c68 to dev "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0
> >> odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: stored.c:588-0 calling first_open_device "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: device.c:279-0 start open_output_device()
> >> odin-sd: device.c:298-0 Opening device.
> >> odin-sd: tape_dev.c:958-0 Enter tape mount
> >> odin-sd: tape_dev.c:84-0 Open dev: device is tape
> >> odin-sd: autochanger.c:260-0 Return cached slot=1
> >> odin-sd: tape_dev.c:99-0 Try open "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> mode=OPEN_READ_ONLY
> >> odin-sd: tape_dev.c:121-0 Rewind after open
> >> odin-sd: os.c:58-0 In set_os_device_parameters
> >> odin-sd: os.c:64-0 Set block size to zero
> >> odin-sd: tape_dev.c:176-0 open dev: tape 5 opened
> >> odin-sd: dev.c:391-0 preserve=0x0 fd=5
> >> odin-sd: dev.c:394-0 open dev: fd=5 dev=7fe350001476 dcr=7fe350001098
> >> vol= type=2 dev_name="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> mode=OPEN_READ_ONLY
> >> odin-sd: device.c:304-0 open dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> OK
> >> odin-sd: label.c:72-0 Enter: int read_dev_volume_label(DCR*)
> >> odin-sd: label.c:75-0 Enter read_volume_label res=0 device="Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) vol= dev_Vol=*NULL*
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set
> >> binbuf=24
> >> odin-sd: label.c:126-0 Big if statement in read_volume_label
> >> odin-sd: block.c:458-0 Read() vol= nbytes=0 addr=-1
> >> odin-sd: block.c:487-0 block.c:480 The Volume= on device="Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
> >> odin-sd: block.c:493-0 ==== Read zero bytes. vol= at -1
> >> odin-sd: label.c:131-0 Requested Volume "" on tape device "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) is not a Bacula labeled
> >> Volume, because: ERR=block.c:480 The Volume= on device="Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
> >> odin-sd: label.c:160-0 No volume label - bailing out
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set
> >> binbuf=24
> >> odin-sd: label.c:251-0 return 3
> >> odin-sd: label.c:252-0 Leave: int read_dev_volume_label(DCR*)
> >> odin-sd: stored.c:613-0 Could not mount device "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
> >> odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:24
> >> odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge
> >> <1587823263.1501531104@odin-sd> ssl=0
> >> odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5
> >> <839623232.1501531104@sleipnir-dir> ssl=0
> >> odin-sd: cram-md5.c:157-0 sending resp to challenge:
> >> P7tmG2+KsR/8M7YfplspnD
> >> odin-sd: dircmd.c:204-0 Message channel init completed.
> >> odin-sd: dircmd.c:211-0 <dird: autochanger slots AutochangerOdin
> >>
> >> odin-sd: dircmd.c:225-0 Do command: autochanger
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:837-0 Found changer device Drive-1
> >> odin-sd: dircmd.c:850-0 Found device Drive-1
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350012830 set
> >> binbuf=24
> >> odin-sd: block_util.c:143-0 New block len=64512 block=7fe350012830
> >> odin-sd: acquire.c:673-0 Attach 0x50012f38 to dev "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:670-0 <stored: slots=24
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
> >> odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:25
> >> odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge
> >> <1792316614.1501531105@odin-sd> ssl=0
> >> odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5
> >> <1290223807.1501531105@sleipnir-dir> ssl=0
> >> odin-sd: cram-md5.c:157-0 sending resp to challenge:
> >> u+RSe94jz4UptzNhM8+toC
> >> odin-sd: dircmd.c:204-0 Message channel init completed.
> >> odin-sd: dircmd.c:211-0 <dird: autochanger list AutochangerOdin
> >>
> >> odin-sd: dircmd.c:225-0 Do command: autochanger
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:837-0 Found changer device Drive-1
> >> odin-sd: dircmd.c:850-0 Found device Drive-1
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe348001500 set
> >> binbuf=24
> >> odin-sd: block_util.c:143-0 New block len=64512 block=7fe348001500
> >> odin-sd: acquire.c:673-0 Attach 0x48000ff8 to dev "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0
> >> odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:657-0 <stored: 2:000018L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 3:000021L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 4:CLNU00L1
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 5:000014L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 6:000017L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 7:000020L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 8:CLN005L3
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 9:000013L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 10:000016L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 11:000019L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 12:000012L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 13:000009L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 14:000006L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 15:000003L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 16:000011L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 17:000008L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 18:000005L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 19:000002L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 20:000010L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 21:000007L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 22:000004L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 23:000001L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 1:000015L6
> >>
> >>
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
> >> odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:35
> >> odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge
> >> <1434613563.1501531115@odin-sd> ssl=0
> >> odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5
> >> <734308377.1501531115@sleipnir-dir> ssl=0
> >> odin-sd: cram-md5.c:157-0 sending resp to challenge:
> >> GA/q4g/uIH/DvkJfC/+UwA
> >> odin-sd: dircmd.c:204-0 Message channel init completed.
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000015L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=1 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000018L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=2 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000021L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=3 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000014L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=5 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000017L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=6 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000020L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=7 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000013L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=9 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000016L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=10 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000019L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=11 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000012L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=12 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000009L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=13 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000006L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=14 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000003L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=15 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000011L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=16 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000008L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=17 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000005L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=18 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000002L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=19 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000010L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=20 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000007L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=21 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000004L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=22 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000001L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=23 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >>
> >>
> >>
> >> Steve Garcia
> >> Ignorance killed the cat, curiosity was framed.
> >>
> >> ---- "Ana Emília M. Arruda" <[hidden email]> wrote:
> >> > Hello Steve,
> >> >
> >> > Sorry, I sent an incomplete message.
> >> >
> >> > I think we will need to speak the same language here :-)
> >> >
> >> > You have your Director running at sleipnir host:
> >> >
> >> > root@sleipnir:/etc/bacula# bconsole
> >> > Connecting to Director sleipnir:9101
> >> > 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> >
> >> > with the Autochanger configuration on Director:
> >> >
> >> > From bacula-dir.conf on sleipnir (where the director is):
> >> > Storage {
> >> >   Name = Library2
> >> > # Do not use "localhost" here
> >> >   Address = odin                # N.B. Use a fully qualified name here
> >> >   SDPort = 9103
> >> >   Password = "*****************"
> >> >   Device = AutochangerOdin
> >> >   Media Type = LTO6
> >> >   Autochanger = yes                   # enable for autochanger device
> >> > }
> >> >
> >> > And you have your remote Storage Daemon installed in a host called
> >> > odin with the following configuration:
> >> >
> >> > From the bacula-sd.conf on odin (where the library is):
> >> > Autochanger {
> >> >   Name = AutochangerOdin
> >> >   Device = Drive-1
> >> >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> >> >   Changer Device = /dev/autochanger1
> >> > }
> >> >
> >> > Device {
> >> >   Name = Drive-1                      #
> >> >   Description = "LT06 inside Dell TL2000 Library"
> >> >   Drive Index = 0
> >> >   Media Type = LT06
> >> >   Archive Device = /dev/nst0
> >> >   AutomaticMount = yes;               # when device opened, read it
> >> >   AlwaysOpen = yes;
> >> >   RemovableMedia = yes;
> >> >   RandomAccess = no;
> >> >   AutoChanger = yes
> >> >   SpoolDirectory = "/var/spool/bacula"
> >> >   MaximumSpoolSize = 485G
> >> >   Maximum Network Buffer Size = 65536
> >> >   Offline On Unmount = no
> >> >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> > }
> >> > This is perfect.
> >> >
> >> > You are right, the permission needs to be checked.
> >> >
> >> > If you have bacula-sd runnig as bacula user, the bacula user must be
> >> member
> >> > of tape group.
> >> >
> >> > Also, you can start the bacula-sd daemon in debug mode to get some debug
> >> > output and maybe help in this case. The following command should be run
> >> on
> >> > odin host:
> >> >
> >> > * sudo -u bacula -g tape /opt/ bacula/bin/bacula-sd -d200
> >> >
> >> > This will produce debug information on the Storage Daemon host and
> >> maybe we
> >> > can have more information about this problem.
> >> >
> >> > Best,
> >> > Ana
> >> >
> >> > On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]>
> >> wrote:
> >> >
> >> > >
> >> > >
> >> > > ---- Darold Lucus <[hidden email]> wrote:
> >> > > > This is an example of my Autochanger listing in the bacula-sd.conf,
> >> this
> >> > > is
> >> > > > only a partial list but you would follow that format. My
> >> autochanger has
> >> > > 16
> >> > > > slots and a drive, the drive-1 is the writing drive.
> >> > > >
> >> > > > AutoChanger {
> >> > > >   Name = AutoChanger
> >> > > >   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6,
> >> > > Drive-7,
> >> > > > Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> >> > > > Drive-15, Drive-16, Drive-17
> >> > > >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a
> >> %d"
> >> > > >   Changer Device = /dev/sg1
> >> > > > }
> >> > >
> >> > > So you're defining each slot as a drive, but only defining the actual
> >> > > drive as a device?
> >> > >
> >> > > >
> >> > > > Device {
> >> > > >   Name = Drive-1                      #
> >> > > >   Drive Index = 0
> >> > > >   Media Type = LTO5
> >> > > >   Archive Device = /dev/st0
> >> > > >   AutomaticMount = yes;               # when device opened, read it
> >> > > >   AlwaysOpen = yes;
> >> > > >   RemovableMedia = yes;
> >> > > >   RandomAccess = no;
> >> > > >   AutoChanger = yes
> >> > > >
> >> > > > }
> >> > > >
> >> > > > You also don't need this information in your storage section:
> >> > > >
> >> > > > Device = AutochangerOdin
> >> > > >   Media Type = LTO6
> >> > > >   Autochanger = yes                   # enable for autochanger
> >> device
> >> > >
> >> > > Well, I don't have those defined in the Storage resource of the
> >> > > bacula-sd.conf configuration (which is on the remote machine where the
> >> > > storage daemon lives) but I *do* have it in the Storage resource
> >> which is
> >> > > part of the bacula-dir.conf configuration.  The director gets quite
> >> cranky
> >> > > if you leave it out there.  :-)
> >> > >
> >> > >
> >> > >
> >> > >
> >> > > >
> >> > > > This is my example:
> >> > > >
> >> > > > Storage {                             # definition of myself
> >> > > >   Name = nas-sd
> >> > > >   SDPort = 9103                  # Director's port
> >> > > >   WorkingDirectory = "/var/lib/bacula"
> >> > > >   Pid Directory = "/var/run/bacula"
> >> > > >   Maximum Concurrent Jobs = 20
> >> > > >   SDAddress = IP.ADD.RE.SS
> >> > > > }
> >> > > >
> >> > > >
> >> > > > Hope this helps.
> >> > > >
> >> > > >
> >> > > >
> >> > > >
> >> > > > Sincerely,
> >> > > >
> >> > > > Darold Lucus
> >> > > >
> >> > > >
> >> > > > [image: cid:image002.png@01D06336.119F49E0] <
> >> http://www.emacinc.com/>
> >> > > >
> >> > > > =====================
> >> > > > LAN Administrator
> >> > > > EMAC, Inc
> >> > > > 618-529-4525 EXT:370
> >> > > > www.emacinc.com
> >> > > > =====================
> >> > > >
> >> > > >
> >> > > >
> >> > > > This message is confidential. It may also be privileged or otherwise
> >> > > > protected by work product immunity or other legal rules. If you have
> >> > > > received it by mistake, please let us know by e-mail reply and
> >> delete it
> >> > > > from your system; you may not copy this message or disclose its
> >> contents
> >> > > to
> >> > > > anyone.
> >> > > >
> >> > > > On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> >> > > > [hidden email]> wrote:
> >> > > >
> >> > > > > Hi Steve,
> >> > > > >
> >> > > > > Sorry, my mistake...
> >> > > > >
> >> > > > > There is no problem in having a remote Storage Daemon with your
> >> tape
> >> > > > > library attached. This is a very usual configuration.
> >> > > > >
> >> > > > > Before having a try with Bacula, I would recommend you to check
> >> if mtx
> >> > > and
> >> > > > > mt are properly working (please use /dev/tape/by-id names when
> >> running
> >> > > > > tests).
> >> > > > >
> >> > > > > The error messages seems related to the tape drive and not to the
> >> tape
> >> > > > > library configuration. So I would try "/dev/tape/by-id/scsi-
> >> > > 35000e11164c42001-nst"
> >> > > > > for the tape device:
> >> > > > >
> >> > > > > Device {
> >> > > > >   Name = Drive-1                      #
> >> > > > >   Description = "LT06 inside Dell TL2000 Library"
> >> > > > >   Drive Index = 0
> >> > > > >   Media Type = LT06
> >> > > > >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> >> > > > >   AutomaticMount = yes;               # when device opened, read
> >> it
> >> > > > >   AlwaysOpen = yes;
> >> > > > >   RemovableMedia = yes;
> >> > > > >   RandomAccess = no;
> >> > > > >   AutoChanger = yes
> >> > > > >   SpoolDirectory = "/var/spool/bacula"
> >> > > > >   MaximumSpoolSize = 485G
> >> > > > >   Maximum Network Buffer Size = 65536
> >> > > > >   Offline On Unmount = no
> >> > > > >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> > > > > }
> >> > > > >
> >> > > > > You should run btape tests before starting backups as well.
> >> > > > >
> >> > > > > Best regards,
> >> > > > >
> >> > > > > Ana
> >> > > > >
> >> > > > >
> >> > > > > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]
> >> >
> >> > > wrote:
> >> > > > >
> >> > > > >> OK, I've got my tape drive working (thanks Ana!) but I'm having
> >> > > trouble
> >> > > > >> connecting to the autochanger it's in using the director.  This
> >> is the
> >> > > > >> first time I've tried having a storage daemon on a different
> >> machine
> >> > > than
> >> > > > >> the director.  The director is a slightly lower version (7.4.3 on
> >> > > Debian
> >> > > > >> Jessie using backports) than the storage daemon (7.4.4 on
> >> stretch)
> >> > > but I
> >> > > > >> had understood that those versions were close enough to work.
> >> > > > >>
> >> > > > >> So I'm hoping this is another configuration issue.
> >> > > > >>
> >> > > > >> Right now what I'm trying to do is label all the tapes in the new
> >> > > library.
> >> > > > >>
> >> > > > >> When I try to access the new storage from the director, it is
> >> able to
> >> > > get
> >> > > > >> a listing of all the tapes, but it fails when it tries to
> >> actually do
> >> > > the
> >> > > > >> labeling.  I get a "3999 Device not found or could not be opened"
> >> > > error.
> >> > > > >> These errors show up quickly, there is no delay as it tries each
> >> > > slot, so
> >> > > > >> it's obviously not getting far enough to try.  But it *is*
> >> obviously
> >> > > > >> connecting to the remote storage, otherwise it wouldn't be able
> >> to
> >> > > obtain
> >> > > > >> the slot list.
> >> > > > >>
> >> > > > >> What am I missing?
> >> > > > >>
> >> > > > >> root@sleipnir:/etc/bacula# bconsole
> >> > > > >> Connecting to Director sleipnir:9101
> >> > > > >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> > > > >> Enter a period to cancel a command.
> >> > > > >> *label storage=Library2 barcodes
> >> > > > >> Automatically selected Catalog: MyCatalog
> >> > > > >> Using Catalog "MyCatalog"
> >> > > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> > > > >> 3306 Issuing autochanger "slots" command.
> >> > > > >> Device "AutochangerOdin" has 24 slots.
> >> > > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> > > > >> 3306 Issuing autochanger "list" command.
> >> > > > >> The following Volumes will be labeled:
> >> > > > >> Slot  Volume
> >> > > > >> ==============
> >> > > > >>    1  000015L6
> >> > > > >>    2  000018L6
> >> > > > >>    3  000021L6
> >> > > > >>    4  CLNU00L1
> >> > > > >>    5  000014L6
> >> > > > >>    6  000017L6
> >> > > > >>    7  000020L6
> >> > > > >>    8  CLN005L3
> >> > > > >>    9  000013L6
> >> > > > >>   10  000016L6
> >> > > > >>   11  000019L6
> >> > > > >>   12  000012L6
> >> > > > >>   13  000009L6
> >> > > > >>   14  000006L6
> >> > > > >>   15  000003L6
> >> > > > >>   16  000011L6
> >> > > > >>   17  000008L6
> >> > > > >>   18  000005L6
> >> > > > >>   19  000002L6
> >> > > > >>   20  000010L6
> >> > > > >>   21  000007L6
> >> > > > >>   22  000004L6
> >> > > > >>   23  000001L6
> >> > > > >> Do you want to label these Volumes? (yes|no):  yes
> >> > > > >> Defined Pools:
> >> > > > >>      1: Default
> >> > > > >>      2: OdinPool
> >> > > > >> Select the Pool (1-2): 2
> >> > > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> > > > >> Sending label command for Volume "000015L6" Slot 1 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000015L6.
> >> > > > >> Sending label command for Volume "000018L6" Slot 2 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000018L6.
> >> > > > >> Sending label command for Volume "000021L6" Slot 3 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000021L6.
> >> > > > >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> >> > > > >> Sending label command for Volume "000014L6" Slot 5 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000014L6.
> >> > > > >> Sending label command for Volume "000017L6" Slot 6 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000017L6.
> >> > > > >> Sending label command for Volume "000020L6" Slot 7 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000020L6.
> >> > > > >> Media record for Slot 8 Volume "CLN005L3" already exists.
> >> > > > >> Sending label command for Volume "000013L6" Slot 9 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000013L6.
> >> > > > >> Sending label command for Volume "000016L6" Slot 10 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000016L6.
> >> > > > >> Sending label command for Volume "000019L6" Slot 11 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000019L6.
> >> > > > >> Sending label command for Volume "000012L6" Slot 12 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000012L6.
> >> > > > >> Sending label command for Volume "000009L6" Slot 13 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000009L6.
> >> > > > >> Sending label command for Volume "000006L6" Slot 14 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000006L6.
> >> > > > >> Sending label command for Volume "000003L6" Slot 15 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000003L6.
> >> > > > >> Sending label command for Volume "000011L6" Slot 16 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000011L6.
> >> > > > >> Sending label command for Volume "000008L6" Slot 17 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000008L6.
> >> > > > >> Sending label command for Volume "000005L6" Slot 18 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000005L6.
> >> > > > >> Sending label command for Volume "000002L6" Slot 19 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000002L6.
> >> > > > >> Sending label command for Volume "000010L6" Slot 20 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000010L6.
> >> > > > >> Sending label command for Volume "000007L6" Slot 21 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000007L6.
> >> > > > >> Sending label command for Volume "000004L6" Slot 22 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000004L6.
> >> > > > >> Sending label command for Volume "000001L6" Slot 23 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000001L6.
> >> > > > >> You have messages.
> >> > > > >> *
> >> > > > >>
> >> > > > >> From the bacula-sd.conf on odin (where the library is):
> >> > > > >> Autochanger {
> >> > > > >>   Name = AutochangerOdin
> >> > > > >>   Device = Drive-1
> >> > > > >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S
> >> %a %d"
> >> > > > >>   Changer Device = /dev/autochanger1
> >> > > > >> }
> >> > > > >>
> >> > > > >> Device {
> >> > > > >>   Name = Drive-1                      #
> >> > > > >>   Description = "LT06 inside Dell TL2000 Library"
> >> > > > >>   Drive Index = 0
> >> > > > >>   Media Type = LT06
> >> > > > >>   Archive Device = /dev/nst0
> >> > > > >>   AutomaticMount = yes;               # when device opened, read
> >> it
> >> > > > >>   AlwaysOpen = yes;
> >> > > > >>   RemovableMedia = yes;
> >> > > > >>   RandomAccess = no;
> >> > > > >>   AutoChanger = yes
> >> > > > >>   SpoolDirectory = "/var/spool/bacula"
> >> > > > >>   MaximumSpoolSize = 485G
> >> > > > >>   Maximum Network Buffer Size = 65536
> >> > > > >>   Offline On Unmount = no
> >> > > > >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> > > > >> }
> >> > > > >>
> >> > > > >> From bacula-dir.conf on sleipnir (where the director is):
> >> > > > >> Storage {
> >> > > > >>   Name = Library2
> >> > > > >> # Do not use "localhost" here
> >> > > > >>   Address = odin                # N.B. Use a fully qualified
> >> name here
> >> > > > >>   SDPort = 9103
> >> > > > >>   Password = "*****************"
> >> > > > >>   Device = AutochangerOdin
> >> > > > >>   Media Type = LTO6
> >> > > > >>   Autochanger = yes                   # enable for autochanger
> >> device
> >> > > > >> }
> >> > > > >>
> >> > > > >> From the /dev directory on odin:
> >> > > > >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 ->
> >> sg3
> >> > > > >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> >> > > > >>
> >> > > > >>
> >> > > > >>
> >> > > > >> --
> >> > > > >> Steve Garcia
> >> > > > >> Ignorance killed the cat, curiosity was framed.
> >> > > > >>
> >> > > > >> ------------------------------------------------------------
> >> > > > >> ------------------
> >> > > > >> Check out the vibrant tech community on one of the world's most
> >> > > > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > > >> _______________________________________________
> >> > > > >> Bacula-users mailing list
> >> > > > >> [hidden email]
> >> > > > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> >> > > > >>
> >> > > > >
> >> > > > >
> >> > > > > ------------------------------------------------------------
> >> > > > > ------------------
> >> > > > > Check out the vibrant tech community on one of the world's most
> >> > > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > > > _______________________________________________
> >> > > > > Bacula-users mailing list
> >> > > > > [hidden email]
> >> > > > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> >> > > > >
> >> > > > >
> >> > >
> >> > >
> >>
> >>
> >


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error talking to remote storage daemon

Ana Emília M. Arruda
Hello Steve,

I think this may help you to disable linux multipathing for the tape library: http://thegeekdiary.com/beginners-guide-to-device-mapper-dm-multipathing/

The tape library and tape drive can be configured in the black list:

blacklistBlacklisted devies. Devices that should not be configured under DMMP
Once you have your tape library/drive not using linux multipath, everything should run fine with your Bacula configurations using the "/dev/tape/by-id" device name.

Hope this helps.

Best regards,
Ana



On Wed, Aug 2, 2017 at 2:07 PM, Steve Garcia <[hidden email]> wrote:



---- "Ana Emília M. Arruda" <[hidden email]> wrote:
> Hello Steve,
>
> Sorry, incomplete email again...
>
> Yes, it looks we have something here.
>
> From one of your previous emails, we have the error "3999 Device
> "AutochangerOdin" not found or could not be opened." when Bacula issues the
> label command for the tapes.
>
> This "not found or could not be opened" message usually refers to the wrong
> "device name" configured for an "Archive Device" or "Changer Device".
>
> The below two messages in the debug output also indicates this problem:
> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> skipping
>
> From another post, you have only one tape library with one tape drive, but
> two paths for each of them:
>
> root@odin:/etc/bacula# lsscsi -g
> [0:2:0:0]    disk    DELL     PERC H730 Mini   4.27  /dev/sda   /dev/sg0
> [1:0:0:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st0   /dev/sg2
> [1:0:0:1]    mediumx IBM      3573-TL          E.30  /dev/sch0  /dev/sg3
> [1:0:1:0]    tape    IBM      ULT3580-HH6      G9P1  /dev/st1   /dev/sg4
> [1:0:1:1]    mediumx IBM      3573-TL          E.30  /dev/sch1  /dev/sg5
> [6:2:0:0]    disk    DELL     PERC H830 Adp    4.27  /dev/sdb   /dev/sg1
> [12:0:0:0]   cd/dvd  PLDS     DVD-ROM DS-8DBSH MD52  /dev/sr0   /dev/sg6
>
> This seems to me you have a tape library/drive configured with physical
> multipath (zoning, two HBAs, etc.) for fail over?

Well, this machine *does* have physical multipathing, but not for the library or tape drive.  The PERC H830 listed above is a single HBA/RAID controller, but with two interfaces that go to separate controllers on my disk array.  Multipath is configured for the system, but only intended for the disk array.

The library is connected to a different HBA (which apparently doesn't rate an entry in the above table, being a simple SCSI HBA) which also has two interfaces.  One goes to the tape drive and one to the changer, so there is no actual physical multipath in that chain.

Is it possible that having the multipath libraries loaded could be confusing the system about the tape path?  I can't get rid of the multipath, but maybe there is a way to exclude the tape systems?

Redefining the tape to its by-path designation doesn't look like it will work:

02-Aug 09:59 bacula-sd: ERROR TERMINATION at parse_conf.c:393
Config error: Attempt to redefine "ArchiveDevice" from "/dev/tape/by-id/scsi-35000e11164c42001-nst" to "/dev/tape/by-path/pci-0000:05:00.0-sas-phy2-lun-0-nst" referenced on line 78 :   Archive Device = /dev/tape/by-path/pci-0000:05:00.0-sas-phy2-lun-0-nst


            : line 78, col 72 of file /etc/bacula/bacula-sd.conf
  Archive Device = /dev/tape/by-path/pci-0000:05:00.0-sas-phy2-lun-0-nst

> If so, you don't have multipath configured in this linux system? This
> explains that your system sees two different device names for each one of
> your tape library and tape drive.
>
> If this is the case, I'm afraid you will have problems to use the
> "/dev/tape/by-id" or "/dev/nst" device names for the tape drives. Maybe it
> would be better, in this case, to use "/dev/tape/by-path". Even better, to
> not have this physical multipath if you are not going to use it with the
> tape library...
>
> Hope this helps.
>
> Best regards,
> Ana
>
>
> On Tue, Aug 1, 2017 at 9:56 PM, Ana Emília M. Arruda <[hidden email]
> > wrote:
>
> > Hello Steve,
> >
> > Yes, it looks we have something here.
> >
> > From one of your previous emails, we have the error "3999 Device
> > "AutochangerOdin" not found or could not be opened." when Bacula issues the
> > label command for the tapes.
> >
> > This "not found or could not be opened" message usually refers to the
> > wrong "device name" configured for an "Archive Device" or "Changer Device".
> >
> > From another post, you have only one tape library with one tape drive, but
> > two paths for each of them:
> >
> >
> >
> > On Mon, Jul 31, 2017 at 5:22 PM, Steve Garcia <[hidden email]> wrote:
> >
> >>
> >> OK, now we may be getting somewhere -- at least I have a dump of
> >> messages...
> >>
> >> It does look like the problem is with the tape drive, but that's after it
> >> working fine at first.  It successfully opens the drive and determines
> >> (correctly) that the volume in the drive is an unlabeled tape.  As a
> >> result?  the tape drive is opened in a read-only state -- or maybe that's
> >> because it start by trying to read the existing label and you only need
> >> read-only for that.
> >>
> >> # sudo -u bacula -g tape /usr/sbin/bacula-sd -d200
> >> bacula-sd: address_conf.c:274-0 Initaddr 0.0.0.0:9103
> >> bacula-sd: stored_conf.c:698-0 Inserting Director res: sleipnir-mon
> >> root@odin:/etc/bacula# odin-sd: bsys.c:726-0 Could not open state file.
> >> sfd=-1 size=192: ERR=No such file or directory
> >> odin-sd: stored.c:572-0 calling init_dev /dev/tape/by-id/scsi-35000e111
> >> 64c42001-nst
> >> odin-sd: dev.c:342-0 init_dev: tape=1 dev_name=/dev/tape/by-id/scsi-
> >> 35000e11164c42001-nst
> >> odin-sd: stored.c:574-0 SD init done /dev/tape/by-id/scsi-35000e111
> >> 64c42001-nst
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set
> >> binbuf=24
> >> odin-sd: block_util.c:143-0 New block len=64512 block=7fe350002170
> >> odin-sd: bnet_server.c:86-0 Addresses 136.168.201.110:9103
> >> odin-sd: acquire.c:673-0 Attach 0x50001c68 to dev "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0
> >> odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: stored.c:588-0 calling first_open_device "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: device.c:279-0 start open_output_device()
> >> odin-sd: device.c:298-0 Opening device.
> >> odin-sd: tape_dev.c:958-0 Enter tape mount
> >> odin-sd: tape_dev.c:84-0 Open dev: device is tape
> >> odin-sd: autochanger.c:260-0 Return cached slot=1
> >> odin-sd: tape_dev.c:99-0 Try open "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> mode=OPEN_READ_ONLY
> >> odin-sd: tape_dev.c:121-0 Rewind after open
> >> odin-sd: os.c:58-0 In set_os_device_parameters
> >> odin-sd: os.c:64-0 Set block size to zero
> >> odin-sd: tape_dev.c:176-0 open dev: tape 5 opened
> >> odin-sd: dev.c:391-0 preserve=0x0 fd=5
> >> odin-sd: dev.c:394-0 open dev: fd=5 dev=7fe350001476 dcr=7fe350001098
> >> vol= type=2 dev_name="Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> mode=OPEN_READ_ONLY
> >> odin-sd: device.c:304-0 open dev "Drive-1" (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> OK
> >> odin-sd: label.c:72-0 Enter: int read_dev_volume_label(DCR*)
> >> odin-sd: label.c:75-0 Enter read_volume_label res=0 device="Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) vol= dev_Vol=*NULL*
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set
> >> binbuf=24
> >> odin-sd: label.c:126-0 Big if statement in read_volume_label
> >> odin-sd: block.c:458-0 Read() vol= nbytes=0 addr=-1
> >> odin-sd: block.c:487-0 block.c:480 The Volume= on device="Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
> >> odin-sd: block.c:493-0 ==== Read zero bytes. vol= at -1
> >> odin-sd: label.c:131-0 Requested Volume "" on tape device "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) is not a Bacula labeled
> >> Volume, because: ERR=block.c:480 The Volume= on device="Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst) appears to be unlabeled.
> >> odin-sd: label.c:160-0 No volume label - bailing out
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350002170 set
> >> binbuf=24
> >> odin-sd: label.c:251-0 return 3
> >> odin-sd: label.c:252-0 Leave: int read_dev_volume_label(DCR*)
> >> odin-sd: stored.c:613-0 Could not mount device "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
> >> odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:24
> >> odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge
> >> <1587823263.1501531104@odin-sd> ssl=0
> >> odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5
> >> <839623232.1501531104@sleipnir-dir> ssl=0
> >> odin-sd: cram-md5.c:157-0 sending resp to challenge:
> >> P7tmG2+KsR/8M7YfplspnD
> >> odin-sd: dircmd.c:204-0 Message channel init completed.
> >> odin-sd: dircmd.c:211-0 <dird: autochanger slots AutochangerOdin
> >>
> >> odin-sd: dircmd.c:225-0 Do command: autochanger
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:837-0 Found changer device Drive-1
> >> odin-sd: dircmd.c:850-0 Found device Drive-1
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe350012830 set
> >> binbuf=24
> >> odin-sd: block_util.c:143-0 New block len=64512 block=7fe350012830
> >> odin-sd: acquire.c:673-0 Attach 0x50012f38 to dev "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:670-0 <stored: slots=24
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
> >> odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:25
> >> odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge
> >> <1792316614.1501531105@odin-sd> ssl=0
> >> odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5
> >> <1290223807.1501531105@sleipnir-dir> ssl=0
> >> odin-sd: cram-md5.c:157-0 sending resp to challenge:
> >> u+RSe94jz4UptzNhM8+toC
> >> odin-sd: dircmd.c:204-0 Message channel init completed.
> >> odin-sd: dircmd.c:211-0 <dird: autochanger list AutochangerOdin
> >>
> >> odin-sd: dircmd.c:225-0 Do command: autochanger
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:837-0 Found changer device Drive-1
> >> odin-sd: dircmd.c:850-0 Found device Drive-1
> >> odin-sd: block_util.c:206-0 empty len=64512 block=7fe348001500 set
> >> binbuf=24
> >> odin-sd: block_util.c:143-0 New block len=64512 block=7fe348001500
> >> odin-sd: acquire.c:673-0 Attach 0x48000ff8 to dev "Drive-1"
> >> (/dev/tape/by-id/scsi-35000e11164c42001-nst)
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:278-0 Run program=/etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0
> >> odin-sd: autochanger.c:280-0 run_prog: /etc/bacula/scripts/mtx-changer
> >> /dev/tape/by-id/scsi-1IBM_3573-TL_00X2U78BZ022_LL0 loaded 0
> >> /dev/tape/by-id/scsi-35000e11164c42001-nst 0 stat=0 result=1
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: autochanger.c:322-0 Locking changer AutochangerOdin
> >> odin-sd: autochanger.c:657-0 <stored: 2:000018L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 3:000021L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 4:CLNU00L1
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 5:000014L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 6:000017L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 7:000020L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 8:CLN005L3
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 9:000013L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 10:000016L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 11:000019L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 12:000012L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 13:000009L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 14:000006L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 15:000003L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 16:000011L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 17:000008L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 18:000005L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 19:000002L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 20:000010L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 21:000007L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 22:000004L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 23:000001L6
> >>
> >> odin-sd: autochanger.c:657-0 <stored: 1:000015L6
> >>
> >>
> >> odin-sd: autochanger.c:336-0 Unlocking changer AutochangerOdin
> >> odin-sd: bnet.c:566-0 who=client host=136.168.201.100 port=9103
> >> odin-sd: dircmd.c:178-0 Got a DIR connection at 31-Jul-2017 12:58:35
> >> odin-sd: cram-md5.c:69-0 send: auth cram-md5 challenge
> >> <1434613563.1501531115@odin-sd> ssl=0
> >> odin-sd: cram-md5.c:133-0 cram-get received: auth cram-md5
> >> <734308377.1501531115@sleipnir-dir> ssl=0
> >> odin-sd: cram-md5.c:157-0 sending resp to challenge:
> >> GA/q4g/uIH/DvkJfC/+UwA
> >> odin-sd: dircmd.c:204-0 Message channel init completed.
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000015L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=1 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000018L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=2 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000021L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=3 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000014L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=5 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000017L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=6 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000020L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=7 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000013L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=9 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000016L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=10 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000019L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=11 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000012L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=12 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000009L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=13 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000006L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=14 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000003L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=15 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000011L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=16 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000008L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=17 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000005L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=18 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000002L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=19 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000010L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=20 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000007L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=21 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000004L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=22 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >> odin-sd: dircmd.c:211-0 <dird: label AutochangerOdin VolumeName=000001L6
> >> PoolName=OdinPool MediaType=LTO6 Slot=23 drive=0
> >> odin-sd: dircmd.c:225-0 Do command: label
> >> odin-sd: dircmd.c:817-0 Try changer device Drive-1
> >> odin-sd: dircmd.c:842-0 Device AutochangerOdin drive wrong: want=0 got=0
> >> skipping
> >>
> >>
> >>
> >> Steve Garcia
> >> Ignorance killed the cat, curiosity was framed.
> >>
> >> ---- "Ana Emília M. Arruda" <[hidden email]> wrote:
> >> > Hello Steve,
> >> >
> >> > Sorry, I sent an incomplete message.
> >> >
> >> > I think we will need to speak the same language here :-)
> >> >
> >> > You have your Director running at sleipnir host:
> >> >
> >> > root@sleipnir:/etc/bacula# bconsole
> >> > Connecting to Director sleipnir:9101
> >> > 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> >
> >> > with the Autochanger configuration on Director:
> >> >
> >> > From bacula-dir.conf on sleipnir (where the director is):
> >> > Storage {
> >> >   Name = Library2
> >> > # Do not use "localhost" here
> >> >   Address = odin                # N.B. Use a fully qualified name here
> >> >   SDPort = 9103
> >> >   Password = "*****************"
> >> >   Device = AutochangerOdin
> >> >   Media Type = LTO6
> >> >   Autochanger = yes                   # enable for autochanger device
> >> > }
> >> >
> >> > And you have your remote Storage Daemon installed in a host called
> >> > odin with the following configuration:
> >> >
> >> > From the bacula-sd.conf on odin (where the library is):
> >> > Autochanger {
> >> >   Name = AutochangerOdin
> >> >   Device = Drive-1
> >> >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
> >> >   Changer Device = /dev/autochanger1
> >> > }
> >> >
> >> > Device {
> >> >   Name = Drive-1                      #
> >> >   Description = "LT06 inside Dell TL2000 Library"
> >> >   Drive Index = 0
> >> >   Media Type = LT06
> >> >   Archive Device = /dev/nst0
> >> >   AutomaticMount = yes;               # when device opened, read it
> >> >   AlwaysOpen = yes;
> >> >   RemovableMedia = yes;
> >> >   RandomAccess = no;
> >> >   AutoChanger = yes
> >> >   SpoolDirectory = "/var/spool/bacula"
> >> >   MaximumSpoolSize = 485G
> >> >   Maximum Network Buffer Size = 65536
> >> >   Offline On Unmount = no
> >> >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> > }
> >> > This is perfect.
> >> >
> >> > You are right, the permission needs to be checked.
> >> >
> >> > If you have bacula-sd runnig as bacula user, the bacula user must be
> >> member
> >> > of tape group.
> >> >
> >> > Also, you can start the bacula-sd daemon in debug mode to get some debug
> >> > output and maybe help in this case. The following command should be run
> >> on
> >> > odin host:
> >> >
> >> > * sudo -u bacula -g tape /opt/ bacula/bin/bacula-sd -d200
> >> >
> >> > This will produce debug information on the Storage Daemon host and
> >> maybe we
> >> > can have more information about this problem.
> >> >
> >> > Best,
> >> > Ana
> >> >
> >> > On Mon, Jul 31, 2017 at 3:58 PM, Steve Garcia <[hidden email]>
> >> wrote:
> >> >
> >> > >
> >> > >
> >> > > ---- Darold Lucus <[hidden email]> wrote:
> >> > > > This is an example of my Autochanger listing in the bacula-sd.conf,
> >> this
> >> > > is
> >> > > > only a partial list but you would follow that format. My
> >> autochanger has
> >> > > 16
> >> > > > slots and a drive, the drive-1 is the writing drive.
> >> > > >
> >> > > > AutoChanger {
> >> > > >   Name = AutoChanger
> >> > > >   Device =  Drive-1, Drive-2, Drive-3, Drive-4, Drive-5, Drive-6,
> >> > > Drive-7,
> >> > > > Drive-8, Drive-9, Drive-10, Drive-11, Drive-12, Drive-13, Drive-14,
> >> > > > Drive-15, Drive-16, Drive-17
> >> > > >   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a
> >> %d"
> >> > > >   Changer Device = /dev/sg1
> >> > > > }
> >> > >
> >> > > So you're defining each slot as a drive, but only defining the actual
> >> > > drive as a device?
> >> > >
> >> > > >
> >> > > > Device {
> >> > > >   Name = Drive-1                      #
> >> > > >   Drive Index = 0
> >> > > >   Media Type = LTO5
> >> > > >   Archive Device = /dev/st0
> >> > > >   AutomaticMount = yes;               # when device opened, read it
> >> > > >   AlwaysOpen = yes;
> >> > > >   RemovableMedia = yes;
> >> > > >   RandomAccess = no;
> >> > > >   AutoChanger = yes
> >> > > >
> >> > > > }
> >> > > >
> >> > > > You also don't need this information in your storage section:
> >> > > >
> >> > > > Device = AutochangerOdin
> >> > > >   Media Type = LTO6
> >> > > >   Autochanger = yes                   # enable for autochanger
> >> device
> >> > >
> >> > > Well, I don't have those defined in the Storage resource of the
> >> > > bacula-sd.conf configuration (which is on the remote machine where the
> >> > > storage daemon lives) but I *do* have it in the Storage resource
> >> which is
> >> > > part of the bacula-dir.conf configuration.  The director gets quite
> >> cranky
> >> > > if you leave it out there.  :-)
> >> > >
> >> > >
> >> > >
> >> > >
> >> > > >
> >> > > > This is my example:
> >> > > >
> >> > > > Storage {                             # definition of myself
> >> > > >   Name = nas-sd
> >> > > >   SDPort = 9103                  # Director's port
> >> > > >   WorkingDirectory = "/var/lib/bacula"
> >> > > >   Pid Directory = "/var/run/bacula"
> >> > > >   Maximum Concurrent Jobs = 20
> >> > > >   SDAddress = IP.ADD.RE.SS
> >> > > > }
> >> > > >
> >> > > >
> >> > > > Hope this helps.
> >> > > >
> >> > > >
> >> > > >
> >> > > >
> >> > > > Sincerely,
> >> > > >
> >> > > > Darold Lucus
> >> > > >
> >> > > >
> >> > > > [image: cid:image002.png@01D06336.119F49E0] <
> >> http://www.emacinc.com/>
> >> > > >
> >> > > > =====================
> >> > > > LAN Administrator
> >> > > > EMAC, Inc
> >> > > > <a href="tel:618-529-4525%20EXT%3A370" value="+16185294525">618-529-4525 EXT:370
> >> > > > www.emacinc.com
> >> > > > =====================
> >> > > >
> >> > > >
> >> > > >
> >> > > > This message is confidential. It may also be privileged or otherwise
> >> > > > protected by work product immunity or other legal rules. If you have
> >> > > > received it by mistake, please let us know by e-mail reply and
> >> delete it
> >> > > > from your system; you may not copy this message or disclose its
> >> contents
> >> > > to
> >> > > > anyone.
> >> > > >
> >> > > > On Thu, Jul 27, 2017 at 4:00 PM, Ana Emília M. Arruda <
> >> > > > [hidden email]> wrote:
> >> > > >
> >> > > > > Hi Steve,
> >> > > > >
> >> > > > > Sorry, my mistake...
> >> > > > >
> >> > > > > There is no problem in having a remote Storage Daemon with your
> >> tape
> >> > > > > library attached. This is a very usual configuration.
> >> > > > >
> >> > > > > Before having a try with Bacula, I would recommend you to check
> >> if mtx
> >> > > and
> >> > > > > mt are properly working (please use /dev/tape/by-id names when
> >> running
> >> > > > > tests).
> >> > > > >
> >> > > > > The error messages seems related to the tape drive and not to the
> >> tape
> >> > > > > library configuration. So I would try "/dev/tape/by-id/scsi-
> >> > > 35000e11164c42001-nst"
> >> > > > > for the tape device:
> >> > > > >
> >> > > > > Device {
> >> > > > >   Name = Drive-1                      #
> >> > > > >   Description = "LT06 inside Dell TL2000 Library"
> >> > > > >   Drive Index = 0
> >> > > > >   Media Type = LT06
> >> > > > >   Archive Device = /dev/tape/by-id/scsi-35000e11164c42001-nst
> >> > > > >   AutomaticMount = yes;               # when device opened, read
> >> it
> >> > > > >   AlwaysOpen = yes;
> >> > > > >   RemovableMedia = yes;
> >> > > > >   RandomAccess = no;
> >> > > > >   AutoChanger = yes
> >> > > > >   SpoolDirectory = "/var/spool/bacula"
> >> > > > >   MaximumSpoolSize = 485G
> >> > > > >   Maximum Network Buffer Size = 65536
> >> > > > >   Offline On Unmount = no
> >> > > > >   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> > > > > }
> >> > > > >
> >> > > > > You should run btape tests before starting backups as well.
> >> > > > >
> >> > > > > Best regards,
> >> > > > >
> >> > > > > Ana
> >> > > > >
> >> > > > >
> >> > > > > On Wed, Jul 26, 2017 at 3:20 PM, Steve Garcia <[hidden email]
> >> >
> >> > > wrote:
> >> > > > >
> >> > > > >> OK, I've got my tape drive working (thanks Ana!) but I'm having
> >> > > trouble
> >> > > > >> connecting to the autochanger it's in using the director.  This
> >> is the
> >> > > > >> first time I've tried having a storage daemon on a different
> >> machine
> >> > > than
> >> > > > >> the director.  The director is a slightly lower version (7.4.3 on
> >> > > Debian
> >> > > > >> Jessie using backports) than the storage daemon (7.4.4 on
> >> stretch)
> >> > > but I
> >> > > > >> had understood that those versions were close enough to work.
> >> > > > >>
> >> > > > >> So I'm hoping this is another configuration issue.
> >> > > > >>
> >> > > > >> Right now what I'm trying to do is label all the tapes in the new
> >> > > library.
> >> > > > >>
> >> > > > >> When I try to access the new storage from the director, it is
> >> able to
> >> > > get
> >> > > > >> a listing of all the tapes, but it fails when it tries to
> >> actually do
> >> > > the
> >> > > > >> labeling.  I get a "3999 Device not found or could not be opened"
> >> > > error.
> >> > > > >> These errors show up quickly, there is no delay as it tries each
> >> > > slot, so
> >> > > > >> it's obviously not getting far enough to try.  But it *is*
> >> obviously
> >> > > > >> connecting to the remote storage, otherwise it wouldn't be able
> >> to
> >> > > obtain
> >> > > > >> the slot list.
> >> > > > >>
> >> > > > >> What am I missing?
> >> > > > >>
> >> > > > >> root@sleipnir:/etc/bacula# bconsole
> >> > > > >> Connecting to Director sleipnir:9101
> >> > > > >> 1000 OK: 102 sleipnir-dir Version: 7.4.3 (18 June 2016)
> >> > > > >> Enter a period to cancel a command.
> >> > > > >> *label storage=Library2 barcodes
> >> > > > >> Automatically selected Catalog: MyCatalog
> >> > > > >> Using Catalog "MyCatalog"
> >> > > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> > > > >> 3306 Issuing autochanger "slots" command.
> >> > > > >> Device "AutochangerOdin" has 24 slots.
> >> > > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> > > > >> 3306 Issuing autochanger "list" command.
> >> > > > >> The following Volumes will be labeled:
> >> > > > >> Slot  Volume
> >> > > > >> ==============
> >> > > > >>    1  000015L6
> >> > > > >>    2  000018L6
> >> > > > >>    3  000021L6
> >> > > > >>    4  CLNU00L1
> >> > > > >>    5  000014L6
> >> > > > >>    6  000017L6
> >> > > > >>    7  000020L6
> >> > > > >>    8  CLN005L3
> >> > > > >>    9  000013L6
> >> > > > >>   10  000016L6
> >> > > > >>   11  000019L6
> >> > > > >>   12  000012L6
> >> > > > >>   13  000009L6
> >> > > > >>   14  000006L6
> >> > > > >>   15  000003L6
> >> > > > >>   16  000011L6
> >> > > > >>   17  000008L6
> >> > > > >>   18  000005L6
> >> > > > >>   19  000002L6
> >> > > > >>   20  000010L6
> >> > > > >>   21  000007L6
> >> > > > >>   22  000004L6
> >> > > > >>   23  000001L6
> >> > > > >> Do you want to label these Volumes? (yes|no):  yes
> >> > > > >> Defined Pools:
> >> > > > >>      1: Default
> >> > > > >>      2: OdinPool
> >> > > > >> Select the Pool (1-2): 2
> >> > > > >> Connecting to Storage daemon Library2 at odin:9103 ...
> >> > > > >> Sending label command for Volume "000015L6" Slot 1 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000015L6.
> >> > > > >> Sending label command for Volume "000018L6" Slot 2 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000018L6.
> >> > > > >> Sending label command for Volume "000021L6" Slot 3 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000021L6.
> >> > > > >> Media record for Slot 4 Volume "CLNU00L1" already exists.
> >> > > > >> Sending label command for Volume "000014L6" Slot 5 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000014L6.
> >> > > > >> Sending label command for Volume "000017L6" Slot 6 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000017L6.
> >> > > > >> Sending label command for Volume "000020L6" Slot 7 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000020L6.
> >> > > > >> Media record for Slot 8 Volume "CLN005L3" already exists.
> >> > > > >> Sending label command for Volume "000013L6" Slot 9 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000013L6.
> >> > > > >> Sending label command for Volume "000016L6" Slot 10 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000016L6.
> >> > > > >> Sending label command for Volume "000019L6" Slot 11 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000019L6.
> >> > > > >> Sending label command for Volume "000012L6" Slot 12 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000012L6.
> >> > > > >> Sending label command for Volume "000009L6" Slot 13 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000009L6.
> >> > > > >> Sending label command for Volume "000006L6" Slot 14 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000006L6.
> >> > > > >> Sending label command for Volume "000003L6" Slot 15 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000003L6.
> >> > > > >> Sending label command for Volume "000011L6" Slot 16 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000011L6.
> >> > > > >> Sending label command for Volume "000008L6" Slot 17 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000008L6.
> >> > > > >> Sending label command for Volume "000005L6" Slot 18 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000005L6.
> >> > > > >> Sending label command for Volume "000002L6" Slot 19 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000002L6.
> >> > > > >> Sending label command for Volume "000010L6" Slot 20 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000010L6.
> >> > > > >> Sending label command for Volume "000007L6" Slot 21 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000007L6.
> >> > > > >> Sending label command for Volume "000004L6" Slot 22 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000004L6.
> >> > > > >> Sending label command for Volume "000001L6" Slot 23 ...
> >> > > > >> 3999 Device "AutochangerOdin" not found or could not be opened.
> >> > > > >> Label command failed for Volume 000001L6.
> >> > > > >> You have messages.
> >> > > > >> *
> >> > > > >>
> >> > > > >> From the bacula-sd.conf on odin (where the library is):
> >> > > > >> Autochanger {
> >> > > > >>   Name = AutochangerOdin
> >> > > > >>   Device = Drive-1
> >> > > > >>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S
> >> %a %d"
> >> > > > >>   Changer Device = /dev/autochanger1
> >> > > > >> }
> >> > > > >>
> >> > > > >> Device {
> >> > > > >>   Name = Drive-1                      #
> >> > > > >>   Description = "LT06 inside Dell TL2000 Library"
> >> > > > >>   Drive Index = 0
> >> > > > >>   Media Type = LT06
> >> > > > >>   Archive Device = /dev/nst0
> >> > > > >>   AutomaticMount = yes;               # when device opened, read
> >> it
> >> > > > >>   AlwaysOpen = yes;
> >> > > > >>   RemovableMedia = yes;
> >> > > > >>   RandomAccess = no;
> >> > > > >>   AutoChanger = yes
> >> > > > >>   SpoolDirectory = "/var/spool/bacula"
> >> > > > >>   MaximumSpoolSize = 485G
> >> > > > >>   Maximum Network Buffer Size = 65536
> >> > > > >>   Offline On Unmount = no
> >> > > > >>   Alert Command = "sh -c 'smartctl -H -l error %c'"
> >> > > > >> }
> >> > > > >>
> >> > > > >> From bacula-dir.conf on sleipnir (where the director is):
> >> > > > >> Storage {
> >> > > > >>   Name = Library2
> >> > > > >> # Do not use "localhost" here
> >> > > > >>   Address = odin                # N.B. Use a fully qualified
> >> name here
> >> > > > >>   SDPort = 9103
> >> > > > >>   Password = "*****************"
> >> > > > >>   Device = AutochangerOdin
> >> > > > >>   Media Type = LTO6
> >> > > > >>   Autochanger = yes                   # enable for autochanger
> >> device
> >> > > > >> }
> >> > > > >>
> >> > > > >> From the /dev directory on odin:
> >> > > > >> lrwxrwxrwx 1 root root 3     Jun  5 17:42 /dev/autochanger1 ->
> >> sg3
> >> > > > >> crw-rw---- 1 root tape 21, 3 Jun  1 15:01 /dev/sg3
> >> > > > >>
> >> > > > >>
> >> > > > >>
> >> > > > >> --
> >> > > > >> Steve Garcia
> >> > > > >> Ignorance killed the cat, curiosity was framed.
> >> > > > >>
> >> > > > >> ------------------------------------------------------------
> >> > > > >> ------------------
> >> > > > >> Check out the vibrant tech community on one of the world's most
> >> > > > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > > >> _______________________________________________
> >> > > > >> Bacula-users mailing list
> >> > > > >> [hidden email]
> >> > > > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> >> > > > >>
> >> > > > >
> >> > > > >
> >> > > > > ------------------------------------------------------------
> >> > > > > ------------------
> >> > > > > Check out the vibrant tech community on one of the world's most
> >> > > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > > > _______________________________________________
> >> > > > > Bacula-users mailing list
> >> > > > > [hidden email]
> >> > > > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> >> > > > >
> >> > > > >
> >> > >
> >> > >
> >>
> >>
> >



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/bacula-users
Loading...