Chinaunix首页 | 论坛 | 博客
  • 博客访问: 261332
  • 博文数量: 54
  • 博客积分: 2668
  • 博客等级: 少校
  • 技术积分: 560
  • 用 户 组: 普通用户
  • 注册时间: 2009-05-06 01:08
文章分类

全部博文(54)

文章存档

2011年(14)

2010年(14)

2009年(26)

分类: Oracle

2011-01-26 16:39:56

1、offline表空间备份

SQL> select TABLESPACE_NAME ,status from dba_tablespaces;
TABLESPACE_NAME                STATUS
------------------------------ ---------
SYSTEM                         ONLINE
SYSAUX                         ONLINE
UNDOTBS1                       ONLINE
TEMP                           ONLINE
USERS                          ONLINE
ZWTEST                         OFFLINE
 
RMAN> backup tablespace "ZWTEST";
Starting backup at 26-JAN-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00020 name=/u01/app/oracle/oradata/orcl/zwtest.dbf
channel ORA_DISK_1: starting piece 1 at 26-JAN-11
channel ORA_DISK_1: finished piece 1 at 26-JAN-11
piece handle=/u01/app/oracle/flash_recovery_area/ORCL/backupset/2011_01_26/o1_mf_nnndf_TAG20110126T162841_6mzpst5z_.bkp tag=TAG20110126T162841 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backup at 26-JAN-11
 
2READ only表空间备份
 
$ sqlplus / AS sysdba
 
SQL*Plus: Release 10.2.0.2.0 - Production ON Sat Nov 10 10:38:35 2007
 
Copyright (c) 1982, 2005, Oracle. ALL Rights Reserved.
Connected TO:
Oracle DATABASE 10g Enterprise Edition Release 10.2.0.2.0 - Production
WITH the Partitioning, OLAP AND DATA Mining options
 
SQL> ALTER tablespace TEST online;
 
Tablespace altered.
 
SQL> ALTER tablespace TEST READ only;
 
Tablespace altered.
 
RMAN> backup tablespace "TEST";
 
Starting backup at 2007-11-10 10:39:35
USING target DATABASE control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=140 devtype=DISK
channel ORA_DISK_1: starting FULL datafile backupset
channel ORA_DISK_1: specifying datafile(s) IN backupset
input datafile fno=00005 name=/export/home/oracle/product/10.0/oradata/tina/test.dbf
channel ORA_DISK_1: starting piece 1 at 2007-11-10 10:39:36
channel ORA_DISK_1: finished piece 1 at 2007-11-10 10:39:37
piece handle=/export/home/oracle/product/10.0/flash_recovery_area/TINA/backupset/2007_
 
11_10/o1_mf_nnndf_TAG20071110T103936_3mb6h8nq_.bkp tag=TAG20071110T103936 comment=NONE
channel ORA_DISK_1: backup SET complete, elapsed time: 00:00:01
Finished backup at 2007-11-10 10:39:37
阅读(1700) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~