Sunday, May 7, 2023

GET DIRECTORY LOCATION ON ORACLE DATABASE

 echo "
col name_col_plus_show_param for a20;
col value_col_plus_show_param for a80;
show parameter db_recovery_file_dest;
" | sqlplus \/ as sysdba | grep -o "\w*/[[:graph:]]*" > bkploc.txt


--------------------- To find the RMAN backup locations --------------------------------------------
echo "
$(
echo "select fname from v\$backup_files where file_type='PIECE' order by completion_time desc fetch first 1 rows only;" | sqlplus \/ as sysdba | dirname $(grep -e "^/[[:graph:]]*")
)"
----------------------------------------------------------------------------------------------------------------

No comments:

Post a Comment

opatchauto

# Log in as root su - root # Execute opatchauto against the unzipped patch directory /u01/app/19.0.0/ grid /OPatch/opatchauto apply /tmp/pat...