Question : how to increase the table space

Hi
Gurs

I have attchaed the table space list which are having in my database , As iam new to the DBA please can any one suggest  me , the table space percentage is showing 99% for some of the tablespaces, Please can you suggest the remedies which i need to take,Please help
we are using oracle9i database.And also can u give me detail steps to rebuild the index on table , and to create the partion of the table .our database size is 200GB.

Thanks
Attachments:
 
tablespace size
 

Answer : how to increase the table space

You have to increase size of datafiles in your tablespaces or add new data files to your tablespaces, if for instance maximum datafile size is reached (32 GB under Windows).

Increase Size of a datafile:

ALTER DATABASE DATAFILE <<path/filename>> RESIZE <<newsize>>
e. g.:
ALTER DATABASE DATAFILE 'E:\DATA\DATAFILE01.DBF' RESIZE 18000M

Add datafile to a tablespace:

ALTER TABLESPACE <<tablespace_name>> ADD DATAFILE <<path and filename>> SIZE <<initial_size>> AUTOEXTEND OFF;

e. g. :
ALTER TABLESPACE A ADD DATAFILE 'E:\DATA\DATAFILE02.DBF' SIZE 5000M AUTOEXTEND OFF;

You can also set AUTOEXTEND ON for any data file, so data files will increase automatically if space is needed:

ALTER DATABASE DATAFILE <<path and filename>> AUTOEXTEND ON NEXT <<size to increase>>
MAXSIZE UNLIMITED;

e. g. :
ALTER DATABASE DATAFILE 'E:\DATA\DATAFILE02.DBF' AUTOEXTEND ON NEXT 500M MAXSIZE UNLIMITED;

Datafile will automatically increment by 500 MB until MAXSIZE, if space is needed...

Steps, you have to do:
1.)
Check if AUTOEXTEND ON is already set for your tablespace datafiles:

SELECT FILE_NAME,TABLESPACE_NAME,BYTES,AUTOEXTENSIBLE,
MAXBYTES,INCREMENT_BY
FROM DBA_DATA_FILES;

2.)
if AUTOEXTENSIBLE and maximum size of datafiles is reached (32 GB under Windows),  add new datafiles to tablespace
if not AUTOEXTENSIBLE increase size of datafiles and/or add new datafiles to tablespace; set AUTOEXTEND ON for datafiles, which you want to increment automatically

For detailled information see oracle Oracle9i Database Administrator's Guide / Managing Tablespace as Audhi203 already mentioned above:
http://download.oracle.com/docs/cd/B10501_01/server.920/a96521/tspaces.htm

To rebuild an index use ALTER INDEX ... REBUILD:
ALTER INDEX <index-name> REBUILD TABLESPACE <index-tablespace>
e. g. :
ALTER INDEX schema1.idx1 REBUILD TABLESPACE A

For further information please see Oracle9i Database Administrator's Guide / Managing Indexes:
http://download.oracle.com/docs/cd/B10501_01/server.920/a96521/indexes.htm#10473




Random Solutions  
 
programming4us programming4us