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

mb_prealloc_table table read/write code is racy

Details

    • Bug
    • Resolution: Fixed
    • Critical
    • Lustre 2.13.0
    • None
    • None
    • 3
    • 9223372036854775807

    Description

      Preallocation table read/write code is racy. There is a  possibility of accessing memory outside of allocated table.
      This issue can be easy reproduced. I am not sure, I have to upload test that lead to test system to be crashed. So I put it here.
       
      dd if=/dev/zero of=<path_to_ldiskfs_partition> bs=1048576 count=1024 conv=fsync
      cat "32 64 128 256" > /proc/fs/ldiskfs/<dev>/prealloc_table

      Attachments

        Issue Links

          Activity

            [LU-12335] mb_prealloc_table table read/write code is racy

            No need send this patch to ext4 upstream because no such bug there. Bug was introduced in our ldiskfs patches.

            artem_blagodarenko Artem Blagodarenko (Inactive) added a comment - No need send this patch to ext4 upstream because no such bug there. Bug was introduced in our ldiskfs patches.

            Please make sure this is push to the ext4 maintainers.

            simmonsja James A Simmons added a comment - Please make sure this is push to the ext4 maintainers.
            pjones Peter Jones added a comment -

            As per recent LWG discussion this ticket should be marked as RESOLVED and anyone wanting to keep SLES/Ubuntu servers in sync should do that under a separate ticket

            pjones Peter Jones added a comment - As per recent LWG discussion this ticket should be marked as RESOLVED and anyone wanting to keep SLES/Ubuntu servers in sync should do that under a separate ticket
            simmonsja James A Simmons added a comment - - edited

            This fix was only every applied to RHEL platforms. SLES and Ubuntu lack this fix.

            simmonsja James A Simmons added a comment - - edited This fix was only every applied to RHEL platforms. SLES and Ubuntu lack this fix.
            pjones Peter Jones added a comment -

            Landed for 2.13

            pjones Peter Jones added a comment - Landed for 2.13

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/34950/
            Subject: LU-12335 ldiskfs: fixed size preallocation table
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: f15995b8e52bafabe55506ad2e12c8a64a373948

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/34950/ Subject: LU-12335 ldiskfs: fixed size preallocation table Project: fs/lustre-release Branch: master Current Patch Set: Commit: f15995b8e52bafabe55506ad2e12c8a64a373948

            People

              artem_blagodarenko Artem Blagodarenko (Inactive)
              artem_blagodarenko Artem Blagodarenko (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: