Chg-scsi-chio

From The Open Source Backup Wiki (Amanda, MySQL Backup, BackupPC)
Jump to navigationJump to search
Deprecated
This changer is deprecated; see amanda-changers(7)


A C program that relies on scsi tape-changer interfaces. It may either use the tape changer interface specified in chio.h (Gerd Knor's SCSI media changer driver, a Linux kernel loadable module), or it may use built-in tape changer interfaces available on HPUX, Solaris 2.5, IRIX and possibly others, but only the chio and HPUX interfaces are currently implemented . `tapedev' specifies the tape device to be used; `changer_dev' is the device used to talk to the kernel module (for chio, usually /dev/ch0), and `changerfile' specifies a filename in which the current slot number will be stored.

Now there is another way, to get the chg-scsi a little bit more flexible. If you use only one digit in the `tapedev' parameter, the chg-scsi expects that changerfile points to a real configuration file, not only a counting file. In this configuration file you may specify that the tapedrive needs an eject command and an optional waittime, necessary after inserting the tape into the drive. You are also able to configure a range of slots which should be used by your configuration. The idea behind this is, that you don't want AMANDA to cycle all the tapes if AMANDA searches exactly one tape. If you have a library which supports more than one drive you can also specify which drive to use. For each configuration (there should be at least one) you have to specify a file, where AMANDA remembers which tape is actually in the drive. For future use there is also some stuff for cleaning the drives.

In amanda.conf:

tapedev "x"       with x between 0 and 9, selects the configuration to use
changerfile "filename"            specifies the changer configuration file


In the changer-config-file the following could be set:

number_configs x
#	x between 0 and 9 	number of configurations defined. This should be the first parameter in the config-file.
eject	x
#	x 0 or 1		1 means that the drives need an eject command, before the robot can handle the tape.
sleep	x
#	x between 0 and MAX_INT specifies the seconds to wait before the drive could be used after inserting a tape. 5 should be OK.
cleanmax x	
#	x some positive int	How many cleanings does a cleaning tape survive
changerdev  <device>
#				The device for the robot

And then there come some configuration sections, separated by the word `config` followed by the ordinal of that configuration (0 to 9). In each configuration section you should specify:

drivenum x		x between 0 and the number of drives in the library
This one specifies the drive to use with this configuration
dev	<device>				The device for the tapedrive
startuse    x		x between 0 and maximum slotnumber of your library
Starting here we may use the tapes
enduse	 x		x between start and maximum slotnumber
This is the last tape we may use in this configuration. If we reach this one the next will be start..
statfile <filename>				Here we remember the last used
slot for this configuration
cleancart	x	x between 0 and maximum slotnumber 
In this slot we find the cleaning tape
cleanfile <filename>				
Here we will remember how often we used the cleaning tape
usagecount <filename>				This points to a file which is deleted after cleaning the drive
                                               e.g. the usagetime of the drive

Comments begin with an '#' until end of line. Allowed separators are TAB and SPACE.