12.4 Setting Directory Quotas on DST Volumes

Directory quotas limit the space available in an individual NSS directory. In a DST volume pair, the directory quota set on the directory instance on the primary volume functions separately from the directory instance on the secondary volume. Before you can add quotas using the ncpcon quotas command, you must enable the Directory Quotas attribute for the primary volume and the secondary volume.

In NSS, each directory’s quota information is stored as metadata with the directory in the file system. If there is no directory quota, no information is stored. Only directories with active quota settings have quota information. If you disable space restrictions for a directory, NSS automatically removes the quota setting from the directory. If you set a directory quota to a very large value (or unlimited), you effectively remove space restrictions from the directory, and the directory still has an active quota setting.

In order to remove space restrictions on the directory instance on the secondary volume, you can set an unlimited quota for the directory instance on the primary volume, and synchronize the unlimited setting to the secondary volume. The setting can be larger than the secondary volume’s maximum size, but the directory’s maximum size will be limited to the secondary volume’s actual maximum size and space availability when the quota is enforced.

  1. Verify that the Directory Quotas attribute is enabled on each volume.

    1. In iManager, select Storage > Volumes.

    2. Click the Search icon, then browse to select a server to manage.

    3. In the Volumes list, select the volume, then wait for the volume’s details to be displayed.

    4. Click Properties.

    5. On the Attributes tab, verify that the Directory Quotas check box is selected. If it is deselected, select it, then click Apply.

    6. Repeat Step 1.c to Step 1.e to verify that the Directory Quotas attribute is selected on the secondary volume.

  2. Add, modify, or remove directory quotas for the instance of the directory on the primary volume.

    For more information, see Managing Directory Quotas in the OES 2015 SP1: NSS File System Administration Guide for Linux.

    1. In iManager, open the Properties page for the folder instance on the primary volume. You can use either of the following methods:

      • Files and Folders:

        1. In Roles and Tasks, select Files and Folders > Properties.

        2. On the Properties page, click the Search icon, then browse to select the folder you want to manage.

        3. Click OK to open the Properties page for the folder.

      • Tree View:

        1. In the iManager toolbar, click the View Objects icon.

        2. In the Tree View, click the Browse tab in the left panel.

        3. Browse the tree to locate and select the folder you want to manage.

        4. In the right panel, select the check box next to the folder, then select Actions > Properties.

    2. On the Information tab of the folder’s Properties page, view the current status of the directory quota.

      If a Directory Quota is set, the Restrict Size field is selected and the Limit field shows the quota size (in KB, MB, GB, TB, or PB).

      If the Directory Quota is not set, the Restrict Size field is deselected and the Limit field is dimmed (grayed out).

    3. Do one of the following:

      • Add directory quota: On the Information tab, select Restrict Size to enable space restrictions for the selected directory. In the Limit field, type the directory quota in KB, MB, GB, TB, or PB.

      • Modify a directory quota: On the Information tab, the Restrict Size check box should already be selected. In the Limit field, type the new directory quota in KB, MB, GB, TB, or PB.

      • Set an unlimited directory quota: On the Information tab, select Restrict Size to enable space restrictions for the selected directory. In the Limit field, type the new directory quota in KB, MB, GB, TB, or PB. For example, you can set a value that exceeds the volume size.

        You might set the quota as unlimited instead of disabling the quota if you need to remove the directory quota on the secondary volume. The setting can be larger than the secondary volume’s maximum size, but the directory’s maximum size will be limited to the secondary volume’s actual maximum size and space availability when the quota is enforced.

      • Remove a directory quota: On the Information tab, deselect Restrict Size to disable space restrictions for the selected directory. The Limit field is automatically dimmed (grayed out). The quota information is removed from the directory metadata.

        A deleted quota for a directory cannot be synchronized to the secondary volume. In order to remove space restrictions for a directory on the secondary volume, set an unlimited quota for the directory instance on the primary volume, and then synchronize the unlimited quota setting to the secondary volume.

    4. On the Information page, click Apply or OK to apply the changes.

    5. Repeat Step 2.a to Step 2.d for each directory where you want to set a quota on the primary volume.

  3. Synchronize the directory space quotas settings from the primary volume to the secondary volume.

    1. Log in as the root user to the server, then open a terminal console.

    2. Use the ncpcon quotas sync command to synchronize the directory quotas from the primary volume to the secondary volume.

      ncpcon quotas sync <ALL|MISSING|PERCENT> <primary_volume_name> [percent_value] d [q]

      For example, using the ALL option synchronizes all directory quotas settings from the primary volume to the secondary volume:

      ncpcon quotas sync ALL VOLD d

      Using the PERCENT option with a percent value of 200 assigns a quota for the instance of the directory on the secondary volume that is twice the size of the quota set on the primary volume.

      ncpcon quotas sync PERCENT VOLD 200 d

      For command information and other examples, see Section 12.2, NCPCON Quotas Command.

  4. (Optional) In iManager, modify the space quota for the directory instance on the primary volume.

    It is not required that the directory be assigned the same space quota on the primary volume as on the secondary volume. However, if you change it, the next time you synchronize the directory quotas, the modified directory quota is applied to the secondary volume if you use the ALL or PERCENT options. In order to synchronize directory quotas only for secondary directories that do not have a quota set, use the MISSING option.

NOTE:To manage directory quotas for AD users using NFARM, see Information in the OES 2015 SP1: NSS AD Administration Guide.