Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Good Link from metalink 1 Oracle
  • Read CSV File using Python Python/PySpark
  • Order by with ROWNUM Oracle
  • ipcs -l Linux/Unix
  • create PLAN_TABLE command. Oracle
  • eplan9i.sql Oracle
  • Roles and Stored Object behaviour Oracle
  • Find All internal Parameters Oracle
  • Search and replace pattern Linux/Unix
  • cache buffer chain latch Oracle
  • 284785.1 How to check RAC Option is currently linked into the Oracle Binary Oracle
  • cold backup scripts to copy locally Linux/Unix
  • usnsql.sql Displays information about UNDO segments with sql statements Oracle
  • Find nth max and min. Oracle
  • Explain Plan Output 2 Oracle

online_bkup.sql

Posted on 15-Sep-2005 By Admin No Comments on online_bkup.sql

set serveroutput on

execute dbms_output.enable(20000);

declare

cursor c1 is

select distinct tablespace_name

from dba_data_files

order by tablespace_name;

cursor c4 is

select member from v$logfile

order by member;

staging_copy_area varchar2(100) := ‘10.201.43.51:/uocdb1/oradata/UOC’;

begin

for cur in c1 loop

dbms_output.put_line (‘alter tablespace ‘ || cur.tablespace_name || ‘ begin backup;’);

declare

cursor c2 is

select file_name

from dba_data_files

where tablespace_name = cur.tablespace_name

order by file_name;

begin

for cur1 in c2 loop

dbms_output.put_line (‘! scp ‘ || cur1.file_name || ‘ ‘ || staging_copy_area );

end loop;

end;

dbms_output.put_line (‘alter tablespace ‘ || cur.tablespace_name || ‘ end backup;’);

end loop;

/********* log file backup **************/

for cur4 in c4 loop

dbms_output.put_line (‘! scp ‘ || cur4.member || ‘ ‘ || staging_copy_area );

end loop;

end;

/

Oracle, SQL scripts

Post navigation

Previous Post: Global Unique Identifier Generation in Oracle 9.2 SYS_GUID()
Next Post: Set Role explaination.

Related Posts

  • temp_use.sql diplays usage of temp ts Oracle
  • Drop database in Oracle 10g Oracle
  • lck.sql Oracle
  • How to specify 2 arch location to avoid any kind of DB hanging. Oracle
  • DBMS_UTILITY.ANALYZE_SCHEMA Oracle
  • v$backup.status information Oracle

Leave a Reply Cancel reply

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

Categories

  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • Oracle (387)
  • PHP/MYSQL/Wordpress (10)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (336)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • SQL Tracker by SID sqltrackerbysid.sql22-Apr-2025
  • How to connect to Oracle Database with Wallet with Python.21-Mar-2025
  • JSON/XML Types in Oracle18-Mar-2025
  • CPU Core related projections12-Mar-2025
  • Exadata Basics10-Dec-2024
  • Reading config file from other folder inside class24-Sep-2024
  • Python class import from different folders22-Sep-2024
  • Transfer SQL Profiles from One database to other database.05-Sep-2024
  • Load testing on Oracle 19C RAC with HammerDB18-Jan-2024
  • Add new columns in dataframe30-Sep-2023

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Adding addidional hard drive and attach it to a linux box. Linux/Unix
  • fkwoind.sql fkwoindex.sql Oracle
  • Creating never expiring DB user accounts in Oracle Oracle
  • AWR settings- MMON is not taking snapshot. Oracle
  • login.sql Oracle
  • secure crt settings Linux/Unix
  • Jai Shree Ram Oracle
  • Removing Ctrl-M from end of line using vi Linux/Unix

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme