Extending an ASM Datafile


The following example shows how to extend a datafile to the APP_DATA tablespace in the +DATA ASM group.
1. Identify the datafiles for the tablespace you want to increase.

SQL> select file_name,bytes/1024/1024 mb
aaaaaafrom dba_data_files
aaaaaawhere tablespace_name = ‘APP_DATA’
aaaaaaorder by file_name;

FILE_NAMEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaMB
———————————————————— ——-
+DATA/SID/datafile/app_data.259.669898683aaaaaaaaaaaaaaaa20000
+DATA/SID/datafile/app_data.267.636216519aaaaaaaaaaaaaaaa28100

2. Extened the Datafile

SQL> alter database datafile ‘+DATA/SID/datafile/app_data.259.669898683’ resize 30000m;

Tablespace altered.


Adding an ASM Datafile
The following example shows how to add a datafile to the APP_DATA tablespace in the +DATA ASM group.
1. Find out where the current datafiles are defined. In this example the ASM group is +STORE1.

SQL> select file_name,bytes/1024/1024 mb
aaaaaafrom dba_data_files
aaaaaawhere tablespace_name = ‘APP_DATA’
aaaaaaorder by file_name;

2. Add the datafile.

SQL> alter tablespace APP_DATA add datafile ‘+DATA’ size 20000m;

Tablespace altered.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: