Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-12585

obdfilter read_bytes stat reports requested read bytes and not actual read bytes

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 2.15.0
    • Lustre 2.10.7, Lustre 2.12.1
    • None
    • 3
    • 9223372036854775807

    Description

      obdfilter.*.stats has a read_bytes metric. This metrics reports the number of requested bytes, and not what I was expecting, what was actually read bytes from the OST.

      By example, if you have a 1MB file, and you try to read 16MB from it, the{{ read_bytes}} will likely reports 16MB and not 1MB.

      To reproduce:

      # llmount.sh
      
      # dd if=/dev/zero of=/mnt/lustre/dump bs=1M count=1
      # lctl set_param -n ldlm.namespaces.*.lru_size=clear
      
      # dd if=/mnt/lustre/dump of=/dev/null bs=16M count=1
      # lctl get_param obdfilter.*.stats | grep read_bytes
      read_bytes 4 samples [bytes] 4194304 4194304 16777216
       

      I think this comes from the fact that the stats is updated at I/O preparation, and not I/O completion.

      Is this intended? I think we should either:

      • Fix the stat to store the actual read bytes
      • Or, add a second stat to store the actual read bytes if we don't want to change this one

      Attachments

        Issue Links

          Activity

            People

              paf0186 Patrick Farrell (Inactive)
              degremoa Aurelien Degremont (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: