Professional Documents
Culture Documents
Hot Backup (Online Backup) : Posted by Narashim Reddy .R On August 16, 2009
Hot Backup (Online Backup) : Posted by Narashim Reddy .R On August 16, 2009
1 Votes
/home/oracle/rub/datafiles/system01.dbf
/home/oracle/rub/datafiles/undotbs1.dbf
/home/oracle/rub/datafiles/sysaux01.dbf
/home/oracle/rub/datafiles/users01.dbf
/home/oracle/rub/control/c1.ctl
SQL> show parameter pfile;
NAME TYPE VALUE
spfile string /home/oracle/oracle/product/10
.2.0/db_1/dbs/spfilerub.ora
SQL> select tablespace_name from dba_tablespaces;
TABLESPACE_NAME
SYSTEM
UNDOTBS1
SYSAUX
TEMP
USERS
SQL> alter tablespace system begin backup;
Tablespace altered.
SQL> alter tablespace undotbs1 begin backup;
Tablespace altered.
SQL> alter tablespace sysaux begin backup;
Tablespace altered.
SQL> alter tablespace users begin backup;
Tablespace altered.
SQL> !
[oracle@reddy ~]$ mkdir backup
[oracle@reddy ~]$ cd rub/
[oracle@reddy rub]$ ls
archive bdump control datafiles dbc.sql udump
[oracle@reddy rub]$ cd archive/
[oracle@reddy archive]$ ls
arch_1_668961233_71.arc arch_1_668961233_75.arc
arch_1_668961233_79.arc
arch_1_668961233_72.arc arch_1_668961233_76.arc
arch_1_668961233_80.arc
arch_1_668961233_73.arc arch_1_668961233_77.arc
arch_1_668961233_81.arc
arch_1_668961233_74.arc arch_1_668961233_78.arc
[oracle@reddy archive]$ cp *.arc /home/oracle/backup/
[oracle@reddy archive]$ cd ..
[oracle@reddy rub]$ cd control/
[oracle@reddy control]$ ls
c1.ctl
[oracle@reddy control]$ cp c1.ctl /home/oracle/backup/
[oracle@reddy control]$ cd ..
[oracle@reddy rub]$ cd datafiles/
[oracle@reddy datafiles]$ ls
redo01.log redo02.log sysaux01.dbf system01.dbf temp01.dbf undotbs1.dbf
users01.dbf
[oracle@reddy datafiles]$ cp *.dbf /home/oracle/backup/
[oracle@reddy datafiles]$ cd $ORACLE_HOME/dbs
[oracle@reddy dbs]$ ls
initrub.ora spfilerub.ora
[oracle@reddy dbs]$ cp initrub.ora /home/oracle/backup
[oracle@reddy dbs]$ cp spfilerub.ora /home/oracle/backup/
[oracle@reddy dbs]$ cd
[oracle@reddy ~]$ cd backup/
[oracle@reddy backup]$ ls
arch_1_668961233_71.arc arch_1_668961233_76.arc
arch_1_668961233_81.arc system01.dbf
arch_1_668961233_72.arc arch_1_668961233_77.arc c1.ctl temp01.dbf
arch_1_668961233_73.arc arch_1_668961233_78.arc initrub.ora undotbs1.dbf
arch_1_668961233_74.arc
arch_1_668961233_79.arc spfilerub.ora users01.dbf
arch_1_668961233_75.arc arch_1_668961233_80.arc sysaux01.dbf
[oracle@reddy backup]$ exit
exit
SQL> alter tablespace system end backup;
Tablespace altered.
SQL> alter tablespace undotbs1 end backup;
Tablespace altered.
SQL> alter tablespace sysaux end backup;
Tablespace altered.
SQL> alter tablespace users end backup;
Tablespace altered