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

zero length xattrs handled incorrectly when xattr cache disabled or bypassed

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 2.12.0
    • None
    • 3
    • 9223372036854775807

    Description

      When xattr caching is disabled or bypassed extended attributes with zero length values are not handled correctly:

      o:~# cd /mnt/lustre
      o:lustre# lctl set_param llite.*.xattr_cache=1
      llite.lustre-ffff8c4ac8a60000.xattr_cache=1
      o:lustre# rm -f f0
      o:lustre# touch f0
      o:lustre# setfattr -n user.blah f0
      o:lustre# getfattr -d -m- f0
      # file: f0
      lustre.lov=0s0AvRCwEAAAADAAAAAAAAAAEEAAACAAAAAAAQAAEAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=
      trusted.link=0s3/HqEQEAAAAsAAAAAAAAAAAAAAAAAAAAABQAAAACAAAABwAAAAEAAAAAZjA=
      trusted.lma=0sAAAAAAAAAAABBAAAAgAAAAMAAAAAAAAA
      trusted.lov=0s0AvRCwEAAAADAAAAAAAAAAEEAAACAAAAAAAQAAEAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=
      trusted.version=0sDAAAAAEAAAA=
      user.blah
      
      o:lustre# lctl set_param llite.*.xattr_cache=0
      llite.lustre-ffff8c4ac8a60000.xattr_cache=0
      o:lustre# getfattr -d -m- f0
      # file: f0
      lustre.lov=0s0AvRCwEAAAADAAAAAAAAAAEEAAACAAAAAAAQAAEAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=
      trusted.link=0s3/HqEQEAAAAsAAAAAAAAAAAAAAAAAAAAABQAAAACAAAABwAAAAEAAAAAZjA=
      trusted.lma=0sAAAAAAAAAAABBAAAAgAAAAMAAAAAAAAA
      trusted.lov=0s0AvRCwEAAAADAAAAAAAAAAEEAAACAAAAAAAQAAEAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=
      trusted.version=0sDAAAAAEAAAA=
      f0: user.blah: No such attribute
      
      

      I noticed this while looking at LU-11074 but this is not the underlying cause of that bug.

      Attachments

        Activity

          [LU-11109] zero length xattrs handled incorrectly when xattr cache disabled or bypassed
          pjones Peter Jones added a comment -

          Landed for 2.12

          pjones Peter Jones added a comment - Landed for 2.12

          Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/32755/
          Subject: LU-11109 mdt: handle zero length xattr values correctly
          Project: fs/lustre-release
          Branch: master
          Current Patch Set:
          Commit: 1e4164a1254d7fb75e49af73994d2e53864536ab

          gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/32755/ Subject: LU-11109 mdt: handle zero length xattr values correctly Project: fs/lustre-release Branch: master Current Patch Set: Commit: 1e4164a1254d7fb75e49af73994d2e53864536ab
          jhammond John Hammond added a comment -

          The first change is logically independent of the others but they should be used together for LU-11074.

          jhammond John Hammond added a comment - The first change is logically independent of the others but they should be used together for LU-11074 .

          John are the patches a series or independent?

          simmonsja James A Simmons added a comment - John are the patches a series or independent?

          John L. Hammond (jhammond@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/32755
          Subject: LU-11109 mdt: handle zero length xattr values correctly
          Project: fs/lustre-release
          Branch: master
          Current Patch Set: 1
          Commit: c4a00691479e245a2134dc03574448c652e38f13

          gerrit Gerrit Updater added a comment - John L. Hammond (jhammond@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/32755 Subject: LU-11109 mdt: handle zero length xattr values correctly Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: c4a00691479e245a2134dc03574448c652e38f13

          People

            jhammond John Hammond
            jhammond John Hammond
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: