Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-14 Thread Andreas Helmcke
On 14.05.2007 09:40, Adam Cécile wrote:
> All weeks I need to unload all tapes from drives to the library, so all
> tapes can be removed from the Autochanger easily.
> However, when I do "umount", device is marked as BLOCKED and no more
> jobs run until I mount the drive again.
> What's the right way to eject all tapes without blocking drives ?
> 

I don't know if it's the "right way" but what I do is a mount with an
non existing slot e.g. slot 0 after an unmount.
Afterwards the tape will be used again by bacula.

Andreas


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-14 Thread Adam Cécile
Andreas Helmcke a écrit :
> On 14.05.2007 09:40, Adam Cécile wrote:
>   
>> All weeks I need to unload all tapes from drives to the library, so all
>> tapes can be removed from the Autochanger easily.
>> However, when I do "umount", device is marked as BLOCKED and no more
>> jobs run until I mount the drive again.
>> What's the right way to eject all tapes without blocking drives ?
>>
>> 
>
> I don't know if it's the "right way" but what I do is a mount with an
> non existing slot e.g. slot 0 after an unmount.
> Afterwards the tape will be used again by bacula.
>
> Andreas
>   
Yes, it's what I'm doing right now (in fact I just type mount, and as
there's no more tape loaded in the drive, mount fails, but bacula
unblock the drive).

However I really would find something like "Blocked On Umount = No"
directive.
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
>   


-- 
Adam CECILELinbox / Free&ALter Soft
152 rue de Grigy   tél: +33 3 87 50 87 95
Technopôle Metz 2000   fax: +33 3 87 75 19 26   
57070 METZ - Francehttp://www.linbox.com


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-15 Thread Thomas Eszlinger
Hello Adam,

I'm having an "Always Open = No" and an "Automount = yes" in my 
bacula-sd.conf so when bacula needs a tape he automatically mounts the 
right slot and gives it back when its not needed anymore.
With this I have no need to umount the drive from the bacula-console to 
change my tapes in the library.

Thomas

Adam Cécile schrieb:
> Andreas Helmcke a écrit :
>> On 14.05.2007 09:40, Adam Cécile wrote:
>>   
>>> All weeks I need to unload all tapes from drives to the library, so all
>>> tapes can be removed from the Autochanger easily.
>>> However, when I do "umount", device is marked as BLOCKED and no more
>>> jobs run until I mount the drive again.
>>> What's the right way to eject all tapes without blocking drives ?
>>>
>>> 
>> I don't know if it's the "right way" but what I do is a mount with an
>> non existing slot e.g. slot 0 after an unmount.
>> Afterwards the tape will be used again by bacula.
>>
>> Andreas
>>   
> Yes, it's what I'm doing right now (in fact I just type mount, and as
> there's no more tape loaded in the drive, mount fails, but bacula
> unblock the drive).
> 
> However I really would find something like "Blocked On Umount = No"
> directive.
>> -
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Bacula-users mailing list
>> Bacula-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/bacula-users
>>   
> 
> 

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-18 Thread Troy Daniels
You didn't mention which version of bacula you are running but I know 
2.0.2 has a 'release' command that releases the tape and bacula knows to 
check the drive before trying to access it the next time.

Not sure what version it was introduced in however.

Troy.

Adam Cécile wrote:
> Hi,
> 
> All weeks I need to unload all tapes from drives to the library, so all
> tapes can be removed from the Autochanger easily.
> However, when I do "umount", device is marked as BLOCKED and no more
> jobs run until I mount the drive again.
> What's the right way to eject all tapes without blocking drives ?
> 
> Thanks in advance.
> 
> 
> # bacula-dir.conf
> # Autochanger Dell PV132T (21x LTO3)
> Storage {
>   Name = Autochanger
>   Address = srv-mpp-lrs
>   SDPort = 9103
>   Password = "ZK9nC86vuFvW80l28xQ3jaKtEJt89jXM3R31VjdZl"
>   Device = Dell-PV132T
>   Media Type = LTO3
>   Autochanger = yes
>   Maximum Concurrent Jobs = 2
> }
> 
> # bacula-sd.conf
> # An autochanger device with two drives
> Autochanger {
>   Name = Dell-PV132T
>   Device = ULTRIUM-TD3-1
>   Device = ULTRIUM-TD3-2
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/sg2
> }
> Device {
>   Name = ULTRIUM-TD3-1
>   Drive Index = 0
>   Media Type = LTO3
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;   # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   Offline On Unmount = no;
>   #RandomAccess = no;
>   AutoChanger = yes
>   # Enable the Alert command only if you have the mtx package loaded
>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }
> Device {
>   Name = ULTRIUM-TD3-2
>   Drive Index = 1
>   Media Type = LTO3
>   Archive Device = /dev/nst1
>   AutomaticMount = yes;   # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   Offline On Unmount = no;
>   #RandomAccess = no;
>   AutoChanger = yes
>   # Enable the Alert command only if you have the mtx package loaded
>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }
> 


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-18 Thread Troy Daniels
Forgot to mention that in the older 1.38.x version of Bacula I used 
'update slots' to trigger an unload of the tape. We were then able to 
use the controls on the front of the autochanger to swap tapes in the 
unit with new ones.

I only have 8 slots in my autochanger so it doesn't take long to update 
them.

However, the new 2.x version of Bacula, 'update slots' no longer unloads 
the tape.

Cheers,


Troy.

Troy Daniels wrote:
> You didn't mention which version of bacula you are running but I know 
> 2.0.2 has a 'release' command that releases the tape and bacula knows to 
> check the drive before trying to access it the next time.
> 
> Not sure what version it was introduced in however.
> 
> Troy.
> 
> Adam Cécile wrote:
>> Hi,
>>
>> All weeks I need to unload all tapes from drives to the library, so all
>> tapes can be removed from the Autochanger easily.
>> However, when I do "umount", device is marked as BLOCKED and no more
>> jobs run until I mount the drive again.
>> What's the right way to eject all tapes without blocking drives ?
>>
>> Thanks in advance.
>>
>>
>> # bacula-dir.conf
>> # Autochanger Dell PV132T (21x LTO3)
>> Storage {
>>   Name = Autochanger
>>   Address = srv-mpp-lrs
>>   SDPort = 9103
>>   Password = "ZK9nC86vuFvW80l28xQ3jaKtEJt89jXM3R31VjdZl"
>>   Device = Dell-PV132T
>>   Media Type = LTO3
>>   Autochanger = yes
>>   Maximum Concurrent Jobs = 2
>> }
>>
>> # bacula-sd.conf
>> # An autochanger device with two drives
>> Autochanger {
>>   Name = Dell-PV132T
>>   Device = ULTRIUM-TD3-1
>>   Device = ULTRIUM-TD3-2
>>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>>   Changer Device = /dev/sg2
>> }
>> Device {
>>   Name = ULTRIUM-TD3-1
>>   Drive Index = 0
>>   Media Type = LTO3
>>   Archive Device = /dev/nst0
>>   AutomaticMount = yes;   # when device opened, read it
>>   AlwaysOpen = yes;
>>   RemovableMedia = yes;
>>   Offline On Unmount = no;
>>   #RandomAccess = no;
>>   AutoChanger = yes
>>   # Enable the Alert command only if you have the mtx package loaded
>>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
>> }
>> Device {
>>   Name = ULTRIUM-TD3-2
>>   Drive Index = 1
>>   Media Type = LTO3
>>   Archive Device = /dev/nst1
>>   AutomaticMount = yes;   # when device opened, read it
>>   AlwaysOpen = yes;
>>   RemovableMedia = yes;
>>   Offline On Unmount = no;
>>   #RandomAccess = no;
>>   AutoChanger = yes
>>   # Enable the Alert command only if you have the mtx package loaded
>>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
>> }
>>
> 
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-18 Thread Thomas Sturm
Hello Adam,
that is what I do:

I have an admin-Job:
Job {
  Name = "unload_tape"
  Type = admin
  Client = bacula-fd
  JobDefs = "backup"
  FileSet="Catalog"
  RunBeforeJob = "/usr/libexec/bacula/unload_tape"
  Schedule = "nachts"
  Priority = 99  # 
}

/usr/libexec/bacula/unload_tape:
#!/bin/bash
/usr/sbin/bconsole -c /etc/bacula/bconsole.conf < Hi,
>
> All weeks I need to unload all tapes from drives to the library, so all
> tapes can be removed from the Autochanger easily.
> However, when I do "umount", device is marked as BLOCKED and no more
> jobs run until I mount the drive again.
> What's the right way to eject all tapes without blocking drives ?
>
> Thanks in advance.
>
>
> # bacula-dir.conf
> # Autochanger Dell PV132T (21x LTO3)
> Storage {
>   Name = Autochanger
>   Address = srv-mpp-lrs
>   SDPort = 9103
>   Password = "ZK9nC86vuFvW80l28xQ3jaKtEJt89jXM3R31VjdZl"
>   Device = Dell-PV132T
>   Media Type = LTO3
>   Autochanger = yes
>   Maximum Concurrent Jobs = 2
> }
>
> # bacula-sd.conf
> # An autochanger device with two drives
> Autochanger {
>   Name = Dell-PV132T
>   Device = ULTRIUM-TD3-1
>   Device = ULTRIUM-TD3-2
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/sg2
> }
> Device {
>   Name = ULTRIUM-TD3-1
>   Drive Index = 0
>   Media Type = LTO3
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;   # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   Offline On Unmount = no;
>   #RandomAccess = no;
>   AutoChanger = yes
>   # Enable the Alert command only if you have the mtx package loaded
>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }
> Device {
>   Name = ULTRIUM-TD3-2
>   Drive Index = 1
>   Media Type = LTO3
>   Archive Device = /dev/nst1
>   AutomaticMount = yes;   # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   Offline On Unmount = no;
>   #RandomAccess = no;
>   AutoChanger = yes
>   # Enable the Alert command only if you have the mtx package loaded
>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-18 Thread Adam Cécile
Hi,

Thanks for you reply. I made my own script based on yours and I added
stuff to set inchanger flag to no for all volumes.

Here is the script :

#!/bin/sh
/usr/bin/bconsole -c /etc/bacula/bconsole.conf <> ${temp}
done
cat ${temp} | bconsole -c /etc/bacula/bconsole.conf
rm ${temp}

And bacula-dir.conf :
Job {
  Name = "Eject-tapes"
  Type = admin
  Client = srv-mpp-lrs-fd
  Messages = Standard
  Storage = Autochanger
  Pool = Weekly, Daily
  FileSet = "Dummy"
  RunBeforeJob = "/etc/bacula/scripts/eject_tapes"
  Priority = 99
}
FileSet {
  Name = "Dummy"
}

It seems to do the job for now !


Thomas Sturm a écrit :
> Hello Adam,
> that is what I do:
>
> I have an admin-Job:
> Job {
>   Name = "unload_tape"
>   Type = admin
>   Client = bacula-fd
>   JobDefs = "backup"
>   FileSet="Catalog"
>   RunBeforeJob = "/usr/libexec/bacula/unload_tape"
>   Schedule = "nachts"
>   Priority = 99  # 
> }
>
> /usr/libexec/bacula/unload_tape:
> #!/bin/bash
> /usr/sbin/bconsole -c /etc/bacula/bconsole.conf < unmount storage=DLT-S4
> unmount storage=X
> unmount storage=Y
> END_OF_DATA
>
> sleep 120
>
> /usr/sbin/bconsole -c /etc/bacula/bconsole.conf < mount storage=DLT-S4
> mount storage=X
> mount storage=Y
> END_OF_DATA
>
> In the morning, I only have to collect the tapes from the library   :-)
>
> regards
> Thomas
>
> Am Montag, 14. Mai 2007 09:40 schrieb Adam Cécile:
>   
>> Hi,
>>
>> All weeks I need to unload all tapes from drives to the library, so all
>> tapes can be removed from the Autochanger easily.
>> However, when I do "umount", device is marked as BLOCKED and no more
>> jobs run until I mount the drive again.
>> What's the right way to eject all tapes without blocking drives ?
>>
>> Thanks in advance.
>>
>>
>> # bacula-dir.conf
>> # Autochanger Dell PV132T (21x LTO3)
>> Storage {
>>   Name = Autochanger
>>   Address = srv-mpp-lrs
>>   SDPort = 9103
>>   Password = "ZK9nC86vuFvW80l28xQ3jaKtEJt89jXM3R31VjdZl"
>>   Device = Dell-PV132T
>>   Media Type = LTO3
>>   Autochanger = yes
>>   Maximum Concurrent Jobs = 2
>> }
>>
>> # bacula-sd.conf
>> # An autochanger device with two drives
>> Autochanger {
>>   Name = Dell-PV132T
>>   Device = ULTRIUM-TD3-1
>>   Device = ULTRIUM-TD3-2
>>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>>   Changer Device = /dev/sg2
>> }
>> Device {
>>   Name = ULTRIUM-TD3-1
>>   Drive Index = 0
>>   Media Type = LTO3
>>   Archive Device = /dev/nst0
>>   AutomaticMount = yes;   # when device opened, read it
>>   AlwaysOpen = yes;
>>   RemovableMedia = yes;
>>   Offline On Unmount = no;
>>   #RandomAccess = no;
>>   AutoChanger = yes
>>   # Enable the Alert command only if you have the mtx package loaded
>>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
>> }
>> Device {
>>   Name = ULTRIUM-TD3-2
>>   Drive Index = 1
>>   Media Type = LTO3
>>   Archive Device = /dev/nst1
>>   AutomaticMount = yes;   # when device opened, read it
>>   AlwaysOpen = yes;
>>   RemovableMedia = yes;
>>   Offline On Unmount = no;
>>   #RandomAccess = no;
>>   AutoChanger = yes
>>   # Enable the Alert command only if you have the mtx package loaded
>>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
>> }
>> 


-- 
Adam CECILELinbox / Free&ALter Soft
152 rue de Grigy   tél: +33 3 87 50 87 95
Technopôle Metz 2000   fax: +33 3 87 75 19 26   
57070 METZ - Francehttp://www.linbox.com


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] How to unload all loaded tapes to library ?

2007-05-23 Thread Thomas Sturm
Hello Adam,
that is what I do:

I have an admin-Job:
Job {
  Name = "unload_tape"
  Type = admin
  Client = bacula-fd
  JobDefs = "backup"
  FileSet="Catalog"
  RunBeforeJob = "/usr/libexec/bacula/unload_tape"
  Schedule = "nachts"
  Priority = 99  # 
}

/usr/libexec/bacula/unload_tape:
#!/bin/bash
/usr/sbin/bconsole -c /etc/bacula/bconsole.conf < Hi,
>
> All weeks I need to unload all tapes from drives to the library, so all
> tapes can be removed from the Autochanger easily.
> However, when I do "umount", device is marked as BLOCKED and no more
> jobs run until I mount the drive again.
> What's the right way to eject all tapes without blocking drives ?
>
> Thanks in advance.
>
>
> # bacula-dir.conf
> # Autochanger Dell PV132T (21x LTO3)
> Storage {
>   Name = Autochanger
>   Address = srv-mpp-lrs
>   SDPort = 9103
>   Password = "ZK9nC86vuFvW80l28xQ3jaKtEJt89jXM3R31VjdZl"
>   Device = Dell-PV132T
>   Media Type = LTO3
>   Autochanger = yes
>   Maximum Concurrent Jobs = 2
> }
>
> # bacula-sd.conf
> # An autochanger device with two drives
> Autochanger {
>   Name = Dell-PV132T
>   Device = ULTRIUM-TD3-1
>   Device = ULTRIUM-TD3-2
>   Changer Command = "/etc/bacula/scripts/mtx-changer %c %o %S %a %d"
>   Changer Device = /dev/sg2
> }
> Device {
>   Name = ULTRIUM-TD3-1
>   Drive Index = 0
>   Media Type = LTO3
>   Archive Device = /dev/nst0
>   AutomaticMount = yes;   # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   Offline On Unmount = no;
>   #RandomAccess = no;
>   AutoChanger = yes
>   # Enable the Alert command only if you have the mtx package loaded
>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }
> Device {
>   Name = ULTRIUM-TD3-2
>   Drive Index = 1
>   Media Type = LTO3
>   Archive Device = /dev/nst1
>   AutomaticMount = yes;   # when device opened, read it
>   AlwaysOpen = yes;
>   RemovableMedia = yes;
>   Offline On Unmount = no;
>   #RandomAccess = no;
>   AutoChanger = yes
>   # Enable the Alert command only if you have the mtx package loaded
>   # Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }

-- 
Mit freundlichen Grüßen

i.A. Thomas Sturm 
  EDV Abteilung 

Melle Dachbaustoffe GmbH
An der Unteren Söse 36
37520 Osterode

Telefon 05522 967-160
Fax 05522 967-149
eMail   [EMAIL PROTECTED]

Melle Dachbaustoffe GmbH, Registergericht Göttingen, HRB 130676
Sitz der Gesellschaft Osterode am Harz, Ust-ID-Nummer DE115896425
Geschäftsführer: Joel Bravard, Christopher J. Davies, Frank Engelmann
Geschäftsführer: Ralf Gehrke, Manfred Marks

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users