Why is my tape drive so slow?

1

I have bought a used Quantum Ultrium LTO-4 tape drive and attached it to an HP Smart Array P400 SAS controller in my HP ProLiant N54l. I use FreeBSD 11 as my operating system.

Now I have inserted a tape and ran the benchmark of Bacula's btape command:

$ btape /dev/nsa0
Tape block granularity is 1024 bytes.
btape: butil.c:291-0 Using device: "/dev/nsa0" for writing.
btape: btape.c:471-0 open device "LTO-4" (/dev/nsa0): OK
*rewind
btape: btape.c:576-0 Rewound "LTO-4" (/dev/nsa0)
*speed
btape: btape.c:1055-0 Test with zero data, should give the maximum throughput.
btape: btape.c:904-0 Begin writing 3 files of 1.073 GB with raw blocks of 64512 bytes.
++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 2.182 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 4.511 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 1.835 MB/s
btape: btape.c:379-0 Total Volume bytes=3.221 GB. Total Write rate = 2.449 MB/s

This (and some other tests) confirms a write rate of about 2 MB/s, which is unreasonably slow. Why is this the case? What can I do to elevate the write rate to the expected speed (e.g. 100 MB/s)?

Edit

It appears that something might be wrong with the controller. After a reboot, I was able to transfer data at high speed for a while until a number of PCI errors occured and speed slowed down to a crawl:

ciss0: *** PCI-E LL correctable errors, count=10546, LLErrStatus=0x80000004
ciss0: *** PCI-E LL correctable errors, count=20570, LLErrStatus=0x80000004
ciss0: *** PCI-E LL correctable errors, count=30995, LLErrStatus=0x80000004
ciss0: *** PCI-E LL correctable errors, count=41101, LLErrStatus=0x80000004
ciss0: *** PCI-E LL correctable errors, count=51400, LLErrStatus=0x80000004
ciss0: *** PCI-E LL correctable errors, count=61729, LLErrStatus=0x80000004

Perhaps the card is incorrectly seated or something like that.

freebsd
sas
scsi
tape
asked on Super User Apr 22, 2017 by FUZxxl • edited Apr 23, 2017 by FUZxxl

2 Answers

0

Minimum and maximum reading and writing speeds are drive-dependent.
Max uncompressed speed in 120 MBps for LTO-4.
Quantum LTO-4 HH tape drives have compressed transfer rates up to 576GB/hr Assumes 2:1 compression.
Real maximum speed of this drive is: 576GB/hr /2 = 288 *1024MB / 3600s = 81.92MBps. From drive specification:

Data Rate Matching Range: 33 to 80MB/sec native

So you never get 100 MB/s

Edit:
Read about Testing Your Tape Drive With Bacula.
You should set bacula-sd.conf file, and make sure that Bacula (the Storage daemon) is not running or that you have unmounted the drive you will use for testing.

answered on Super User Apr 22, 2017 by Adam Silenko • edited Apr 22, 2017 by Adam Silenko
0

I swapped the HP SmartArray P400 SAS controller for an LSI 3041E SAS controller. This solved my performance problems, I can now comfortably backup at high speed (I can reach about 70 MB/s in practice). Below you can find output from the same performance test previously used:

$ btape /dev/nsa0
Tape block granularity is 1024 bytes.
btape: butil.c:291-0 Using device: "/dev/nsa0" for writing.
btape: btape.c:471-0 open device "LTO-4" (/dev/nsa0): OK
*rewind
btape: btape.c:576-0 Rewound "LTO-4" (/dev/nsa0)
*speed
btape: btape.c:1055-0 Test with zero data, should give the maximum throughput.
btape: btape.c:904-0 Begin writing 3 files of 1.073 GB with raw blocks of 64512 bytes.
++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 71.58 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 119.3 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 134.2 MB/s
btape: btape.c:379-0 Total Volume bytes=3.221 GB. Total Write rate = 100.6 MB/s

