Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Creating never expiring DB user accounts in Oracle Oracle
  • get_vmstat_solaris Oracle
  • Privilege to describe the table. Oracle
  • Sending email with file attachment. Linux/Unix
  • Absolute file number and relative file number Oracle
  • Restoring a user’s original password 1051962.101 Oracle
  • dbinv.sql Oracle
  • check_copy_progress.sh Linux/Unix
  • tracksqltime.sql Oracle
  • Parallel DML Oracle
  • Find Plan Hash value fphv.sql Oracle
  • Remove DOS CR/LFs (^M) Linux/Unix
  • DB Console Mainenance. Oracle
  • tblwopk.sql tablewopk.sql Oracle
  • Search and replace editor command in vi Linux/Unix

runon_allcdbs_find_pdbs.sql

Posted on 23-Apr-2026 By Admin No Comments on runon_allcdbs_find_pdbs.sql
#!/usr/bin/bash
ORACLE_BASE=/u02/app/oracle
ORACLE_HOME=/u02/app/oracle/product/19.0.0.0/dbhome_1
LOGNAME=runon_all_localdb_$$.log

for v_inst in `ps -ef| grep pmon | awk '{print $8}' | grep -iv asm | grep -iv apx | awk -F"_" '{print $3}'`
do
 echo "Instance name = $v_inst"
 export ORACLE_SID=$v_inst
 $ORACLE_HOME/bin/sqlplus "/ as sysdba" << EOF >> ${LOGNAME}
 show user
 set echo off
 set numwidth 9
 set linesize 132
 set pagesize 300
 set feedback off
 set verify off
 set time off
 set timing off
 --select * from v\$instance;
 @/u02/scripts/paresh/find_pdbs.sql
 --select PROPERTY_VALUE from database_properties where PROPERTY_NAME='DEFAULT_TEMP_TABLESPACE';
EOF
done

cat ${LOGNAME}

rm ${LOGNAME}
Oracle, SQL scripts

Post navigation

Previous Post: Running PDB on single node in RAC
Next Post: runon_allpdbs_show_conname.sh

Related Posts

  • Jai Shree Ram Oracle
  • How to Modify the statistics collection by MMON for AWR repository Oracle
  • Rollback force for distributed transactions Oracle
  • Rman Notes -1 Oracle
  • Gathering statistics with DBMS_STATS Oracle
  • database trigger failing Oracle

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Django (0)
  • GIT (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (402)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (1)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (18)
  • rman-dataguard (26)
  • shell (150)
  • SQL scripts (350)
  • SQL Server (6)
  • Uncategorized (3)
  • Videos (0)

Recent Posts

  • runon_allpdbs_show_conname.sh23-Apr-2026
  • runon_allcdbs_find_pdbs.sql23-Apr-2026
  • Running PDB on single node in RAC09-Apr-2026
  • find_arc.sql09-Apr-2026
  • pvm_pre_change.sql08-Apr-2026
  • find_encr_wallet.sql08-Apr-2026
  • find_pdbs.sql08-Apr-2026
  • Creating a Container Database using dbaascli08-Apr-2026
  • track_autoupgrade_copy_progress.sql01-Apr-2026
  • refre.sql for multitenant01-Apr-2026

Archives

  • 2026
  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Best approach for Oracle database patching sequence to latest/required patchset along with CPU/PSU/any-other-one-off patch ID 865255.1 Oracle
  • Good Link from metalink 1 Oracle
  • Important Script Method for tuning Oracle
  • Load SPM baseline from AWR Oracle
  • crontab syntax Linux/Unix
  • Order by with ROWNUM Oracle
  • Read CSV File using Python Python/PySpark
  • oracle_env_10g_CADEV Linux/Unix

Copyright © 2026 pvmehta.com.

Powered by PressBook News WordPress theme