mccntl(1M)


mccntl -- medium changer control

Synopsis

mccntl [-E] [-l element] [-e element] [-x element] [-d raw-device][-i] [-n] [-s] [-L] [-U] [-M] [-F] [-t device]

Description

mccntl sends the optional commands to the medium changer device driver sub-device /dev/mc/mc*.

Options

mccntl accepts the following options:

-E
Eject the currently loaded media. The media is returned to the slot it was loaded from. The functionality of this command is dependent on not using the changer's front panel controls for positioning or loading/unloading media. If the front panel controls are used, the driver will not be able to determine which slot the media was loaded from.

-l element
Load the media from element into the data drive.

-e element
Eject the media currently loaded in the data drive into the specified element.

-x element
Eject the media currently loaded in the data drive into the slot from which it was loaded, then load the media currently in the specified element into the data drive.

-d raw-device
Perform the requested operation on the medium changer raw-device. raw-device is the medium changer special device node, and defaults to /dev/mc/mc1 if not specified. There exists one device node in /dev/mc for each medium changer attached to the system.

-i
Initialize the medium changer status. This will cause the medium changer to check all elements for medium and any other status relevant to that element.

-n
Display the number of slots in the currently loaded magazine.

-s
Display the medium changer and data drive status.

-L
Disable removal of media via front panel controls.

-U
Allow removal of media via front panel controls.

-M
Dump the configuration status map. This will generate a colon-separated list describing the current configuration.

-F
Return to the first filled element. If the drive is loaded, this will unload the currently loaded cartridge to the currently positioned source element. Then the cartridge in the lowest numbered source element that contains a cartridge will be loaded.

-t device
Since a single medium changer can service many devices within a library, this option provides a way to direct a medium changer operation to a particular device. The medium changer is to perform the requested operation to the device specified. The device is the numeric sequence of a drive within a library and defaults to 1 if not specified. For example:
   mccntl -d /dev/mc/mc2 -l 3 -t 2
This command instructs the changer /dev/mc/mc2 to load the medium from storage slot 3 onto the second device in the library.

Exit codes

Exit codes and their meanings are as follows:


exit(1)
Invalid command syntax.

exit(2)
Device failed to open properly.

exit(3)
Unable to determine the number of slots in the currently loaded magazine.

exit(4)
Unable to allocate required memory to complete the requested command.

exit(5)
Unable to obtain device status.

exit(6)
Unable to extract device configuration map.

exit(7)
Data drive is empty, and a request was made to remove media from the drive.

exit(8)
The source element in a move request was empty.

exit(9)
Unable to determine the source element used to load the data drive.

exit(10)
Destination element is full in a move request.

exit(11)
The MC_EXCHANGE command failed.

exit(12)
The MC_MOVE_MEDIUM command failed.

exit(13)
The data transfer element is full, and a request to load the element was made.

exit(14)
The MC_POSITION command failed.

exit(15)
The MC_INIT_STATUS command failed.

exit(16)
The MC_PREVMR command failed.

exit(17)
The MC_ALLOWMR command failed.

Files

/dev/mc/mc*

References

mc01(7)
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004