TivoliStorageManager: Difference between revisions
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
== Intro == | == Intro == | ||
Revision as of 22:29, 1 August 2006
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.
mkdir /root/tsm cd /root/tsm mkdir linux_server cd linux_server
Downloaded server package for linux from IBM.
unzip tsmv5310.zip ./install_server
The server package has to be installed before the license package or the license files won't be installed.
Client
Installed TSM client.
cd /root/tsm mkdir linux_client cd linux_client
Grabbed TSM client package for linux.
tar -zxvf C80C5ML.tar.gz cd tsmcli/linux86 rpm -ivh TIVsm-API.i386.rpm TIVsm-BA.i386.rpm
Configuration
Server
Setup the server config file, /opt/tivoli/tsm/server/bin/dsmserv.opt.
* Comments are denoted by a *.
COMMmethod SHAREDMEM
COMMmethod TCPip
tcpport 1500
LANGuage en_US
Register the license files.
cd /opt/tivoli/tsm/server/bin ./dsmserv REGister LICense FILE=*.lic
Define LTO library.
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
Define storage pool for LTO library.
define devclass autoltoclass library=autoltolib devtype=lto format=drive define stgpool autoltopool autoltoclass maxscratch=24
Check in labeled blank tapes.
label libvolume autoltolib search=yes labelsource=barcode checkin=scratch
Define storage policy.
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
Define schedules.
define schedule ICONIC nightly starttime=00:01 duration=5 durunits=hours define schedule ICONIC saturday startime=09:01 duration=5 durunits=hours dayofweek=saturday
Register client node.
register node <nodename> <password> domain=ICONIC
Define association between node and schedule.
define association ICONIC <schedule> <node>
Start server daemon on buttercup
cd /opt/tivoli/tsm/server/bin nohup ./dsmserv >& /dev/null &
Client
Setup client config file, /opt/tivoli/tsm/client/ba/bin/dsm.opt.
servername buttercup
Setup client config file, /opt/tivoli/tsm/client/ba/bin/dsm.sys.
servername buttercup commmethod tcpip tcpport 1500 tcpserveraddress 128.223.202.95 passwordaccess generate nodename sonicclient inclexcl /opt/tivoli/tsm/client/ba/bin/sonic.inclexcl
Setup client include/exclude file, /opt/tivoli/tsm/client/ba/bin/sonic.inclexcl.
exclude.dir / exclude.dir /boot include /mnt/home
Start client daemon on remote nodes.
nohup dsmc sched >& /dev/null &
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.
dsmc restore /mnt/home/users/ryanm/test_file
Restore a user's home directory to a temporary space.
dsmc restore /mnt/home/users/amorris /mnt/admin/restores/20060523/ -subdir=yes
Maintenance
Start/Stop/Update
How to start/stop/update or maintain this service or system
Start the server.
/etc/init.d/dsmserv stop or nohup ./dsmserv >& /dev/null &
Stop the server.
/etc/init.d/dsmserv stop or killall dsmserv
Start the client.
/etc/init.d/dsmcsched start or nohup dsmc sched >& /dev/null &
Stop the client.
/etc/init.d/dsmsched stop or killall dsmc
Logs
Server logs are located here.
/opt/tivoli/tsm/server/bin/dsmserv.log
Client logs are located in the directory the daemon was started from, usually
~/dsmsched.log
Useful Tips
Configure server from client machine.
dsmadmc #username=admin #password=secret
Get help.
help <command> e.g. help query, help define, help define node
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:
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
Command-line Utility
IBMtapeutil and IBMtapeconfig are installed on buttercup. The following are some useful commands.
IBMtapeutil usage.
IBMtapeutil -h
Output from IBMtapeutil -h.
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
Tape inventory.
IBMtapeutil -f /dev/IBMchanger0 inventory
Mount a tape from slot 5.
IBMtapeutil -f /dev/IBMchanger0 mount 5
Move a tape from slot 3 to slot 10.
IBMtapeutil -f /dev/IBMchanger0 move 3 10