Oracle 12c RMAN新特性
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
<rac02:orcl2:/home/oracle>$rman target /Recovery Manager: Release 12.1.0.2.0 - Production on Fri Dec 8 06:46:59 2017Copyright (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 catalogStatement processedRMAN> grant sysbackup to roidba;Statement processedRMAN> exit
2.备份用户特权sysbackup,可以备份恢复
<rac02:orcl2:/home/oracle>$rman target '"roidba/roidba@orcl as sysbackup"'Recovery Manager: Release 12.1.0.2.0 - Production on Fri Dec 8 06:49:21 2017Copyright (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:07using target database control file instead of recovery catalogallocated channel: ORA_DISK_1channel ORA_DISK_1: SID=86 instance=orcl2 device type=DISKchannel ORA_DISK_1: starting full datafile backup setchannel ORA_DISK_1: specifying datafile(s) in backup setinput datafile file number=00001 name=+DATADG/ORCL/DATAFILE/system.258.954539407input datafile file number=00003 name=+DATADG/ORCL/DATAFILE/sysaux.257.954539345input datafile file number=00004 name=+DATADG/ORCL/DATAFILE/undotbs1.260.954539485input datafile file number=00005 name=+DATADG/ORCL/DATAFILE/undotbs2.265.954539975input datafile file number=00006 name=+DATADG/ORCL/DATAFILE/users.259.962189275channel ORA_DISK_1: starting piece 1 at 08-DEC-2017 06:50:10channel ORA_DISK_1: finished piece 1 at 08-DEC-2017 06:51:45piece handle=/u01/app/oracle/product/12.1.0/dbhome_1/dbs/2rslj812_1_1 tag=TAG20171208T065009 comment=NONEchannel ORA_DISK_1: backup set complete, elapsed time: 00:01:35Finished backup at 08-DEC-2017 06:51:45Starting Control File and SPFILE Autobackup at 08-DEC-2017 06:51:45piece handle=/u01/app/oracle/product/12.1.0/dbhome_1/dbs/c-1482320270-20171208-04 comment=NONEFinished Control File and SPFILE Autobackup at 08-DEC-2017 06:51:52RMAN>
生产环境建议大家使用专用用户,不要什么时候都使用sysdba权限,防止误操作,养成好习惯。
声明:本站所有文章资源内容,如无特殊说明或标注,均为采集网络资源。如若本站内容侵犯了原著者的合法权益,可联系本站删除。