TSM V6.2.1 DC(中国)
TSM V6.2.1
DC(中国)
目 录
第 1章 环境准备 ....................................................................................................................3
1.1、 软件描述................................................................................................................3 1.2、 系统环境................................................................................................................3
第 2章 Server ..........................................................................................................................3
2.1、 TS3200 Driver .........................................................................................................3 2.2、 install Server for Linux redhat 5.4 x86_64..............................................................5 2.3、 Configuring the server instance manually..............................................................7
2.3.1、 Creating the directories and the user ID for the server instance ................7
2.3.2、 Creating the server instance .......................................................................7
2.3.3、 Configuring dsmserv.opt .............................................................................7
2.3.4、 Formatting the database and log ................................................................8
2.4、 Configuring the server instance manually..............................................................8 2.5、 Configuring TSM Server..........................................................................................8 2.6、 define admin schedule ...........................................................................................9 2.7、 define library/driver/path ...................................................................................9 2.8、 define devclass .......................................................................................................9 2.9、 define stgpool ........................................................................................................9 2.10、 define domain/policyset/mgmtclass/copygroup .................................................9 2.11、 register node ......................................................................................................10
第 3章 Client .........................................................................................................................10
3.1、 TS3200 Driver .......................................................................................................10 3.2、 install client for AIX ..............................................................................................11 3.3、 Configuring dsm.opt/dsm.sys...............................................................................11 3.4、 update db cfg .......................................................................................................12 3.5、 scripts ...................................................................................................................12 3.6、 Storage Agent .......................................................................................................13
第 4章 Administration Center ..............................................................................................13
第1章 环境准备
1.1、软件描述
软件 位置 描述
CZG6WML.bin /tsm/soft IBM Tivoli Storage Manager V6.2.1 Linux x86_64 Server
CZGL7ML.tar.gz /tsm/soft IBM Tivoli Storage Manager V6.2.1 AIX Clients
lin_tape‐1.27.0‐1.src.rpm.bin
lin_taped‐1.27.0‐rhel5.x86_64.rpm.bin
/tsm/soft/driver
CZG73ML.bin /tsm/soft IBM Tivoli Storage Manager V6.2.1 Linux x86 Administration Center
CZG7AML.tar /tsm/soft IBM Tivoli Storage Manager V6.2.1 Linux x86_64 Reporting & Monitoring
CZGL9ML.tar /tsm/soft IBM Tivoli Storage Manager V6.2.1 Linux Clients
1.2、系统环境
主机名 操作系统 查看命令 IP 角色
tsmserver Red Hat Enterprise 5.4 X86_64 cat /etc/redhat‐release Server /client/api/
TESTDB oslevel ‐s Server/client/api/SAN
TESTAPP oslevel ‐s Server/client/api/SAN
第2章Server
2.1、TS3200 Driver
安装之前,查看 HBA卡和 TS3200信息 # more /proc/scsi/IBMtape lin_tape version: 1.27.0 lin_tape major number: 250 Attached Tape Devices: Number model SN HBA FO Path 0 ULT3580‐TD4 1310225352 lpfc NA 1 ULT3580‐TD4 1310225205 lpfc NA
安装 TS3200磁带库驱动程序(For Linux X86_64)
驱动下载链接如下:
ftp://ftp.software.ibm.com/storage/devdrvr/Linux/archive/lin_tape_source‐lin_taped/lin_tape/
ftp://ftp.software.ibm.com/storage/devdrvr/Linux/archive/lin_tape_source‐lin_taped/lin_taped/
RHEL5/
cd /tsm/soft/driver 1. Download the appropriate level of the source RPM package to a directory of your choice on the Linux kernel for which you wish to install it. 2. Run rpmbuild ‐‐rebuild <filename>, where: <filename> is the name of the RPM file. This creates a binary RPM package for your kernel from the source RPM package. For example:
>rpmbuild ‐‐rebuild lin_tape‐1.x.x.x.0‐1.src.rpm
3. Output from the build is printed to your screen. Near the end of the output, there is a line that indicates the filename and location of your binary RPM package. For example, a line similar to the following is output to your screen: Wrote: /usr/src/redhat/RPMS/i386/lin_tape‐1.x.x.x.0‐1.i386.rpm 4. To install the lin_tape driver from the binary package, run >rpm ‐ivh <filename> For example:
>rpm ‐ivh /usr/src/redhat/RPMS/i386/lin_tape‐1.x.x.x.0‐1.i386.rpm
5. To install the lin_taped daemon, download it to your Linux filesystem and run rpm ‐ivh on the daemon RPM file. For example:
>rpm ‐ivh /usr/src/redhat/RPMS/i386/lin_taped‐1.x.x.x.0‐rhel5.i386.rpm
下面的 rpmbuild.txt文件,为编译驱动的完整信息
Rpmbuild.txt 安装完 TS3200 FOR LINUX驱动后,使用命令 ls ‐l /dev/IBMtape*,可以看到如下信息:
如需要卸载驱动,请执行以下命令 [root@tsmserver ~]# rpm ‐e lin_taped Shutting down lin_tape: [root@tsmserver ~]# rpm ‐e lin_tape Shutting down lin_tape:
2.2、install Server for Linux redhat 5.4 x86_64
./CZG6WML.bin 解压安装软件包后
./install.bin
由于是安装 TSM Server,所以不需要安装 Tivoli Storage Manager Storage Agent组件
2.3、Configuring the server instance manually
2.3.1、Creating the directories and the user ID for the server instance
groupadd tsmsrvrs adduser ‐d /home/tsminst1 ‐m ‐g tsmsrvrs ‐s /bin/bash tsminst1 passwd tsminst1(密码设置为 password)
2.3.2、Creating the server instance
/opt/tivoli/tsm/db2/instance/db2icrt ‐a SERVER ‐u tsminst1 tsminst1
$ db2 update dbm cfg using dftdbpath /home/tsminst1/tsminst1
2.3.3、Configuring dsmserv.opt
编辑/opt/tivoli/tsm/server/bin/dsmserv.opt COMMmethod TCPIP tcpport 1500
tcpwindowsize 0 tcpnodelay yes DEVCONFIG /home/tsminst1/tsminst1/devconfig.out VOLUMEHISTORY /home/tsminst1/tsminst1/volhist.out ACTIVELOGDirectory /tsm/activelog ARCHLOGDirectory /tsm/archlog commtimeout 7200 idletimeout 120 DEVCONFIG /tsm/files/devconfig.out VOLUMEHISTORY /tsm/files/volhist.out
2.3.4、Formatting the database and log
db2set ‐i tsminst1 DB2CODEPAGE=819 /opt/tivoli/tsm/server/bin/dsmserv format dbdir=/tsm/db activelogdir=/tsm/activelog archlogdir=/tsm/archlog
2.4、Configuring the server instance manually
vi /etc/rc.d/rc.local 添加如下内容 service crond start(自动备份任务) ######Automatically starting TSM Service############# /opt/tivoli/tsm/server/bin/rc.dsmserv ‐u tsminst1 ‐i /home/tsminst1/tsminst1 ‐q >/dev/console 2>&1& crontab ‐e 添加系统任务 ##############TSM DB‐BACKUP SCHEDULE#################################################### 0 5 * * * /tsm/scripts/db2full.sh>/dev/console 2>&1 #FULLBackup tsmdb1 at 05:00 everyday more /tsm/scripts/db2full.sh export LOGFILE=/tsm/logs/`date +"%Y.%m.%d_%H.%M.%S"`_db2full.log date>>$LOGFILE echo backup database TSMDB1>>$LOGFILE su ‐ tsminst1 ‐c "db2 backup db TSMDB1 online to /tsm/dbbackup/ include logs">>$LOGFILE date>>$LOGFILE 设置 TSMDB1 备份保留版本及过期处理 db2 update db cfg for tsmdb1 using NUM_DB_BACKUPS 5 REC_HIS_RETENTN 10 AUTO_DEL_REC_OBJ ON
分配管理员权限 grant authority admin classes=system
2.5、Configuring TSM Server
set servername tsm set serverpassword password set serverhladdress set serverlladdress 1500 reg lic file=*.lic number=100
set PASSExp 9999
2.6、define admin schedule
define schedule backup_devconfig type=administrative cmd="backup devconfig filenames=/tsm/dbbackup/devconfig.new" starttime=06:30 active=yes description="backup devconfig using files" define schedule backup_volhistory type=administrative cmd="backup volhistory filenames=/tsm/dbbackup/volhistory.new" starttime=06:30 active=yes description="backup volhistory using files" define schedule delete_volhistory type=administrative cmd="delete volhistory TODate=today‐5 type=dbbackup" starttime=07:00 active=yes description="Volhistory backup" define schedule expire_inventory type=administrative cmd="expire inventory" startt=07:30 description="Inventory expiration"
2.7、define library/driver/path
def library 3200lib libtype=scsi shared=yes def path tsm 3200lib srctype=server autodetect=yes desttype=library device=/dev/IBMchanger0 online=yes def drive 3200lib driver1 element=autodetect online=yes def path tsm driver1 srctype=server autodetect=yes desttype=drive library=3200lib device=/dev/IBMtape0 online=yes def drive 3200lib driver2 element=autodetect online=yes def path tsm driver2 srctype=server autodetect=yes desttype=drive library=3200lib device=/dev/IBMtape1 online=yes
2.8、define devclass
define devclass fileclass devtype=file maxcapacity=2000M directory=/tsm/dbbackup define devclass 3200class library=3200lib devtype=LTO
2.9、define stgpool
define stgpool filepool 3200class maxscratch=2 define stgpool db2pool 3200class maxscratch=50
2.10、define domain/policyset/mgmtclass/copygroup
define domain file descr="BACKUP IMPORTANT FILES" define policyset file file_set descr="BACKUP IMPORTANT FILES" define MGMTCLASS file file_set file_class SPACEMGTECHNIQUE=NONE AUTOMIGNONUSE=0 MIGREQUIRESBKUP=YES descr="BACKUP IMPORTANT FILES" define COPYGROUP file file_set file_class DESTINATION=NONE FREQUENCY=0 VEREXISTS=7 VERDELETED=1 RETEXTRA=30 RETONLY=180 MODE=MODIFIED SERIALIZATION=SHRSTATIC
assign defmgmtclass file file_set file_class activate policyset file file_set define domain db2 descr="BACKUP DB2 DATABASE" define policyset db2 db2_set descr="BACKUP DB2 DATABASE" define MGMTCLASS db2 db2_set db2_class migdestination=NONE descr="BACKUP db2 database" define COPYGROUP db2 db2_set db2_class standard type=backup DESTINATION=db2pool FREQUENCY=0 VEREXISTS=1 VERDELETED=0 RETEXTRA=0 RETONLY=0 MODE=absolute SERIALIZATION=SHRSTATIC define copygroup db2 db2_set db2_class standard type=archive destination=NONE RETVER=NOLIMIT assign defmgmtclass db2 db2_set db2_class activate policyset db2 db2_set
2.11、register node
reg node tsmserver password domain=file maxnummp=10 passexp=0 backdelete=yes archdelete=yes reg node TESTDB_FILE password domain=file maxnummp=10 passexp=0 backdelete=yes archdelete=yes reg node TESTAPP_FILE password domain=file maxnummp=10 passexp=0 backdelete=yes archdelete=yes reg node TESTDB_DB2 password domain=db2 maxnummp=10 passexp=0 backdelete=yes archdelete=yes
第3章 Client
3.1、TS3200 Driver
*.*.*.81和*.*.*.82上,都需要安装 Atape驱动 安装后,使用命令 lsdev ‐Cc tape,查询磁带库设备
tapeutil ‐f /dev/smc0 inventory tapeutil ‐f /dev/smc0 inventory|grep A00
3.2、install client for AIX
TESTDB:/tsm/soft/client/TSMCLI_AIX/usr/sys/inst.images#>smitty install_latest tivoli.tsm.client.ba tivoli.tsm.client.api.32bit tivoli.tsm.client.api.64bit
3.3、Configuring dsm.opt/dsm.sys
/usr/tivoli/tsm/client/ba/bin/dsm.opt servername tsm /usr/tivoli/tsm/client/ba/bin/dsm.sys SErvername tsm enablelanfree yes LANFREECommmethod TCPIP LANFREETCPPort 1500 COMMmethod TCPip TCPPort 1500 TCPServeraddress nodename TESTDB_FILE passwordaccess generate errorlogname /tsm/logs/dsmerror.log schedlogname /tsm/logs/dsmsched.log
SErvername tdp_db2 enablelanfree yes LANFREECommmethod TCPIP LANFREETCPPort 1500 COMMmethod TCPip TCPPort 1500 TCPServeraddress nodename TESTDB_DB2
passwordaccess generate errorlogname /tsm/logs/dsmerror.log schedlogname /tsm/logs/dsmsched.log
/usr/tivoli/tsm/client/api/bin64/dsm.opt SErvername tdp_db2 /usr/tivoli/tsm/client/api/bin64/dsm.sys SErvername tdp_db2 enablelanfree yes LANFREECommmethod TCPIP LANFREETCPPort 1500 COMMmethod TCPip TCPPort 1500 TCPServeraddress nodename TESTDB_DB2 passwordaccess generate errorlogname /tsm/logs/dsmerror.log schedlogname /tsm/logs/dsmsched.log
3.4、update db cfg
db2 update db cfg for ITF using LOGRETAIN ON LOGARCHMETH1 TSM AUTO_DEL_REC_OBJ ON TRACKMOD ON db2 update db cfg for IUFO using LOGRETAIN ON LOGARCHMETH1 TSM AUTO_DEL_REC_OBJ ON TRACKMOD ON db2 update db cfg for NCDB using LOGRETAIN ON LOGARCHMETH1 TSM AUTO_DEL_REC_OBJ ON TRACKMOD ON
3.5、scripts
/tsm/scripts/db2full.sh export LOGFILE=/tsm/logs/`date +"%Y.%m.%d_%H.%M.%S"`_db2full.log echo backup database ITF>>$LOGFILE su ‐ db2inst1 ‐c "db2 backup db ITF online use tsm include logs">>$LOGFILE su ‐ db2inst1 ‐c "db2adutl delete full keep 60 db ITF without prompting">>$LOGFILE echo backup database IUFO>>$LOGFILE su ‐ db2inst1 ‐c "db2 backup db IUFO online use tsm include logs" >>$LOGFILE su ‐ db2inst1 ‐c "db2adutl delete full keep 60 db IUFO without prompting">>$LOGFILE echo backup database NCDB>>$LOGFILE su ‐ db2inst1 ‐c "db2 backup db NCDB online use tsm include logs" >>$LOGFILE su ‐ db2inst1 ‐c "db2adutl delete full keep 60 db NCDB without prompting">>$LOGFILE /tsm/scripts/db2incre.sh export LOGFILE=/tsm/logs/`date +"%Y.%m.%d_%H.%M.%S"`_db2incre.log echo backup database ITF>>$LOGFILE su ‐ db2inst1 ‐c "db2 backup db ITF online use tsm incremental include logs">>$LOGFILE su ‐ db2inst1 ‐c "db2adutl delete full keep 60 db ITF without prompting">>$LOGFILE echo backup database IUFO>>$LOGFILE su ‐ db2inst1 ‐c "db2 backup db IUFO online use tsm incremental include logs" >>$LOGFILE su ‐ db2inst1 ‐c "db2adutl delete full keep 60 db IUFO without prompting">>$LOGFILE echo backup database NCDB>>$LOGFILE
su ‐ db2inst1 ‐c "db2 backup db NCDB online use tsm incremental include logs" >>$LOGFILE su ‐ db2inst1 ‐c "db2adutl delete full keep 60 db NCDB without prompting">>$LOGFILE
3.6、 Storage Agent
TESTDB:/tsm/soft/san/COI/PackageSteps/TSM_Stagent/FILES/TIV‐TSMSTA‐AIX tivoli.tsm.StorageAgent 6.2.1.0
define server TESTDB serverpassword=password hladdress=*.*.*.81 lladdress=1500 validateprotocol=all define server TESTAPP serverpassword=password hladdress=*.*.*.82 lladdress=1500 validateprotocol=all define path TESTDB DRIVER1 srctype=server desttype=drive library=3200LIB device=/dev/rmt2 define path TESTDB DRIVER2 srctype=server desttype=drive library=3200LIB device=/dev/rmt1 define path TESTAPP DRIVER1 srctype=server desttype=drive library=3200LIB device=/dev/rmt2 define path TESTAPP DRIVER2 srctype=server desttype=drive library=3200LIB device=/dev/rmt1 ./dsmsta setstorageserver myname=TESTDB mypassword=password myhladdress=*.*.*.81 servername=tsm serverpassword=password hladdress= lladdress=1500 ./dsmsta setstorageserver myname=TESTAPP mypassword=password myhladdress=*.*.*.82 servername=tsm serverpassword=password hladdress= lladdress=1500
第4章 Administration Center
tipadmin/password
访问 URL
http://*.*.*.80:16310
dd if=/home/group02/* of=/dev/rmt0 bs=8192
dd if=/dev/rmt0 of=/home/group02_r
find /home/group02 ‐print | cpio ‐ov >/dev/rmt0
cpio ‐ir </dev/rmt0