btape: btape.c:904-0 Begin writing 3 files of 2.147 GB with raw blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 143.1 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 153.3 MB/s
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 143.1 MB/s
btape: btape.c:379-0 Total Volume bytes=6.442 GB. Total Write rate = 146.4 MB/s

btape: btape.c:904-0 Begin writing 3 files of 4.294 GB with raw blocks of 64512 bytes.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 165.1 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 165.1 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 165.1 MB/s
btape: btape.c:379-0 Total Volume bytes=12.88 GB. Total Write rate = 165.1 MB/s

btape: btape.c:1067-0 Test with random data, should give the minimum throughput.
btape: btape.c:904-0 Begin writing 3 files of 1.073 GB with raw blocks of 64512 bytes.
++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 53.69 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 51.13 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 53.69 MB/s
btape: btape.c:379-0 Total Volume bytes=3.221 GB. Total Write rate = 52.80 MB/s

btape: btape.c:904-0 Begin writing 3 files of 2.147 GB with raw blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 59.65 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 58.04 MB/s
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 58.04 MB/s
btape: btape.c:379-0 Total Volume bytes=6.442 GB. Total Write rate = 58.56 MB/s

btape: btape.c:904-0 Begin writing 3 files of 4.294 GB with raw blocks of 64512 bytes.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 60.49 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 70.41 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 69.27 MB/s
btape: btape.c:379-0 Total Volume bytes=12.88 GB. Total Write rate = 66.41 MB/s

btape: btape.c:1081-0 Test with zero data and bacula block structure.
btape: btape.c:959-0 Begin writing 3 files of 1.073 GB with blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 71.58 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 76.70 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 71.58 MB/s
btape: btape.c:379-0 Total Volume bytes=3.221 GB. Total Write rate = 73.21 MB/s

btape: btape.c:959-0 Begin writing 3 files of 2.147 GB with blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 93.37 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 85.90 MB/s
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 89.48 MB/s
btape: btape.c:379-0 Total Volume bytes=6.442 GB. Total Write rate = 89.48 MB/s

btape: btape.c:959-0 Begin writing 3 files of 4.294 GB with blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 97.61 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 99.88 MB/s
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 97.61 MB/s
btape: btape.c:379-0 Total Volume bytes=12.88 GB. Total Write rate = 98.35 MB/s

btape: btape.c:1093-0 Test with random data, should give the minimum throughput.
btape: btape.c:959-0 Begin writing 3 files of 1.073 GB with blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 41.30 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 39.77 MB/s
+++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=1.073 GB. Write rate = 41.30 MB/s
btape: btape.c:379-0 Total Volume bytes=3.221 GB. Total Write rate = 40.77 MB/s

btape: btape.c:959-0 Begin writing 3 files of 2.147 GB with blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 45.69 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 44.74 MB/s
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=2.147 GB. Write rate = 44.74 MB/s
btape: btape.c:379-0 Total Volume bytes=6.442 GB. Total Write rate = 45.05 MB/s

btape: btape.c:959-0 Begin writing 3 files of 4.294 GB with blocks of 64512 bytes.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 45.69 MB/s
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 49.94 MB/s
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
btape: btape.c:606-0 Wrote 1 EOF to "LTO-4" (/dev/nsa0)
btape: btape.c:405-0 Volume bytes=4.295 GB. Write rate = 51.13 MB/s
btape: btape.c:379-0 Total Volume bytes=12.88 GB. Total Write rate = 48.80 MB/s

*quit

I am pretty sure that this line of SAS controller doesn't like tape drives in general as evidenced by the following tests I performed:

  • I swapped the SmartArray P400 for another controller of the same kind with equal results sans the PCI-E LL correctable errors.
  • I swapped the cable for another one, same result.
  • I attached a hard disk drive to the SmartArray P400 card, it worked without problems.
answered on Super User May 13, 2017 by FUZxxl

User contributions licensed under CC BY-SA 3.0