Oracle10g新增命令用以简化用户管理的备份,可以通过
alter database begin/end backup来进行数据库备份模式的切换。
$ sqlplus "/ as sysdba"
SQL*Plus: Release 10.1.0.2.0 - Production on Wed Apr 6 22:31:33 2005
Copyright (c) 1982, 2004, Oracle.
All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options
SYS AS SYSDBA on 06-APR-05 alter database begin backup;
Database altered.
SYS AS SYSDBA on 06-APR-05 desc v$backup
Name
Null?
Type
----------------------------------------- -------- ----------------------------
FILE#
NUMBER
STATUS
VARCHAR2(18)
CHANGE#
NUMBER
TIME
DATE
SYS AS SYSDBA on 06-APR-05 select * from v$backup;
FILE# STATUS
CHANGE# TIME
---------- ------------------ ---------- ------------
1 ACTIVE
11000149 06-APR-05
2 ACTIVE
11000149 06-APR-05
3 ACTIVE
11000149 06-APR-05
4 ACTIVE
11000149 06-APR-05
5 ACTIVE
11000149 06-APR-05
6 ACTIVE
11000149 06-APR-05
7 ACTIVE
11000149 06-APR-05
9 ACTIVE
11000149 06-APR-05
10 ACTIVE
11000149 06-APR-05
11 ACTIVE
11000149 06-APR-05
10 rows selected.
SYS AS SYSDBA on 06-APR-05 alter database end backup;
Database altered.
SYS AS SYSDBA on 06-APR-05 select * from v$backup;
FILE# STATUS
CHANGE# TIME
---------- ------------------ ---------- ------------
1 NOT ACTIVE
11000149 06-APR-05
2 NOT ACTIVE
11000149 06-APR-05
3 NOT ACTIVE
11000149 06-APR-05
4 NOT ACTIVE
11000149 06-APR-05
5 NOT ACTIVE
11000149 06-APR-05
6 NOT ACTIVE
11000149 06-APR-05
7 NOT ACTIVE
11000149 06-APR-05
9 NOT ACTIVE
11000149 06-APR-05
10 NOT ACTIVE
11000149 06-APR-05
11 NOT ACTIVE
11000149 06-APR-05
10 rows selected.
SYS AS SYSDBA on 06-APR-05