---count machine connected
select count (*),machine from V$session group by machine
-------- deadloack counts
path:/oraUB/admin/UB46BF35/udump
ls *.trc|wc -l
DEADLOCK DETECTED ( ORA-00060 )
two types of deadlocks:
transaction:solution application design
session head : solution inittrans
---- shut down oracle
oracle user id login
export oracle_sid = dbname
sqlplus / as sysdba
shutdown immediate
start oracle
startup
alternate:
sqlplus /nolog
connect sys as sysdba
password:oracle
----- import of full oracle
impdp system/oracle directory=DPUMP_DIR dumpfile=opics.dmp logfile=opics_110210.log FULL =Y
---oracle table export
expdp wasadmin/wasadmin TABLES=bankfusion.BFTB_TASK,bankfusion.BFTB_TASKLIST,bankfusion.BFTB_TASKMESSAGE,bankfusion.BFTB_TASKMSGRECIPNT,bankfusion.BFTB_TASKGROUP directory=DPUMP_DIR
------------oracle explain plan
explain plan for
--QUERY
SELECT PLAN_TABLE_OUTPUT FROM TABLE(DBMS_XPLAN.DISPLAY());
---Run the same query against multiple SQL Server AND Oracle instances - This may come handy.
http://www.pythian.com/news/4683/run-the-same-query-against-multiple-sql-server-and-oracle-instances
----Execute as user system
select to_char(max(last_analyzed),'dd mm yyyy:hh.mi.ss') from dba_tables
where owner like 'WAS%'
If you have imported DB afresh, please run the runstats script available in SVN. Next time onwards stats gathering will be done automatically every night by Oracle itself.
---DPUMP_DIR /oracle/admin/mmdb/dpump_dest
No comments:
Post a Comment