linux安装模拟磁带库

  • A+
所属分类:linux技术
摘要

安装模拟带库 重启磁带库 列出scsi设备 linux命令操作磁带库  版权声明:本文为博主原创文章,转载请附上博文链接!

安装模拟带库

 1 [root@classroom TAPE]# cd mhvtl-master/  2 [root@classroom mhvtl-master]# ls  3 ccan       doc      INSTALL   man               scripts  usr  4 ChangeLog  etc      kernel    mhvtl-utils.spec  tcopy    vagrant  5 COPYING    include  Makefile  README            todo     webgui  6 [root@classroom mhvtl-master]# cd kernel/  7 [root@classroom kernel]# make  8 [root@classroom kernel]# make install  9 [root@classroom kernel]# cd .. 10 [root@classroom mhvtl-master]# make 11 [root@classroom mhvtl-master]# make install

重启磁带库

1 [root@classroom mhvtl-master]# systemctl restart mhvtl.target

列出scsi设备

 1 [root@classroom mhvtl]# lsscsi -g  2 [0:0:0:0]    cd/dvd  PLDS     DVD-RW DS8ABSH   AL61  /dev/sr0   /dev/sg0  3 [4:0:0:0]    disk    ATA      ST500LT012-1DG14 LVM1  /dev/sda   /dev/sg1  4 [6:0:0:0]    mediumx STK      L700             0106  /dev/sch0  /dev/sg11  5 [6:0:1:0]    tape    IBM      ULT3580-TD5      0106  /dev/st6   /dev/sg9  6 [6:0:2:0]    tape    IBM      ULT3580-TD5      0106  /dev/st2   /dev/sg5  7 [6:0:3:0]    tape    IBM      ULT3580-TD4      0106  /dev/st1   /dev/sg4  8 [6:0:4:0]    tape    IBM      ULT3580-TD4      0106  /dev/st5   /dev/sg8  9 [6:0:8:0]    mediumx STK      L80              0106  /dev/sch1  /dev/sg12 10 [6:0:9:0]    tape    STK      T10000B          0106  /dev/st7   /dev/sg10 11 [6:0:10:0]   tape    STK      T10000B          0106  /dev/st3   /dev/sg6 12 [6:0:11:0]   tape    STK      T10000B          0106  /dev/st4   /dev/sg7 13 [6:0:12:0]   tape    STK      T10000B          0106  /dev/st0   /dev/sg3 14 [7:0:0:0]    disk    Kingston DataTraveler 3.0 PMAP  /dev/sdc   /dev/sg2

linux命令操作磁带库

 1 [root@classroom ~]# mtx -f /dev/sg12 load 1 3          --把第1盒带子(卷)装入第4个磁带机  2 Loading media from Storage Element 1 into drive 3...done  3 [root@classroom share]# tar zcvf /dev/nst0  install.log    --将文件写入磁带  4 [root@classroom G03001TA]# mt -f /dev/nst0 tel          --查看磁头停止位置  5 At block 3319.  6 [root@classroom share]# mt -f /dev/nst0 rewind          --倒带  7 [root@classroom share]# mt -f /dev/nst0 tel   8 At block 0.  9 [root@classroom share]# mt -f /dev/nst0 fsf 1          --前进到下一个块 10 [root@classroom share]# mt -f /dev/nst0 tel  11 At block 3319. 12 [root@classroom share]# mt -f /dev/st0  rewind 13 [root@classroom share]# mt -f /dev/st0  erase          --清洗磁带 14 [root@classroom share]# mt -f /dev/st0  tel  15 At block 0. 16 [root@classroom share]# mtx -f /dev/sg12  unload  1 3     --拔出磁带 17 Unloading drive 3 into Storage Element 1...done

 版权声明:本文为博主原创文章,转载请附上博文链接!