Monday, January 23, 2012

ORA-04031: unable to allocate N bytes of shared memory

This error can we fixed by increasing shared pool memory.

Or you can flush your shared pool memory ,If the size is already High

SQL>alter system flush shared_pool;

You can increase shared pool size(shared_pool_size) using parameter file(INIT.ORA)

Or you can dynamically increase your size by

SQL>ALTER SYSTEM SET SHARED_POOL_SIZE=1200M SCOPE=BOTH;

Wednesday, January 11, 2012

Last SQL statement on each SCHEMA

We can calculate late executed statement using below query.

select j.sql_text,y.username
from v$session y, v$sqlarea j
where j.hash_value = y.prev_hash_value



Cheers.

Sunday, January 8, 2012

ORA-12518: TNS:listener could not hand off client connection

ORA-12518: TNS:listener could not hand off client connection

In a shared server environment .


Shutdown the dispatcher and add new dispatchers.
SQL> show parameter dispatchers
SQL> select name from v$dispatcher;
SQL> alter system shutdown immediate 'D001';
Add new dispatcher
SQL> alter system set DISPATCHERS = '(protocol=tcp)(dispatchers=4)';


In dedicated Server.


PGA is fully allocated for all processes.Check PGA memory allocation.
SQL> SELECT * FROM V$PROCESS ORDER BY PGA_ALLOC_MEM DESC

Kill unnecessary Sessions for freed PGA memory



Cheers...!!!