public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: bugzilla-daemon@bugzilla.kernel.org
To: linux-scsi@vger.kernel.org
Subject: [Bug 212183] New: st read statistics inaccurate when requested and physical block mismatch
Date: Tue, 09 Mar 2021 14:34:00 +0000	[thread overview]
Message-ID: <bug-212183-11613@https.bugzilla.kernel.org/> (raw)

https://bugzilla.kernel.org/show_bug.cgi?id=212183

            Bug ID: 212183
           Summary: st read statistics inaccurate when requested and
                    physical block mismatch
           Product: IO/Storage
           Version: 2.5
    Kernel Version: 5.3.1
          Hardware: All
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: low
          Priority: P1
         Component: SCSI
          Assignee: linux-scsi@vger.kernel.org
          Reporter: etienne.mollier@cgg.com
        Regression: No

Created attachment 295769
  --> https://bugzilla.kernel.org/attachment.cgi?id=295769&action=edit
st.c patch working around stats issue when blocks size mismatch

Greetings,

when reading from tape with requested blocks larger than physical, statistics
go wrong as using the requested size for the calculation, instead of the actual
size of the block returned.  So, when running `dd if=/dev/st0 bs=10240
of=/dev/null`, a tool such as `tapestat` will work out the bandwidth using the
bs=10240.  However, if the block on tape was of size 1024, then the metric
would go wrong by a factor 10.

Most configurations won't notice, as tapes are usually fixed size block,
typically for backup use case.  However on our end, the problem exacerbates due
to reading field acquisition cartridges with varying block size.  We are
currently working this around with the patch in attachment.

While we've observed the issue on a somewhat old kernel revision, checking out
the "master" branch of the linux tree, we believe this is present since
introduction of the capability in Linux 4.2, and likely to reappear with more
recent kernel revisions if left as-is.

Kind Regards,
Étienne.

-- 
You may reply to this email to add a comment.

You are receiving this mail because:
You are the assignee for the bug.

             reply	other threads:[~2021-03-09 14:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-09 14:34 bugzilla-daemon [this message]
2021-03-11 18:41 ` [Bug 212183] New: st read statistics inaccurate when requested and physical block mismatch "Kai Mäkisara (Kolumbus)"
2021-03-11 18:42 ` [Bug 212183] " bugzilla-daemon
2021-03-12 16:50 ` bugzilla-daemon
2021-03-12 16:58 ` bugzilla-daemon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-212183-11613@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@bugzilla.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox