Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Difference between SYNC and AFFIRM Oracle
  • How can I tell if ASO is installed ? Oracle
  • sql_plan9i.sql Oracle
  • find the files that are 1 day old. Linux/Unix
  • Good links for x$ tables in oracle. Oracle
  • findinfo.sql (SQL for getting CPU and Active session info) Oracle
  • secure crt settings Linux/Unix
  • Oracle vs MYSQL Architecture differences (For DBAs) MYSQL
  • oradebug ipcrm ipcs Oracle
  • Resolving RMAN Hung Jobs Oracle
  • Sample WW22 listener.ora Oracle
  • chk_space_SID.ksh Linux/Unix
  • configUOCIOTTO.ora Oracle
  • How to find who is using which Rollback segment and how many rows or blocks in that rollback segments, Oracle
  • How to connect to Oracle Database with Wallet with Python. Oracle

pvm_rbs1.sql (to collect rbs info from db)

Posted on 10-May-2008 By Admin No Comments on pvm_rbs1.sql (to collect rbs info from db)

select segment_name, status from dba_rollback_segs order by status, segment_name; select status, count(1) from dba_rollback_segs group by status;

Oracle, SQL scripts

Find sort details from Db find_sort.sql

Posted on 10-May-2008 By Admin No Comments on Find sort details from Db find_sort.sql

select sql_text,(executions-sorts) “Diff” from v$sqlarea where (executions-sorts) < 20 and executions > 100 order by 2 ; SELECT S.sid || ‘,’ || S.serial# sid_serial, S.username, T.blocks * TBS.block_size / 1024 / 1024 mb_used, T.tablespace, T.sqladdr address, Q.hash_value, Q.sql_text FROM v$sort_usage T, v$session S, v$sqlarea Q, dba_tablespaces TBS WHERE T.session_addr = S.saddr AND T.sqladdr = Q.address…

Read More “Find sort details from Db find_sort.sql” »

Oracle, SQL scripts

runsql_once.ksh

Posted on 10-May-2008 By Admin No Comments on runsql_once.ksh

#!/bin/ksh # This parameter will be for executing environment file. $1 $ORACLE_HOME/bin/sqlplus -s “/ as sysdba”

Linux/Unix, shell

send attachment from unix-shell script

Posted on 10-May-2008 By Admin No Comments on send attachment from unix-shell script

#!/bin/ksh ORACLE_HOME=/oracle/app/oracle/product/9.2.0.8;export ORACLE_HOME ORACLE_SID=800P; export ORACLE_SID $ORACLE_HOME/bin/sqlplus -s “/ as sysdba”

Linux/Unix, shell

temp_use.sql diplays usage of temp ts

Posted on 10-May-2008 By Admin No Comments on temp_use.sql diplays usage of temp ts

SELECT b.TABLESPACE, b.segfile#, b.segblk#, b.blocks, a.SID, a.serial#, a.username, a.osuser, a.status, c.sql_text FROM v$session a, v$sort_usage b, v$sqlarea c WHERE a.saddr = b.session_addr AND a.SQL_HASH_VALUE = c.HASH_VALUE ORDER BY b.TABLESPACE, b.segfile#, b.segblk#, b.blocks / set pagesize 10000 set linesize 133 column tablespace format a15 heading ‘Tablespace Name’ column segfile# format 9,999 heading ‘File|ID’ column segblk# format…

Read More “temp_use.sql diplays usage of temp ts” »

Oracle, SQL scripts

get_ratio.sql get the ratio of users from v$session and this uses CASE-WHEN-THEN clause

Posted on 10-May-2008 By Admin No Comments on get_ratio.sql get the ratio of users from v$session and this uses CASE-WHEN-THEN clause

set time on set timing on set verify off select to_char(sysdate, ‘DD-MON-RRRR:HH24:MI’) from dual; prompt ‘Total distinct users and total user sessions’ select count(distinct username), count(1), round(count(1)/count(distinct username),1 ) from v$session where username is not null; prompt ‘Total terminal server distinct users and total user sessions’ select count(distinct username), count(1), round(count(1)/count(distinct username),1 ) from v$session…

Read More “get_ratio.sql get the ratio of users from v$session and this uses CASE-WHEN-THEN clause” »

Oracle, SQL scripts

pvm_metric.sql for gathering report from vmstat tables

Posted on 10-May-2008 By Admin No Comments on pvm_metric.sql for gathering report from vmstat tables

col AVG_ACTIVE_USR format 999999.99 col AVG_TOT_USR format 9999.99 col AVG_USR_CPU format 9999.99 col AVG_SYS_CPU format 99.99 col AVG_IDLE_CPU format 99.99 col AVG_WAIT_CPU format 99.99 col TOT_ODR format 99999999 col AVG_ACT_USR format 999999.99 col RUNQ format 999.99 col CSW format 99999.99 set lines 120 pages 2000 accept start1 prompt ‘Enter Start Dare in DD-MON-RRRR:HH24:MI format :…

Read More “pvm_metric.sql for gathering report from vmstat tables” »

Oracle, SQL scripts

ORA-4031 issue and solution on 09-MAY-2008

Posted on 10-May-2008 By Admin No Comments on ORA-4031 issue and solution on 09-MAY-2008

++++++++++++++++++++ Problem description ++++++++++++++++++++ Some users started getting ORA-4031. This is the eror that show following: 4031, 00000, “unable to allocate %s bytes of shared memory (“%s”,”%s”,”%s”,”%s”)” ++++++++++++++++++++++ Problem solution ++++++++++++++++++++++ We ran following query and found failues that may result into 4031. set echo off verify off set lines 120 pages 555 /* V$SHARED_POOL_RESERVED_SIZE…

Read More “ORA-4031 issue and solution on 09-MAY-2008” »

Oracle, SQL scripts

How to calculate PROCESSES parameter

Posted on 09-May-2008 By Admin No Comments on How to calculate PROCESSES parameter

SEMMSL Set to 10 plus the largest initsid.ora PROCESSES parameter of an Oracle database on the system. The PROCESSES parameter can be found in each initsid.ora file, loc ORACLE_HOME/dbs directory. The default value of PROCESSES for the 8.1.5 prebuilt database is 50. SEMMNS Set to the sum of the PROCESSES parameter for each Oracle database…

Read More “How to calculate PROCESSES parameter” »

Oracle, SQL scripts

How to set Processes Parameter

Posted on 09-May-2008 By Admin No Comments on How to set Processes Parameter

The only drawback in setting the processes value high is that the corresponding kernel settings, SEMMNS and SEMMSL need to be set higher based on the following formulas: SEMMSL – Set to 10 plus the largest PROCESSES parameter of any Oracle database on the system. SEMMNS – Set to the sum of the PROCESSES parameter…

Read More “How to set Processes Parameter” »

Oracle, SQL scripts

Posts pagination

Previous 1 … 23 24 25 … 57 Next

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (392)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (0)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (341)
  • SQL Server (6)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • SQL Server Vs Oracle Architecture difference25-Jul-2025
  • SQL Server: How to see historical transactions25-Jul-2025
  • SQL Server: How to see current transactions or requests25-Jul-2025
  • T-SQL Vs PL/SQL Syntax25-Jul-2025
  • Check SQL Server edition25-Jul-2025
  • Checking SQL Server Version25-Jul-2025
  • Oracle vs MYSQL Architecture differences (For DBAs)24-Jul-2025
  • V$INSTANCE of Oracle in MYSQL24-Jul-2025
  • Day to day MYSQL DBA operations (Compared with Oracle DBA)24-Jul-2025
  • MYSQL and Oracle Comparison for Oracle DBA24-Jul-2025

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • handling filenname with space Linux/Unix
  • Which environment is used by currently running process ( Very good) Linux/Unix
  • check_copy_progress.sh Linux/Unix
  • For Search and replace unix command. Linux/Unix
  • DBMS_Shared_pool pinning triggers Oracle
  • Recovering lost SYS password Oracle
  • How to find Unix server conguraiton including Server Model number and underlying disk sub-system ( On Solaris) Linux/Unix
  • tar and untar a dolder with all its subfolder. Linux/Unix

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme