Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • move_arch_files.ksh Linux/Unix
  • cold backup scripts to copy locally Linux/Unix
  • avail.sh ( find filesystem spae usage) Linux/Unix
  • Order by with ROWNUM Oracle
  • online_ts_bkup.sql Oracle
  • Processes parameter and its dependencies on OS kernel parameters Linux/Unix
  • FGA Part-I Oracle
  • scripts to take listener.log backup Linux/Unix
  • Vivek Tuning for Row Locks. Oracle
  • cp_filesystem.sql Oracle
  • How to see which patches are applied. Oracle
  • Drop all SPM baselines for SQL handle Oracle
  • Global Unique Identifier Generation in Oracle 9.2 SYS_GUID() Oracle
  • Shuffle an array PHP/MYSQL/Wordpress
  • TABLE SIZING WITH DB_BLOCK ARCHITECTURE Reference : Metalink note : 10640.1 Oracle

Category: Linux/Unix

Remove DOS CR/LFs (^M)

Posted on 11-Sep-2009 By Admin No Comments on Remove DOS CR/LFs (^M)

Remove DOS style CR/LF characters (^M) from UNIX files using: sed -e ‘s/^M$//’ filename > tempfile The newly created tempfile should have the ^M character removed

Linux/Unix, shell

backspace in SQL Plus not working then..?

Posted on 01-Sep-2009 By Admin No Comments on backspace in SQL Plus not working then..?

If you set “stty erase ^H” on unix prompt and it works fine on unix prompt. But not working on SQLPLUS then you need to put “stty erase ^H” in .kshrc file as following. -> pwd /home/oracle oem.localdomain:OEMDB:/home/oracle -> more .kshrc stty erase ^H oem.localdomain:OEMDB:/home/oracle ->

Linux/Unix, shell

Changing default shell

Posted on 01-Sep-2009 By Admin No Comments on Changing default shell

Following statement will be used to change default shell to /bin/ksh for oracle user. [root@oem ~]# chsh -s /bin/ksh oracle Changing shell for oracle. Shell changed. [root@oem ~]#

Linux/Unix, shell

How to remove blank lines using vi editor command

Posted on 09-Jul-2009 By Admin No Comments on How to remove blank lines using vi editor command

use the following: :g/^$/d

Linux/Unix, shell

remove archfiles only when it is applied to DR rm_archfiles.sh

Posted on 08-Jul-2009 By Admin No Comments on remove archfiles only when it is applied to DR rm_archfiles.sh

echo “script execution starts at `date`” echo “COMFORT_SPACE=$COMFORT_SPACE” echo “ARCH_DEST=$ARCH_DEST” echo “ALERT_LOG=$ALERT_LOG” ARCH_SPACE=`df -k $ARCH_DEST | tail -1 | awk ‘{print $5}’ | sed ‘s/%//g’` echo “ARCH_SPACE=$ARCH_SPACE” STDBY_LAST_RECOVERED_FILE=`grep “Media ” $ALERT_LOG |grep -v grep|grep “arch” | tail -1 | sed -e ‘s#^.*/##g’ ` echo “STDBY_LAST_RECOVERED_FILE=$STDBY_LAST_RECOVERED_FILE” STDBY_LAST_RECOVERED_NUMBER=`grep “Media ” $ALERT_LOG |grep -v grep|grep “arch” | tail…

Read More “remove archfiles only when it is applied to DR rm_archfiles.sh” »

Linux/Unix, shell

remove archfiles only when it is applied to DR rm_archfiles.sh

Posted on 08-Jul-2009 By Admin No Comments on remove archfiles only when it is applied to DR rm_archfiles.sh

/oracle/scripts/rm_archfiles.sh “/db9/archlog” “90” “/oracle/admin/TESTDB/bdump/alert_TESTDB.log” #!/bin/sh RUNNING=`ps -ef|grep rm_archfiles.sh|grep -v grep|wc -l` if [ $RUNNING -gt 2 ] then echo “Exiting !!! Total $RUNNING occurence of rm_archfiles.sh are running at `date`” exit fi

Linux/Unix, shell

remove archfiles only when it is applied to DR rm_archfiles.sh

Posted on 08-Jul-2009 By Admin No Comments on remove archfiles only when it is applied to DR rm_archfiles.sh

ARCH_DEST=$1 COMFORT_SPACE=$2 ALERT_LOG=$3 NOTIFY_LIST=dbaoracle@1800flowers.com

Linux/Unix, shell

kill all processes from specific user in solaris.

Posted on 22-Jun-2009 By Admin No Comments on kill all processes from specific user in solaris.

kill all processes from user name atsscript on solaris. pkill -9 -u atsscript

Linux/Unix, shell

check_copy_progress.sh

Posted on 04-Jun-2009 By Admin No Comments on check_copy_progress.sh

#!/bin/ksh LOGFILE=/export/home/oracle/paresh/mylog.log NOTIFY_LIST=me@pvmehta.com while true do echo “Reading Time : `date` n” >> ${LOGFILE} echo “Following Files are currently copying” >>${LOGFILE} ls -rlt /db*/oradata/800JPOE/*.dbf | tail -2 >>${LOGFILE} echo “Out of 116 files, `ls -rlt /db*/oradata/800JPOE/*.dbf | wc -l` files copied so far” >> ${LOGFILE} echo “df -k /800JPOEARCH” >> ${LOGFILE} df -k /800JPOEARCH >>…

Read More “check_copy_progress.sh” »

Linux/Unix, shell

note id 373303.1

Posted on 22-May-2009 By Admin No Comments on note id 373303.1

find the runnung process’s environment

Linux/Unix, shell

Posts pagination

Previous 1 2 3 4 … 15 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
  • UTL_FILE test program Oracle
  • Find execution plan from dba_hist_sql_plan for a specific SQL_ID and PLAN_HASH_VALUE fplan.sql Oracle
  • Adding or Dropping Online Redo Log Files When Physical Standby in place Oracle
  • Jai Shree Ram Oracle
  • In Addition to previous note, following grants needed on PERFSTAT user. Oracle
  • Finding last recovered file on DR and remove all chanracters before any “/” Linux/Unix
  • cache buffer chain latch Oracle
  • pvm_pre_change.sql Oracle

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme