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

lfs quota should show quota allocation rather than used

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 1.8.6
    • None
    • Lustre 1.8.6 clients
    • 3
    • 4787

    Description

      lfs quota give actual used rather than what has been allocated. But what is allocated what really effects the user. Here is an example

      sh-3.2# lfs quota -u treddy /nobackupp30
      Disk quotas for user treddy (uid 10787):
      Filesystem kbytes quota limit grace files quota limit grace
      /nobackupp30 208932428 210000000 420000000 - 14641 75000 100000 -

      This shows that he is under his soft quota. But if we look at what he is allocated

      pbspl1 ~ # lfs quota v -u treddy /nobackupp30 | awk '$2 == ""

      { sumu = sumu + $1; suma = suma + $3 }

      END

      { print sumu, suma, "\n" }

      '
      > 208932428 220463104

      We see that his allocation (220,463,104) is over the softlimit (210,000,000). Therefore his grace time has been accumulating and in fact it is expired.

      I have a modified version of lfs tool that does a better job of providing the quota info.

      bash-3.2# /usr/local/bin/lfs.nas quota -v -u treddy /nobackupp30
      Disk quotas for user treddy (uid 10787):
      Filesystem kbytes quota limit grace files quota limit grace
      /nobackupp30 208932428* 210000000 420000000 None 14641 75000 100000 -
      nbp30-MDT0000_UUID
      6844 - 131072 - 14641 - 20480 -
      nbp30-OST0000_UUID
      2352640 - 2490368 - - - - -
      nbp30-OST0001_UUID
      1963180 - 2097152 - - - - -
      ...

      nbp30-OST0076_UUID
      2860332 - 3014656 - - - - -
      nbp30-OST0077_UUID
      1344680 - 1441792 - - - - -
      ------- -------
      Total 208932428 220463104

      We see here that he has no grace time left and the softlimit has turn into a hardlimit. In order to reset his grace time he must delete enough data to drop his allocation below his softlimit. In this case it would be ~10,217 MB.

      So it would be better to show total allocated in the lfs quota output. Example in this case should be

      Disk quotas for user treddy (uid 10787):
      Filesystem kbytes quota limit grace files quota limit grace
      /nobackupp30 220463104* 210000000 420000000 None - 14641 75000 100000 -

      Attachments

        Issue Links

          Activity

            People

              niu Niu Yawei (Inactive)
              mhanafi Mahmoud Hanafi
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: