Disclaimer

Sunday 11 July 2021

What is ASM Quota Groups for Oracle ASM File Groups

 

What is ASM Quota Groups for Oracle ASM File Groups

A quota group defines the quota allocated to a group of Oracle ASM File Groups. A file group belongs to only one quota group. A Quota Group on a  File Group applies limit on the on space a file group can use from the diskgroup with which this quota group is associated.

Important notes about quota groups for file groups.
  1. A file group can belong to only one quota group.
  2. A quota group cannot span multiple disk groups.
  3. A quota group describes an aggregate of space used by one file group or multiple file groups in the same disk group.
  4. The quota is enforced when a file is created and resized.
  5. A quota is a physical space.
  6. Each quota group has two values: the limit and the current used space.If the limit value set below the current used space. This action prevents any additional space being allocated for files described by file groups associated with this quota group.
  7. A file group can be moved from one quota group to another, regardless whether or not the target quota group has enough space for the file group.

How to Add a Quota Group to a Disk Group

SQL> ALTER DISKGROUP DG_FLEX_DATA ADD QUOTAGROUP QG_PDB1 SET 'quota'= 5g;
Diskgroup altered.

How to Move a File Group From One Quota Group To Another

I have a file group FG_PDB1 in Quota Group GENERIC. I would like to move it to QG_PDB1

ASMCMD> lsfg
File Group         Disk Group    Quota Group  Used Quota MB  Client Name  Client Type
DEFAULT_FILEGROUP  DG_FLEX_DATA  GENERIC      0
FG_PDB1            DG_FLEX_DATA  GENERIC      0              PDB1         DATABASE


SQL> ALTER DISKGROUP DG_FLEX_DATA MODIFY FILEGROUP FG_PDB1 SET 'quota_group' = 'QG_PDB1';
Diskgroup altered.

SQL> SELECT FI.NAME,FI.INCARNATION,QO.NAME FROM V$ASM_FILEGROUP FI,V$ASM_QUOTAGROUP QO WHERE FI.QUOTAGROUP_NUMBER=QO.QUOTAGROUP_NUMBER AND FI.NAME='FG_PDB1'; 


NAME                 INCARNATION NAME
-------------------- ----------- --------------------
FG_PDB1                        1 QG_PDB1





No comments:

Post a Comment

100 Oracle DBA Interview Questions and Answers

  Here are 100 tricky interview questions tailored for a Senior Oracle DBA role. These questions span a wide range of topics, including perf...