Oracle基於使用者管理的不完全恢複(四)完全恢複時丟失部分歸檔日誌

來源:互聯網
上載者:User

案例3——在做完全恢複時,丟失了部分歸檔日誌 (recover database until cancel;)

1、基於cancel 的不完全恢複

——類比環境

SQL> col table_name for a20

SQL> col tablespace_name for a10

SQL> select table_name,tablespace_name from user_tables;

TABLE_NAME           TABLESPACE

-------------------- ----------

DEPT                 USERS

EMP                  USERS

BONUS                USERS

SALGRADE             USERS

EMPLOYEES            USERS

EMP2                 USERS

TB02                 CUUG

TB01                 TEST

ADMIN_EXT_EMPLOYEES

EMP1                 USERS

10 rows selected.

SQL> conn /as sysdba

Connected.

SQL> select * from scott.tb02;

ID

----------

1

2

3

4

5

6

7

8

8 rows selected.

SQL> select * from v$log;

GROUP#    THREAD#  SEQUENCE#      BYTES    MEMBERS ARCHIVED  STATUS       FIRST_CHANGE# FIRST_TIME

---------- ---------- ---------- ---------- ---------- --------- ------------ ------------- -------------------

1          1          1  104857600          3 YES       INACTIVE            851230 2012-03-23 16:04:13

4          1          4  104857600          3 NO        CURRENT             851518 2012-03-23 16:13:25

3          1          3  104857600          3 YES       INACTIVE            851509 2012-03-23 16:13:09

2          1          2  104857600          3 YES       INACTIVE            851500 2012-03-23 16:12:53

SQL> insert into scott.tb02 values(9);

1 row created.

SQL> commit;

Commit complete.

SQL> alter system archive log current;

System altered.

SQL> insert into scott.tb02 values(10);

1 row created.

SQL> commit;

Commit complete.

SQL> alter system archive log current;

System altered.

SQL> insert into scott.tb02 values(11);

1 row created.

SQL> commit;

Commit complete.

SQL> alter system archive log current;

System altered.

SQL> select name from v$archived_log;

NAME

--------------------------------------------------

查看本欄目更多精彩內容:http://www.bianceng.cnhttp://www.bianceng.cn/database/Oracle/

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.