TivoliStorageManager: Difference between revisions

From OACISS Systems Wiki
Jump to navigation Jump to search
No edit summary
 
Line 1: Line 1:
 
#REDIRECT [[Service:Tivoli Storage Manager]]
== Intro ==
 
=== Purpose ===
 
Tivoli Storage Manager(TSM) is used to backup all user home dirs to an LTO2 tape library.
 
=== Reason for choosing ===
 
Downloaded for free from IBM Scholars Program.
 
== Setup ==
 
=== Installation ===
 
==== Server ====
 
Installed TSM server.
 
<pre>
mkdir /root/tsm
cd /root/tsm
mkdir linux_server
cd linux_server
</pre>
 
Downloaded server package for linux from IBM.
 
<pre>
unzip tsmv5310.zip
./install_server
</pre>
 
The server package has to be installed before the license package or the license files won't be installed.
 
==== Client ====
 
Installed TSM client.
 
<pre>
cd /root/tsm
mkdir linux_client
cd linux_client
</pre>
 
Grabbed TSM client package for linux.
 
<pre>
tar -zxvf C80C5ML.tar.gz
cd tsmcli/linux86
rpm -ivh TIVsm-API.i386.rpm TIVsm-BA.i386.rpm
</pre>
 
=== Configuration ===
 
==== Server ====
 
Setup the server config file, /opt/tivoli/tsm/server/bin/dsmserv.opt.
 
<pre>
* Comments are denoted by a *.
COMMmethod SHAREDMEM
COMMmethod TCPip
    tcpport 1500
LANGuage en_US
</pre>
 
Register the license files.
 
<pre>
cd /opt/tivoli/tsm/server/bin
./dsmserv
REGister LICense FILE=*.lic
</pre>
 
Define LTO library.
 
<pre>
define library autoltolib libtype=scsi autolabel=yes
define path buttercup autoltolib srctype=server desttype=library device=/dev/IBMchanger0
define drive autoltolib autoltodrive01
define path buttercup autoltodrive01 srctype=server desttype=drive library=autoltolib device=/dev/IBMtape0
</pre>
 
Define storage pool for LTO library.
 
<pre>
define devclass autoltoclass library=autoltolib devtype=lto format=drive
define stgpool autoltopool autoltoclass maxscratch=24
</pre>
 
Check in labeled blank tapes.
 
<pre>
label libvolume autoltolib search=yes labelsource=barcode checkin=scratch
</pre>
 
Define storage policy.
 
<pre>
define domain ICONIC
define policyset ICONIC ICONIC
define mgmtclass ICONIC ICONIC ICONIC
define copygroup ICONIC ICONIC ICONIC standard destination=autoltopool
assign defmgmtclass ICONIC ICONIC ICONIC
activate policyset ICONIC ICONIC
</pre>
 
Define schedules.
 
<pre>
define schedule ICONIC nightly starttime=00:01 duration=5 durunits=hours
define schedule ICONIC saturday startime=09:01 duration=5 durunits=hours dayofweek=saturday
</pre>
 
Register client node.
 
<pre>
register node <nodename> <password> domain=ICONIC
</pre>
 
Define association between node and schedule.
 
<pre>
define association ICONIC <schedule> <node>
</pre>
 
Start server daemon on buttercup
 
<pre>
cd /opt/tivoli/tsm/server/bin
nohup ./dsmserv >& /dev/null &
</pre>
 
==== Client ====
 
Setup client config file, /opt/tivoli/tsm/client/ba/bin/dsm.opt.
 
<pre>
servername buttercup
</pre>
 
Setup client config file, /opt/tivoli/tsm/client/ba/bin/dsm.sys.
 
<pre>
servername buttercup
commmethod tcpip
  tcpport 1500
  tcpserveraddress 128.223.202.95
passwordaccess generate
nodename sonicclient
inclexcl        /opt/tivoli/tsm/client/ba/bin/sonic.inclexcl
</pre>
 
Setup client include/exclude file, /opt/tivoli/tsm/client/ba/bin/sonic.inclexcl.
 
<pre>
exclude.dir /
exclude.dir /boot
include /mnt/home
</pre>
 
Start client daemon on remote nodes.
 
<pre>
nohup dsmc sched >& /dev/null &
</pre>
 
== Restoring Files ==
 
Log in to the machine the file was backed up from and run one or more of the following commands.
 
Restore a file.
 
<pre>
dsmc restore /mnt/home/users/ryanm/test_file
</pre>
 
Restore a user's home directory to a temporary space.
 
<pre>
dsmc restore /mnt/home/users/amorris /mnt/admin/restores/20060523/ -subdir=yes
</pre>
 
== Maintenance ==
 
=== Start/Stop/Update ===
 
How to start/stop/update or maintain this service or system
 
Start the server.
 
<pre>
/etc/init.d/dsmserv stop
or
nohup ./dsmserv >& /dev/null &
</pre>
 
Stop the server.
 
<pre>
/etc/init.d/dsmserv stop
or
killall dsmserv
</pre>
 
Start the client.
 
<pre>
/etc/init.d/dsmcsched start
or
nohup dsmc sched >& /dev/null &
</pre>
 
Stop the client.
 
<pre>
/etc/init.d/dsmsched stop
or
killall dsmc
</pre>
 
=== Logs ===
 
Server logs are located here.
 
<pre>
/opt/tivoli/tsm/server/bin/dsmserv.log
</pre>
 
Client logs are located in the directory the daemon was started from, usually
 
<pre>
~/dsmsched.log
</pre>
 
=== Useful Tips ===
 
Configure server from client machine.
 
<pre>
dsmadmc
#username=admin
#password=secret
</pre>
 
Get help.
 
<pre>
help <command>
e.g. help query, help define, help define node
</pre>
 
 
== IBM 3582 LTO Tape Library ==
 
=== Description ===
 
The IBM 3582 LTO tape library is a 24 tape library with one robot and 2 drive slot, one of which is filled with an LTO2 Ultrium drive.
 
=== Kernel Module ===
 
The '''IBMtape''' kernel module is installed on buttercup and needs to be loaded on boot.  It creates the following device files:
 
<pre>
crw-------  1 root root 253, 512 Feb 24 09:58 /dev/IBMchanger0
crw-------  1 root root 253,  0 Feb 24 09:58 /dev/IBMtape0
crw-------  1 root root 253, 256 Feb 24 09:58 /dev/IBMtape0n
</pre>
 
=== Command-line Utility ===
 
'''IBMtapeutil''' and '''IBMtapeconfig''' are installed on buttercup.  The following are some useful commands.
 
IBMtapeutil usage.
 
<pre>
IBMtapeutil -h
</pre>
 
Output from '''IBMtapeutil -h'''.
 
<pre>
Usage: IBMtapeutil [-f Device Subcommand [Subcommand ...]]
 
IBMtapeutil for Linux, Version 1.3.1, Sept. 14, 2004
General Subcommands:
  tur              inquiry [Page]  print "Text" 
  reserve          release          reqsense       
  qryversion      logpage "Page"  modepage "Page"
  qrypath          enablepath "primary" | number
  path            disablepath "primary" | number
Tape Subcommands:
  bsf [Count]      bsr [Count]    eof [Count]
  fsf [Count]      fsr [Count]    weof [Count]
  fsfm [Count]    bsfm [Count]  asf [Count]
  compress        tell          seek [Count]
  nocompress      rewind        sync
  load            erase          display "Message"
  unload          retension      read -d Destination [-c Count]
  qrypos          seod          write -s Source
  setpos [Blockid] status        rtest  [-b Blocksize] [-c Count] [-r Repetition]
  offline          parms          wtest  [-b Blocksize] [-c Count] [-r Repetition]
  rewoffl          list          rwtest [-b Blocksize] [-c Count] [-r Repetition]
  prevent          lock          setblk [Count]
  allow            unlock        density
  qryinquiry      qrysense      append        mtdevice
Medium Changer Subcommands:
  allow        prevent          audit [Address [Count]]   
  inventory    mount [Slot]    position "Destination"
  elementinfo  unmount [Slot]  move "Source" "Destination"
  devids        exchange "Source" "Dest1" "Dest2"
Service Aid Subcommands:
  dump [Filename] forcedump    ucode "Name"  resetdrive
 
</pre>
 
Tape inventory.
 
<pre>
IBMtapeutil -f /dev/IBMchanger0 inventory
</pre>
 
Mount a tape from slot 5.
 
<pre>
IBMtapeutil -f /dev/IBMchanger0 mount 5
</pre>
 
Move a tape from slot 3 to slot 10.
 
<pre>
IBMtapeutil -f /dev/IBMchanger0 move 3 10
</pre>

Latest revision as of 01:44, 2 August 2006