Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SYSTEM/SYSAUX tablespace analysis - 98% used

Status
Not open for further replies.

nhenriqu

IS-IT--Management
Sep 20, 2007
1
CA
I have an Oracle 10g based application which reports 98 and 99% used (size) for the SYSAUX and SYSTEM tablespaces. The vendor is aware but indicates the files do not grow and should not be a concern. However, we are experiencing extremely slow responses with the application and my own view is that anything that the tablespaces appear to be "maxed" out and may be contributing to the performance degradation. I'm not a Oracle 10g expert, so I am looking for some possible thoughts and recommendations.
Thx NH
 
nhenriqu,

Reaching "98% used" for a tablespace does not necessarily indicate a problem. There are several issues that contribute to whether or not "98% used" is an issue.

So that we can get a complete picture of your situation, please post the results of your running the following script (as a DBA):
Code:
set echo on
REM **************************************************************
REM David L. Hunt (file author) distributes this and other 
REM files/scripts for educational purposes only, to illustrate the 
REM use or application of various computing techniques. Neither the 
REM author nor Dasages, LLC, makes any warranty regarding this 
REM script's fitness for any industrial application or purpose nor is 
REM there any claim that this or any similarly-distributed scripts 
REM are error free or should be used for any purpose other than
REM illustration.
REM **************************************************************
set echo off
set linesize 165
set pagesize 40
set heading on
col fname heading "Filename" format a60
col fnum heading "#" format 999
col ts heading "Tablespace|Name" format a15
col tb heading "Total|Potential|File Size" format 999,999,999,999
col cb heading "Total|Current|File Size" like tb
col used heading "Bytes Used" like tb
col free heading "Potential|Bytes Free" like tb
col autoext heading "Auto|Ext." format a4
col percentfree heading "% Free|of|Pot.|Total|Bytes" format 999
break on report
compute sum of tb cb used free on report
spool TablespaceUsage.txt
select	substr(tablespace_name,1,15) ts
	,d.file_id fnum
	,decode(e.file#,null,d.bytes,(e.maxextend * blksize)) tb
	,d.bytes cb
	,decode(d.bytes,0,0,d.bytes-nvl(freebytes,0)) used
	,decode(e.file#,null,d.bytes,(e.maxextend * blksize))
	 -decode(d.bytes,0,0,d.bytes-nvl(freebytes,0)) free
	,trunc(((decode(e.file#,null,d.bytes,(e.maxextend * blksize))
	  -decode(d.bytes,0,0,d.bytes-nvl(freebytes,0)))/
	   decode(e.file#,null,d.bytes,(e.maxextend * blksize))
         ),2) * 100 percentfree
	,decode(e.file#,null,'No','Yes') autoext
	,''''||substr(file_name,1,55)||'''' fname
from 	sys.dba_data_files d
	,(select file_id,sum(bytes) freebytes
		from sys.dba_free_space
		group by file_id) f
	,sys.filext$ e
	,v$datafile v
	,(select value blksize from v$parameter
		where name = 'db_block_size') b
where	d.file_id=f.file_id(+)
  and	d.file_id=e.file#(+)
  and	v.file#=d.file_id
order by tablespace_name,creation_time
/
spool off
prompt
prompt Note: Physical disk limitations may prevent an AUTOEXTEND-ing file from reaching its potential
prompt
prompt Wrote spool file "TablespaceUsage.txt".
prompt
Let us know your findings.

[santa]Mufasa
(aka Dave of Sandy, Utah, USA)
[I provide low-cost, remote Database Administration services: www.dasages.com]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top