1.查看当前数据库SCN
SQL> select current_scn from v$database;
CURRENT_SCN
--------------------
15170044180773
SQL> select to_char(15170044180773,'xxxxxxxxxxxxxx') from dual;
TO_CHAR(1517004
---------------
dcc0d183925
2.使用oradebug查看kcsgscn_
SQL> oradebug setmypid
Statement processed.
SQL> oradebug dumpvar sga kcsgscn_
kcslf kcsgscn_ [060019598, 0600195C8) = 0D18398F 00000DCC 00000000 00000000 001627D6 00000000 00000000 00000000 00000000 00000000 60019278 00000000
3.修改为当前SCN加 20000
SQL> select to_char(20000,'xxxxxxxxxxxxxx') from dual;
TO_CHAR(20000,'
---------------
4e20
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.
Total System Global Area 421777408 bytes
Fixed Size 2228864 bytes
Variable Size 343936384 bytes
Database Buffers 67108864 bytes
Redo Buffers 8503296 bytes
Database mounted.
SQL> oradebug setmypid
Statement processed.
SQL>
SQL> oradebug dumpvar sga kcsgscn_
kcslf kcsgscn_ [060019598, 0600195C8) = 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 60019278 00000000
SQL>
SQL> oradebug poke 0x060019598 2 0x4e20
BEFORE: [060019598, 06001959C) = 00000000
AFTER: [060019598, 06001959C) = 00004E20
SQL> alter database open;
Database altered.
SQL> select current_scn from v$database;
CURRENT_SCN
--------------------
15170044265190
看嘛 SCN被成功的推进了 20000
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/7569309/viewspace-2133120/
,如需转载,请注明出处,否则将追究法律责任。