Showing posts with label Devices. Show all posts
Showing posts with label Devices. Show all posts

Tuesday, June 23, 2015

RHEL 6.6, non IBM devices and UDEV rules

Few days back we had to move one of our TSM servers and its library - which is a shared one. Did it before with TSM version 5.x and everything was fine that day. Now we are on the 7.1 and I have found that even the SANDISCOVERY found the new path correctly (and updated it on the Library Manager), drives were not working.
TSM 6.x+ server does not run under "root" account anymore, but when the new device is discovered, its device file is created as RW for root only.
Normaly (when you manually add the new device) you update the device files privileges and create the links using "/opt/tivoli/tsm/devices/bin/autoconf -a", but this does not work automatically.

On the TSM Symposium 2013 in Berlin there was a great presentation "Tape configuration for TSM" by Bruno Friess which (among other things) solves this situation by using persistent names via "udev".
http://www.exstor.de/wp-content/uploads/2013/09/tape_config_for_tsm.pdf
 
It only has a 2 minor limitations
a) Linux variant mentioned is SLES
b) lacks details for Linux, udev and non-IBM devices

As our Linux servers run on RHEL amd our libraries are Overland brand with HP tape drives, I had to modify the steps a bit:
a) udevadm info .... does not display serial numbers for HP tape drives and Overland libraries - you need sg3_utils package for having "sginfo" command to get the device serial numbers
b) links are created as /dev/library1 and /dev/drive1 (2, 3) pointing to corresponding /dev/sgX device with crw-rw-rw permissions
c) file below was created as /etc/udev/rules.d/71-persistent-tape.rules
# This file shoud create persistent devices for HP tapes and libraries used by TSM

# Known serial numbers
# <library1>    LIBRSN1234
# <drive1>      DRV1SN3456
# <drive2>      DRV2SN4567
# <drive3>      DRV3SN5678

KERNEL=="sg*", SUBSYSTEM=="scsi_generic", SYSFS{type}=="8", PROGRAM="/usr/bin/sginfo -s /dev/%k", RESULT=="*LIBRSN1234*", SYMLINK+="library1",MODE="0666"
KERNEL=="sg*", SUBSYSTEM=="scsi_generic", PROGRAM="/usr/bin/sginfo -s /dev/%k", RESULT=="*DRV1SN3456*", SYMLINK+="drive1",MODE="0666"
KERNEL=="sg*", SUBSYSTEM=="scsi_generic", PROGRAM="/usr/bin/sginfo -s /dev/%k", RESULT=="*DRV2SN4567*", SYMLINK+="drive2",MODE="0666"
KERNEL=="sg*", SUBSYSTEM=="scsi_generic", PROGRAM="/usr/bin/sginfo -s /dev/%k", RESULT=="*DRV3SN5678*", SYMLINK+="drive3",MODE="0666"
Many thanks to Bruno and hope this helps someone.

Thursday, January 19, 2012

TSM Device Handling in Windows

I have to say that TSM on Windows is good for small to medium size solutions and I'm not ANTI-Windows. I just cringe when dealing with devices in Windows. I hate its driver handling and most of all I hate how Windows presents library and tape drives. So I was working with a TSM server where the tape library would not initialize. It was an older SCSI library, not Fiber. I tried restarting the library, the TSM server, reloading drivers, and updating the drivers and nothing worked.

Duh! <Head Slap!!!>

That's because on the initial reboot that caused the library to stop communicating the device ID's changed. So the library went from LB1.0.0.2 to LB1.0.0.3. Nobody touched the SCSI card or library but the device definition changed! Seriously?  All the drives changed to mtX.X.X.3 also. Now I don't use Windows all that much but luckily I remembered the TSMDLST program that is installed with the TSM server. It's under C:\Porgram Files\tivoli\tsm\console and will pull the information from Windows for you in a readable format. So next time your library goes offline make sure you use it to compare the device definitions and serials with what is defined in TSM. It will save you a lot of time and headache. You can find more information on issues like this here.

Wednesday, October 24, 2007

NetApp Drive Definitions

I always forget the NetApp drive definitions so i thought I would post the example I found here so I can recall it later. If any of you wondered which definition TSM uses or would like to know why here is your answer:


rst4l - rewind device, format is: H Format 30 GB
nrst4l - no rewind device, format is: H Format 30 GB
urst4l - unload/reload device, format is: H Format 30 GB
rst4m - rewind device, format is: H Format 30 GB
nrst4m - no rewind device, format is: H Format 30 GB
urst4m - unload/reload device, format is: H Format 30 GB
rst4h - rewind device, format is: H Format 30 GB
nrst4h - no rewind device, format is: H Format 30 GB
urst4h - unload/reload device, format is: H Format 30 GB
rst4a - rewind device, format is: H Format 60 GB comp
nrst4a - no rewind device, format is: H Format 60 GB comp
urst4a - unload/reload device, format is: H Format 60 GB comp

The one is red is the definition TSM uses since it rewinds the tape, but leaves the unload/reload to TSM and not the device itself.