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

Option to set max stripe count per filesystem

Details

    • New Feature
    • Resolution: Fixed
    • Major
    • Lustre 2.15.0
    • Lustre 2.7.0
    • 9223372036854775807

    Description

      We have users that will set stripe count by using "-1" as in
      lfs setstripe -c -1

      Filesystem with small number of OSTs (~200) this was ok. But as our OST count get lager (>400) this is not always desirable. Most of the time we don't want our users to set stripe counts so large. We would like config option for max default size setting for (lfs setstripe -c -1). But would still like the ability to allow setting stripe counts upto LOV_MAX_STRIPE_COUNT for those who really need it.

      Attachments

        Issue Links

          Activity

            [LU-9162] Option to set max stripe count per filesystem
            pjones Peter Jones added a comment -

            Landed for 2.15

            pjones Peter Jones added a comment - Landed for 2.15

            "Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/45532/
            Subject: LU-9162 lod: option to set max stripe count per filesystem
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: 3c9580931d1a7753e6c03900df01fd05ab3ca73d

            gerrit Gerrit Updater added a comment - "Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/45532/ Subject: LU-9162 lod: option to set max stripe count per filesystem Project: fs/lustre-release Branch: master Current Patch Set: Commit: 3c9580931d1a7753e6c03900df01fd05ab3ca73d

            "Feng, Lei <flei@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/45532
            Subject: LU-9162 lod: option to set max stripe count per filesystem
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: 80534f98629dedaeb381757e97f8c9d7bf62ac0c

            gerrit Gerrit Updater added a comment - "Feng, Lei <flei@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/45532 Subject: LU-9162 lod: option to set max stripe count per filesystem Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 80534f98629dedaeb381757e97f8c9d7bf62ac0c

            Yes, definitely. You can copy stripeoffset_show() and stripeoffset_store() to print/store the parameter in lod_device.

            adilger Andreas Dilger added a comment - Yes, definitely. You can copy stripeoffset_show() and stripeoffset_store() to print/store the parameter in lod_device.
            flei Feng Lei added a comment -

            Is is OK to make the max_stripe_count a member of lod_device?

            flei Feng Lei added a comment - Is is OK to make the max_stripe_count a member of lod_device?

            flei, I don't think this needs locking, because it is "racy" even with a lock. The value could be accessed a microsecond before or after the value is changed by the user, so having a lock won't help that. It will only affect the one file being created at the time it is checked, and does not really need to be consistent from one file to the next.

            Also, this does not really need to be part of lov_desc, which was the old/original way to set the default "plain" layout of the filesystem, but has been deprecated with the introduction of more complex PFL/FLR layouts. It would be better to make this a normal sysfs tunable that can be set with "lctl set_param [-P] lod.*.max_stripe_count".

            adilger Andreas Dilger added a comment - flei , I don't think this needs locking, because it is "racy" even with a lock. The value could be accessed a microsecond before or after the value is changed by the user, so having a lock won't help that. It will only affect the one file being created at the time it is checked, and does not really need to be consistent from one file to the next. Also, this does not really need to be part of lov_desc, which was the old/original way to set the default "plain" layout of the filesystem, but has been deprecated with the introduction of more complex PFL/FLR layouts. It would be better to make this a normal sysfs tunable that can be set with " lctl set_param [-P] lod.*.max_stripe_count ".
            flei Feng Lei added a comment -

            one more question is where to put the lock?

            flei Feng Lei added a comment - one more question is where to put the lock?

            People

              flei Feng Lei
              mhanafi Mahmoud Hanafi
              Votes:
              0 Vote for this issue
              Watchers:
              12 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: