AIX 系统下 Atape 安装与配置实战

本文将就如何在 AIX 系统下安装和配置 IBM 带库以及磁带驱动器进行介绍,并辅以实战例程。本文目标读者为 AIX 系统管理员以及 IBM 带库相关设备的现场安装工程师,并为企业数据中心管理员提供参考。

  前言

  本文就 AIX 系统下带库机械臂、磁带驱动器驱动 Atape 的下载、安装、设备配置、设备测试、驱动卸载进行详细介绍。另外文章还列出了常用的磁带设备的命令,并介绍如何在备份软件 TSM(Tivoli Storage Manager)中定义和使用磁带设备。所用的命令均辅以实战用例,供系统管理员查看使用。

  安装前的准备工作

  对于较小型的存储网络,可以使用 SCSI 线直接连接系统与磁带库。本实例使用 SAN 网络来连接 AIX 系统和磁带库,因此需要在 AIX 系统正确配置 HBA(Host Bus Adapter)卡,确保 SAN 网络的正确连接。

  Atape 简介

  IBM AIX Atape 驱动提供对 IBM 磁带驱动器以及机械臂设备(Media Changer)的支持。Atape 不仅可以给各种应用程序提供基本的磁带操作,例如对备份、恢复;提供基本的机械臂操作,例如载入(Mount)、载出(Unmount)磁带(Cartridges /Tapes);还为磁带管理系统提供更高级的功能。该驱动对应用程序是透明的。正确安装驱动以后,应用程序可以使用驱动提供的各种功能。

  安装包下载:IBM Atape 安装包可以从 ftp://ftp.software.ibm.com/storage/devdrvr/AIX 下载。从下面的网站确定你的操作系统的补丁级别是否符合要求:http://www.storage.ibm.com/tape/lto/compatibility.html

  下载步骤如下:

# ftp ftp.software.ibm.com 
Connected to dispsd-40-ftp.boulder.ibm.com. 
220-******************************************************************************* 
220-* * 
220-* IBM's internal systems must only be used for conducting IBM's * 
220-* business or for purposes authorized by IBM management. * 
220-* * 
220-* Use is subject to audit at any time by IBM management. * 
220-* * 
220-******************************************************************************* 
220- 
220 service FTP server (Version wu-2.6.2(5) Custom Sat May 28 01:48:31 MDT 2005) ready. 
Name (ftp.software.ibm.com:root): anonymous 
331 Guest login ok, send any password. 
Password: 
230 Guest login ok, access restrictions apply. 
ftp> cd /storage/devdrvr/AIX 
250-Please read the file README 
250- it was last modified on Mon Oct 8 17:36:52 2007 - 520 days ago 
250 CWD command successful. 
ftp> ls 
200 PORT command successful. 
150 Opening ASCII mode data connection for file list. 
Atape.10.7.3.0.bin 
Atape.11.3.4.0.bin 
Atape.8.4.9.0.bin 
Atape.9.7.5.0.bin 
Atape.README 
Atape.fixlist 
README 
atldd.5.5.1.0.bin 
atldd.6.7.7.0.bin 
atldd.Readme 
atldd.fixlist 
226 Transfer complete. 
ftp> bin 
200 Type set to I. 
ftp> mget Atape.11.3.4.0.bin 
mget Atape.11.3.4.0.bin? y 
200 PORT command successful. 
150 Opening BINARY mode data connection for Atape.11.3.4.0.bin (5376000 bytes). 
226 Transfer complete. 
5376000 bytes received in 1.261 seconds (4165 Kbytes/s) 
local: Atape.11.3.4.0.bin remote: Atape.11.3.4.0.bin 

安装过程

  在安装新版本的设备驱动之前,建议先卸载老版本的驱动,并保证磁带设备已经上电、功能正常并已经正确连接到 AIX 系统上。

  可以使用命令 :

  installp –acXd Atape.x.x.x.x Atape.driver

  下面来安装我们下载的 Atape.11.3.4.0.bin:

# installp -acXd Atape.11.3.4.0.bin Atape.driver 
+-----------------------------------------------------------------------------+ 
 Pre-installation Verification... 
+-----------------------------------------------------------------------------+ 
Verifying selections...done 
Verifying requisites...done 
Results... 
SUCCESSES 
--------- 
 Filesets listed in this section passed pre-installation verification 
 and will be installed. 
 Selected Filesets 
 ----------------- 
 Atape.driver 11.3.4.0 # IBM AIX Enhanced Tape and Me... 
 <> 
+-----------------------------------------------------------------------------+ 
 BUILDDATE Verification ... 
+-----------------------------------------------------------------------------+ 
Verifying build dates...done 
FILESET STATISTICS 
------------------ 
 1 Selected to be installed, of which: 
 1 Passed pre-installation verification 
 ---- 
 1 Total to be installed 
0503-409 installp: bosboot verification starting... 
installp: bosboot verification completed. 
+-----------------------------------------------------------------------------+ 
 Installing Software... 
+-----------------------------------------------------------------------------+ 
installp: APPLYING software for: 
 Atape.driver 11.3.4.0 
. . . . . <> . . . . . . . 
 IBM AIX Enhanced Tape and Medium Changer Device Driver 
 (C) COPYRIGHT International Business Machines Corp. 1993 2005 
 All Rights Reserved 
 Licensed Materials - Property of IBM 
 US Government Users Restricted Rights - Use, duplication or 
 disclosure restricted by GSA ADP Schedule Contract with IBM Corp. 
. . . . . <>. . . . 
Checking for existing Atape devices... 
Installing AIX Version 6.1 Atape.driver... 
Adding device prototype... 
Adding odm and smit entries... 
Adding catalogs... 
Adding trace template... 
Adding error template... 
6 entries added. 
0 entries deleted. 
0 entries updated. 
Adding utility programs... 
Finished processing all filesets. (Total time: 11 secs). 
0503-409 installp: bosboot verification starting... 
installp: bosboot verification completed. 
0503-408 installp: bosboot process starting... 
bosboot: Boot image is 36475 512 byte blocks. 
0503-292 This update will not fully take effect until after a 
 system reboot. 
 * * * A T T E N T I O N * * * 
 System boot image has been updated. You should reboot the 
 system as soon as possible to properly integrate the changes 
 and to avoid disruption of current functionality. 
installp: bosboot process completed. 
+-----------------------------------------------------------------------------+ 
 Summaries: 
+-----------------------------------------------------------------------------+ 
Installation Summary 
-------------------- 
Name Level Part Event Result 
------------------------------------------------------------------------------- 
Atape.driver 11.3.4.0 USR APPLY SUCCESS 

如上例所示,如果 Installation Summary 给出的结果是 SUCCESS, Atape 驱动已经正确安装到系统中了。

  当然,也可以使用 smit 来安装:

#smitty 
-> Software Installation and Maintenance 
 -> Install and Update Software 
 -> Install Software 
 -> * INPUT device / directory for software 输入安装包位置 

  如下例:

Install Software 
Type or select values in entry fields. 
Press Enter AFTER making all desired changes. 
 
 [Entry Fields] 
* INPUT device / directory for software . 
* SOFTWARE to install [Atape > + 
 PREVIEW only? (install operation will NOT occur) no + 
 COMMIT software updates? yes + 
 SAVE replaced files? no + 
 AUTOMATICALLY install requisite software? yes + 
 EXTEND file systems if space needed? yes + 
 OVERWRITE same or newer versions? no + 
 VERIFY install and check file sizes? no + 
 Include corresponding LANGUAGE filesets? yes + 
 DETAILED output? no + 
 Process multiple volumes? yes + 
 ACCEPT new license agreements? no + 
 Preview new LICENSE agreements? no + 

  需要注意的是,PREVIEW only 一项需要置成 no,这样驱动才真正会被安装到系统中。

  选择确认后,回车完成安装过程。

安装完成后 , 用如下命令来确认,安装的版本和状态:  

  lslpp –l Atape.driver

# lslpp -l Atape.driver 
 Fileset Level State Description 
 ---------------------------------------------------------------------------- 
Path: /usr/lib/objrepos 
 Atape.driver 11.3.4.0 COMMITTED IBM AIX Enhanced Tape and 
 Medium Changer Device Driver 

  如果安装成功的话,installp 会自动调用 AIX 的 bosboot 命令把新安装的 Atape 文件更新到启动记录里,所以不需要重新启动 AIX 系统。

  配置磁带驱动器和机械臂

  安装结束后,需要进行配置以后,才能使用设备驱动。

  使用命令 #cfgmgr 来重新发现系统连接的设备,并进行配置。

  # cfgmgr

  上例中,cfgmgr 执行完毕,没有报错,则配置成功。

  当然重新启动 AIX 系统也能达到重新配置的效果。

  在 Atape 驱动已经安装而且设备已经配置以后,系统通过 /dev 目录下的 smc* 文件来表示物理的机械臂,rmt* 表示磁带驱动器。

  # lsdev -Cc tape 能列出系统所带的所有磁带设备

# lsdev -Cc tape 
rmt0 Available 01-01-01 IBM 3580 Ultrium Tape Drive (FCP) 
rmt1 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
rmt2 Available 01-01-01 IBM 3580 Ultrium Tape Drive (FCP) 
smc8 Available 01-01-01 IBM 3584 Library Medium Changer (FCP) 
smc9 Available 01-01-01 IBM 3584 Library Medium Changer (FCP) 

  上例中,系统连接有两个机械臂设备 smc8 和 smc9,和三个磁带驱动器 rmt0,rmt1,rmt2。

  验证机械臂以及驱动器是否工作正常

  需要使用 tapeutil 对机械臂和驱动器来进行验证。tapeutil 是 Atape 提供的设备测试应用程序,它是对磁带库以及驱动器进行直接操作的接口。安装 Atape 后,可直接运行 tapeutil 来启动程序。下面介绍一下如何使用 tapeutil 对系统连接的磁带驱动器和机械臂进行测试。

  # tapeutil

 General Commands: 
 1. Open a Device 5. Inquiry 9. Log Sense Page 
 2. Close a Device 6. Test Unit Ready 10. Mode Sense Page 
 3. Device Info 7. Reserve Device 11. Release Device 
 4. Tape Drive Service Aids 8. Request Sense Q. Quit Program 
 
 Medium Changer Commands: 
 12. Element Information 16. Move Medium 
 13. Position To Element 17. Load/Unload Medium 
 14. Element Inventory 18. Initialize Element Status 
 15. Exchange Medium 19. Prevent/Allow Medium Removal 
 
 Tape Commands: 
 20. Query/Set Parameters 30. Read and Write Tests 
 21. Prevent/Allow Medium Removal 31. Unload/Load Tape 
 22. Rewind 32. Erase 
 23. Erase Gap 33. Write Filemarks 
 24. Forward Space Filemarks 34. Backward Space Filemarks 
 25. Forward Space Records 35. Backward Space Records 
 26. Space to End of Data 36. Query/Set Tape Position 
 27. Log Sense 37. Read or Write Files 
 28. Display Message 38. Get Drive Encryption Settings 
 29. Synchronize Buffers 39. Report Density Support 
 40. Test Encryption Key Path/Setup 
 
Enter Selection: 

  如何验证磁带驱动器是否正确安装:

  1. 打开 AIX 窗口

  2. 输入 tapeutil

  3. 输入 1(打开一个设备)

  4. 输入 /dev/rmt0(需要验证的设备文件)

  5. 输入 1(Read/Write)

  6. 输入 3(Device Info)

  7. 输入 5(Inquiry)选择 0,对设备进行基本测试

  8. 输入 6(Test Unit Read)确认没有错误。

  9. 输入 18(Initialize Element Status)

  10. 输入 14(Element Inventory)查看所有带库中所有磁带

  11. 从上一步结果中,选择一个可写的空闲磁带,查看其序列号,并选择一个空闲的磁带插槽

  12. 输入 16(Move Medium),指定磁带的地址和空闲磁带插槽的地址。确认磁带被放置到正确的位置

  13. 输入 14 (Element Inventory),确认磁带库信息被更新

  14. 输入 2 (Close a Device)

  15. 输入 Q (退出程序)

  如何验证机械臂是否工作正常:

  1. 打开 AIX 窗口

  2. 输入 tapeutil

  3. 输入 1(打开一个设备)

  4. 输入 /dev/smc0

  5. 输入 1 (Read/Write)

  6. 输入 3 (Device Info)

  7. 输入 5 (Inquiry)选择 0,对设备进行基本测试

  8. 输入 6 (Test Unit Read)确认没有错误

  9. 输入 22(Rewind)

  10. 输入 30 (Read and Write Tests)进行读写测试

  11. 输入 1 (Read/Write). 开始测试

  12. 输入 31(Unload Tape)取出磁带

  13. 输入 2 (Close a Device)

  14. 输入 Q (退出程序)

  常用磁带设备管理命令

  查看所有系统连接的设备:

  下例列出系统识别出的所有带库机械臂和磁带驱动器的基本信息:

 lsdev -Cc tape

# lsdev -Cc tape 
rmt2 Available 01-01-01 IBM 3580 Ultrium Tape Drive (FCP) 
rmt3 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
rmt4 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
rmt5 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
rmt6 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
rmt7 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
rmt8 Available 01-01-01 LTO Ultrium Tape Drive (FCP) 
… 
smc5 Available 01-01-01 IBM 3584 Library Medium Changer (FCP) 
smc6 Available 01-01-01 IBM 3576 Library Medium Changer (FCP) 
smc7 Available 01-01-01 IBM 3584 Library Medium Changer (FCP) 
smc8 Available 01-01-01 IBM 3584 Library Medium Changer (FCP) 

  输出结果中,所有 rmt 开头的设备为磁带驱动器,而 smc 开头的设备为带库机械臂。

  查看设备的具体配置:

  查看设备的具体信息,如查看磁带驱动器 rmt-0 的信息:

  lscfg -vl rmt-0

# lscfg -vl rmt-0 
 rmt-0 U789D.001.DQDWVMV-P1-C3-T2-W5005076300810821-L0 
 IBM 3580 Ultrium Tape Drive (FCP) 
 
 Manufacturer................IBM 
 Machine Type and Model......ULT3580-TD3 
 Serial Number...............0007805879 
 Device Specific.(FW)........73P5 

  该设备为 IBM3580 的磁带驱动器,其序列号为 0007805879。

 查看机械臂 smc0 的具体信息:

# tapeutil -f /dev/smc0 inquiry 
Issuing inquiry... 
 
Inquiry Data, Length 58 
 
 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF 
 0000 - 0880 0302 3500 2002 4942 4D20 2020 2020 [.

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/611609/viewspace-687246/,如需转载,请注明出处,否则将追究法律责任。

user_pic_default.png
请登录后发表评论 登录
全部评论
<%=items[i].createtime%>

<%=items[i].content%>

<%if(items[i].items.items.length) { %>
<%for(var j=0;j
<%=items[i].items.items[j].createtime%> 回复

<%=items[i].items.items[j].username%>   回复   <%=items[i].items.items[j].tousername%><%=items[i].items.items[j].content%>

<%}%> <%if(items[i].items.total > 5) { %>
还有<%=items[i].items.total-5%>条评论 ) data-count=1 data-flag=true>点击查看
<%}%>
<%}%>
<%}%>

转载于:http://blog.itpub.net/611609/viewspace-687246/

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值