StoreEver Tape Storage
1753331 Members
5290 Online
108792 Solutions
New Discussion юеВ

Re: How to enable hw compression on Ultrium 1760 using linux tools

 
Sakis Bouzanis
New Member

How to enable hw compression on Ultrium 1760 using linux tools

Hi

We recently purchased an lto 4 ultrium 1760
sas external. I'm trying to figure out how to enable hw compression under ubuntu 8.04.

More specifically, I'm using the gnu-tar
v. 1.19 and the mt-st suite v. 0.9b

here's the output of 'mt status' for reference:

mt -f /dev/nst0 status

SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x46 (no translation).
Soft error count since last status=0
General status bits on (41010000):
BOT ONLINE IM_REP_EN

When issuing the compression command with mt
(mt -t /dev/nst0 compression 1) I get no
response at all. I assume this is normal
since mt is silent generally, but this leaves
me wondering.

* What is the correct mt option for the 1760
to enable (or make sure it's enabled)
the hw compression?
* Is there a way to verify the acceptance
of the command?

I'm aware of the ltt tool suite which could
be of help, but unfortunately it's precompiled
for the mainstream distros only.

I forgot to mention that everything works
perfectly with tar and mt. I just got thinking
that hw might not be enabled when I didn't
managed to go over 840GB on my first backup,
which consists mainly of hundredths
of thousands of video frames (e.g 150000
video frames) with each frame having a data
size of around 8MB.

Thanks in advance

Sak - 2|35
4 REPLIES 4
Kewl Eugene
Occasional Contributor

Re: How to enable hw compression on Ultrium 1760 using linux tools

I could be mistaken but I think compression is always on the LTO drives, and the DDS drives too.
Sakis Bouzanis
New Member

Re: How to enable hw compression on Ultrium 1760 using linux tools

It could be the case. I'm just looking for confirmation.

Thanks
Yann Nave
New Member

Re: How to enable hw compression on Ultrium 1760 using linux tools

Did you find an answer ?

I've the same problem here....

Sakis Bouzanis
New Member

Re: How to enable hw compression on Ultrium 1760 using linux tools

Hi Yann

Yes, I got a (partial) answer indirectly, following someone else's adventures on a similar subject, which ended with a set
of utilities called sg3-utils.

Among these utilities there's one called:
sg_logs. As the name suggests, it queries
a scsi device and gets all sorts of info.
The info is organized in pages, with some
pages implemented and some not, depending
on the device manufacturer, device type
(i.e hdd, tape), etc.

Of interest in this case is page 12 which
can be looked up like this:
sg_logs /dev/nst0 -p 12
It contains 4 lines (if I remember well),
two of which reveal how many bytes were
send to the device with "write" commands
and how many bytes were ultimately written
to the tape media.

There, I saw that the drive was indeed compressing. I had send 840GB to the drive
and the the data written to tape were 710GB.

So the tape IS compressing by default.
How well? Depends on your data. With text
you might get the 2:1 ratio HP advertises.
But with video, the best I managed to get
was something like 1.5:1 with certain codecs.
The usual case with dpx frames though was
more like 1.15:1, and in one case I got more
data written to tape than the size of the
file I had send, despite HP advertising that
the compression algorithm shuts it self down
when it can't compress reliably, to avoid
such occurrences.

I didn't tried to turn of compression to see
what happens, as I need it anyway, but I read
somewhere that LTO4 devices might not be able
to turn compression off. I don't know...

I also found that the tape medium will go
up to 830GB of (in my case) compressed data.
This was the case with all my first 6 tapes.

The sg_log command deserves exploring and
can be installed on (k)ubuntu from the repos.
The package name is "sg3_utils".

Hope this helps a bit.

Sak