This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Meta-Information ============================================================= | |
| Site Name: | |
| Site URL: | |
| Client: | |
| Client Point of Contact: | |
| Client Services Point of Contact: | |
| Design Phase ================================================================= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| sudo ln -s /usr/local/bin/node /usr/bin/node | |
| sudo ln -s /usr/local/lib/node /usr/lib/node | |
| sudo ln -s /usr/local/bin/npm /usr/bin/npm | |
| sudo ln -s /usr/local/bin/node-waf /usr/bin/node-waf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select 'alter index '||OWNER||'.'||INDEX_NAME||' rebuild online;' | |
| from DBA_INDEXES | |
| WHERE STATUS = 'UNUSABLE'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select machine, count(*) | |
| from v$session | |
| group by machine | |
| order by 2 desc; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select username, osuser, program, module, | |
| machine, terminal, process, | |
| to_char(logon_time, 'YYYY-MM-DD HH24:MI:SS') as logon_time, | |
| status, | |
| case status | |
| when 'ACTIVE' then null | |
| else last_call_et | |
| end as idle_time | |
| from v$session | |
| where type = 'USER'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select username, osuser, program, module, | |
| machine, process, | |
| count(1) as login_count | |
| from v$session | |
| where type = 'USER' | |
| group by username, osuser, program, module, | |
| machine, process; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select s.sid, s.username, s.osuser, | |
| to_char(sm.begin_time, 'HH24:MI:ss') as interval_start, | |
| to_char(sm.end_time, 'HH24:MI:ss') as interval_end, | |
| s.machine, s.process, s.program, s.module, | |
| sm.cpu, sm.pga_memory, sm.logical_reads, sm.physical_reads, | |
| sm.hard_parses, sm.soft_parses, | |
| s.logon_time | |
| from v$session s, v$sessmetric sm | |
| where sm.session_id = s.sid | |
| and s.type = 'USER' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select s.sid, s.username, s.osuser, | |
| s.machine, s.process, s.program, s.module, | |
| q.sql_text, q.optimizer_cost, | |
| s.blocking_session, bs.username as blocking_user, | |
| bs.machine as blocking_machine, bs.module as blocking_module, | |
| bq.sql_text as blocking_sql, s.event as wait_event, | |
| q.sql_fulltext | |
| from v$session s, v$sql q, v$session bs, v$sql bq | |
| where s.sql_id = q.sql_id | |
| and s.blocking_session = bs.sid(+) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select * from | |
| ( | |
| select sql_id, sql_text, executions, | |
| elapsed_time, cpu_time, buffer_gets, disk_reads, | |
| elapsed_time / executions as avg_elapsed_time, | |
| cpu_time / executions as avg_cpu_time, | |
| buffer_gets / executions as avg_buffer_gets, | |
| disk_reads / executions as avg_disk_reads | |
| from v$sqlstats |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select pl.object_owner, pl.object_name, | |
| pl.sql_id, q.sql_text, q.module, | |
| pl.operation, pl.options, pl.cost, pl.cpu_cost, pl.io_cost, | |
| q.executions | |
| from v$sql_plan pl, v$sql q | |
| where pl.sql_id = q.sql_id | |
| and ((pl.operation = 'TABLE ACCESS' and pl.options = 'FULL') | |
| or (pl.operation = 'INDEX' and pl.options = 'FAST FULL SCAN') | |
| or (pl.operation = 'INDEX' and pl.options = 'FULL SCAN (MIN/MAX)') | |
| or (pl.operation = 'INDEX' and pl.options = 'FULL SCAN')) |