Oracle12cRMAN新特性

Oracle 12c RMAN新特性

成都创新互联公司坚持“要么做到,要么别承诺”的工作理念,服务领域包括:成都网站建设、成都网站设计、企业官网、英文网站、手机端网站、网站推广等服务,满足客户于互联网时代的江汉网站设计、移动媒体设计的需求,帮助企业找到有效的互联网解决方案。努力成为您成熟可靠的网络建设合作伙伴!

SYSBACKUP  This privilege allows a user to perform backup and recovery 
operations either from Oracle Recovery Manager (RMAN) or 
SQL*Plus.
See Oracle Database Security Guidefor the full list of operations allowed 
by this administrative privilege.

1.rman 中可以执行sql

$rman target /

Recovery Manager: Release 12.1.0.2.0 - Production on Fri Dec 8 06:46:59 2017

Copyright (c) 1982, 2014, Oracle and/or its affiliates.  All rights reserved.

connected to target database: ORCL (DBID=1482320270)

RMAN> create user roidba identified by roidba;

using target database control file instead of recovery catalog
Statement processed

RMAN> grant sysbackup to roidba;

Statement processed

RMAN> exit

2.备份用户特权sysbackup,可以备份恢复

$rman target '"roidba/roidba@orcl as sysbackup"'

Recovery Manager: Release 12.1.0.2.0 - Production on Fri Dec 8 06:49:21 2017

Copyright (c) 1982, 2014, Oracle and/or its affiliates.  All rights reserved.

connected to target database: ORCL (DBID=1482320270)

RMAN> backup database;

Starting backup at 08-DEC-2017 06:50:07
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=86 instance=orcl2 device type=DISK
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00001 name=+DATADG/ORCL/DATAFILE/system.258.954539407
input datafile file number=00003 name=+DATADG/ORCL/DATAFILE/sysaux.257.954539345
input datafile file number=00004 name=+DATADG/ORCL/DATAFILE/undotbs1.260.954539485
input datafile file number=00005 name=+DATADG/ORCL/DATAFILE/undotbs2.265.954539975
input datafile file number=00006 name=+DATADG/ORCL/DATAFILE/users.259.962189275
channel ORA_DISK_1: starting piece 1 at 08-DEC-2017 06:50:10
channel ORA_DISK_1: finished piece 1 at 08-DEC-2017 06:51:45
piece handle=/u01/app/oracle/product/12.1.0/dbhome_1/dbs/2rslj812_1_1 tag=TAG20171208T065009 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:01:35
Finished backup at 08-DEC-2017 06:51:45

Starting Control File and SPFILE Autobackup at 08-DEC-2017 06:51:45
piece handle=/u01/app/oracle/product/12.1.0/dbhome_1/dbs/c-1482320270-20171208-04 comment=NONE
Finished Control File and SPFILE Autobackup at 08-DEC-2017 06:51:52

RMAN> 

生产环境建议大家使用专用用户,不要什么时候都使用sysdba权限,防止误操作,养成好习惯。


文章名称:Oracle12cRMAN新特性
文章网址:http://pwwzsj.com/article/gsjodd.html