Operating System - HP-UX
1844090 Members
2530 Online
110227 Solutions
New Discussion

how to use mc command to control 1/8 autoloader

 
hugozhou
New Member

how to use mc command to control 1/8 autoloader

I have 1/8 Ultrium Autoloader which connected with rp4440. Does mc support this type autolader? How can I use mc to control it to load/unload and select cartridge?
7 REPLIES 7
Alexander M. Ermes
Honored Contributor

Re: how to use mc command to control 1/8 autoloader

Hi there.
These commands might help you :

mc -p /dev/changer -r S ( shows empty slots )
mc -p /dev/changer -sS1 -dD1
transports tape from slot 1 to drive 1

mt-t /dev/rmt/drive rew
rewinds the tape

mt-t /dev/rmt/drive offline
takes the drive offline, so that you can take the tape out also called unmount tape.

mc -p /dev/changer -sD1 -dS1 transports the tape from drive 1 to slot 1.
Hope i could help.
Rgds
Alexander M. Ermes
.. and all these memories are going to vanish like tears in the rain! final words from Rutger Hauer in "Blade Runner"
Indira Aramandla
Honored Contributor

Re: how to use mc command to control 1/8 autoloader

Hi,

This is how you use mc (media changer manipulation utility) to move a media between tape drives and tape library slots.

For Eg:-
To move tape from slot to tape drive use like this
/usr/sbin/mc -p /dev/picker -s S$SNUM -d D$TNUM;
where /dev/picker is the robotic arm and SNUM is the slot number and TNUM is the Drive number.
To move tape from slot to mail-slot
/usr/sbin/mc -p /dev/picker -s S$SNUM -d I1;
Where SNUM is the slot number and I1 is the mail-slot or the cap.

See man mc for more details.


IA
Never give up, Keep Trying
hugozhou
New Member

Re: how to use mc command to control 1/8 autoloader

thanks for your kindly reply.

but it does not work

# mc -p /dev/changer -r S
ERROR: No such file or directory

# mt -t /dev/rmt/c12t5d0BESTnb offline
/dev/rmt/c12t5d0BESTnb: No such device or address
# mt -t /dev/rmt/c12t5d0BEST offline
/dev/rmt/c12t5d0BEST: No such device or address

# ioscan -fnC tape
Class I H/W Path Driver S/W State H/W Type Description
=====================================================================
tape 0 0/5/1/0.5.0 stape CLAIMED DEVICE HP Ultrium 1-SCSI
/dev/rmt/0m /dev/rmt/c12t5d0BEST
/dev/rmt/0mb /dev/rmt/c12t5d0BESTb
/dev/rmt/0mn /dev/rmt/c12t5d0BESTn
/dev/rmt/0mnb /dev/rmt/c12t5d0BESTnb

what is wrong?
Indira Aramandla
Honored Contributor

Re: how to use mc command to control 1/8 autoloader

Hi,

After you had connected the Ultrium Autoloader to the server rp4440,
Did you do an ioscan (ioscan â fnC) to see that the hardware part is claimed,

Then did you do the insf -e to install special device files.

When you do ll /dev/changer is the device file there.

IA
Never give up, Keep Trying
Bob_Vance
Esteemed Contributor

Re: how to use mc command to control 1/8 autoloader

As said,

# ioscan
# insf -e
# ioscan -fn

Look in /dev/rac for the changer device.

in the 'ioscan -fn', look for "tape" and you should see something like:
... ...
... target 15 0/2/1/0.1.6.255.0.0 tgt CLAIMED DEVICE
... autoch 1 0/2/1/0.1.6.255.0.0.0 schgr CLAIMED DEVICE COMPAQ MSL
........... /dev/rac/c8t0d0
... tape 1 0/2/1/0.1.6.255.0.0.1 stape CLAIMED DEVICE HP Ultrium 1-SCSI
........... /dev/rmt/0m


The "autoch" class and driver "schgr" are what you're looking for. Be sure that the S/W State (software state) is "CLAIMED". If not go into SAM/Kernel/Drivers and add "schgr" driver to kernel.

The default device that 'mc' uses is /dev/scsi/3. I often create a link for that to the actual device and then I don't need the "-p" option on the 'mc' command:

# mkdir /dev/scsi
# ln -s /dev/rac/c8t0d0 /dev/scsi/3
# mc -r DIMS
### which would be equivalent to
# mc -r -p /dev/rac/c8t0d0 DIMS


hth
bv
"The lyf so short, the craft so long to lerne." - Chaucer
Sanjay_6
Honored Contributor

Re: how to use mc command to control 1/8 autoloader

Hi,

You may need the "schgr" device driver configured into the kernel to manipulate the SCSI autoloader.

Here is a link on how to use the "mc" command.

When you have enabled the "schgr" driver in the kernel (& rebooted), you should see the /dev/rac device which is the robotic arm for the autoloader. You use this to move the media from the slot to the drive and vice versa.

Hope this helps.

Regds
Bill Hassell
Honored Contributor

Re: how to use mc command to control 1/8 autoloader

You definitely need schgr in the kernel. The nature of the autochanger (the robotic arm) makes it hard to know that the driver is missing. The mc command is also very difficult to use as a diagnostic. It assumes that the variable $LIBRARY has been set to a working device file for the robotic arm. Otherwise, you must use -p but in either case, the kernel must first hae the schgr driver and rebooted with the autoloader attached. Verify that there is an autochanger device:

ioscan -knfC autoch

It should look something like this:

Class I H/W Path Driver S/W State H/W Type Description
=====================================================================
autoch 0 0/2/0/0.0.0 schgr CLAIMED DEVICE HP C7200-8000
/dev/rac/c4t0d0

The device file /dev/rac/c4t0d0 is the robotic arm. Once you see something like the above, then do a quick status:

mc -p /dev/rac/c4t0d0 -r ISDN

That will show all the slots, the tape drives, mailslots, etc. mc will not function until the robotic arm has a correct device file.


Bill Hassell, sysadmin