In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article will explain in detail how to use BBED in kingsql to modify Oracle data file headers to promote SCN. The editor thinks it is very practical, so I share it with you for reference. I hope you can get something after reading this article.
Please read the newspaper. Big mistake:
SQL > startup
ORACLE instance started.
Total System Global Area 1603411968 bytes
Fixed Size 2228784 bytes
Variable Size 989859280 bytes
Database Buffers 603979776 bytes
Redo Buffers 7344128 bytes
Database mounted.
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1:'/ u01 *
SQL > alter database open
Alter database open
*
ERROR at line 1:
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1:'/ u01 *
Now start repairing the data!
SQL > select name,checkpoint_change# from v$datafile
NAME CHECKPOINT_CHANGE#
/ u01/app/oracle/oradata/oggdb2/system01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/sysaux01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/undotbs01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/users01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/example01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/gguser.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/p2pdata01.dbf 2147548266
7 rows selected.
SQL > select name,checkpoint_change# from v$datafile_header
NAME CHECKPOINT_CHANGE#
/ u01/app/oracle/oradata/oggdb2/system01.dbf 2147546874
/ u01/app/oracle/oradata/oggdb2/sysaux01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/undotbs01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/users01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/example01.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/gguser.dbf 2147548266
/ u01/app/oracle/oradata/oggdb2/p2pdata01.dbf 2147548266
Repair process:
1. Modify the value of the old data file header scn
BBED > dump offset 484
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 484 to 983 Dba:0x00400001
8e4a0180 00000000 243e333b 01000000 94000000 02000000 10000000 02000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
0d000d00 0d000100 00000000 00000000 00000000 02004000 32270f00 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 02ace702 c1770dd9 007b503c cfdee590 34000000
00000000 00000000 00000000 00012997 2a000000 38020000 00000000 c08c5ef2
05fe25a5 9d6b999e 14265f03 1ef30600 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
BBED > m / x 654f0180 offset 484
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 484 to 983 Dba:0x00400001
654f0180 00000000 243e333b 01000000 94000000 02000000 10000000 02000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
0d000d00 0d000100 00000000 00000000 00000000 02004000 32270f00 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 02ace702 c1770dd9 007b503c cfdee590 34000000
00000000 00000000 00000000 00012997 2a000000 38020000 00000000 c08c5ef2
05fe25a5 9d6b999e 14265f03 1ef30600 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
two。 View and correct the value of the data file header chckpoint_time
Fixed link http://blog.itpub.net/28389881/viewspace-2221607/ for this article
BBED > dump offset 492
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 492 to 991 Dba:0x00400001
243e333b 01000000 94000000 02000000 10000000 02000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 0d000d00 0d000100
00000000 00000000 00000000 02004000 32270f00 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 02ace702 c1770dd9 007b503c cfdee590 34000000 00000000 00000000
00000000 00012997 2a000000 38020000 00000000 c08c5ef2 05fe25a5 9d6b999e
14265f03 1ef30600 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
BBED > m / x be42333b offset 492
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 492 to 991 Dba:0x00400001
Be42333b 01000000 94000000 02000000 10000000 02000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 0d000d00 0d000100
00000000 00000000 00000000 02004000 32270f00 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 02ace702 c1770dd9 007b503c cfdee590 34000000 00000000 00000000
00000000 00012997 2a000000 38020000 00000000 c08c5ef2 05fe25a5 9d6b999e
14265f03 1ef30600 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
3. Modify the checkpoint counter (kcvfhcpc) in the old data file header
BBED > dump offset 140
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 140 to 639 Dba:0x00400001
28010000 223e333b 27010000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 06005359 5354454d 00000000 00000000 00000000
00000000 01000000 00000000 00000000 00000000
00000000 00000000 00000000 0a000a00 5c776c2d 01000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 654f0180 00000000
Be42333b 01000000 94000000 02000000 10000000 02000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
BBED > m / x 2a010000 offset 140
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 140 to 639 Dba:0x00400001
2a010000 223e333b 27010000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 06005359 5354454d 00000000 00000000 00000000
00000000 01000000 00000000 00000000 00000000
00000000 00000000 00000000 0a000a00 5c776c2d 01000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 654f0180 00000000
Be42333b 01000000 94000000 02000000 10000000 02000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
4. Modify the value of the counter (kcvfhccc) in the old data file header that controls file backup
BBED > dump offset 148
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 148 to 647 Dba:0x00400001
5c537c9d 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 06005359
5354454d 00000000 00000000 00000000 01000000
00000000 00000000 00000000
00000000 00000000 0a000a00 5c776c2d 01000000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 654f0180 00000000 be42333b 01000000
94000000 02000000 10000000 02000000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
BBED > m / x 29010000 offset 148
File: / u01/app/oracle/oradata/oggdb2/system01.dbf (1)
Block: 1 Offsets: 148 to 647 Dba:0x00400001
29010000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 06005359
5354454d 00000000 00000000 00000000 01000000
00000000 00000000 00000000
00000000 00000000 0a000a00 5c776c2d 01000000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000 654f0180 00000000 be42333b 01000000
94000000 02000000 10000000 02000000 00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
00000000 00000000 00000000
5. Regenerate sum
BBED > sum apply
Check value for File 1, Block 1:
Current = 0xec9b, required = 0xec9b
6. Query each data file header scn
SQL > select file#,checkpoint_change#,name from v$datafile_header
FILE# CHECKPOINT_CHANGE# NAME
-
1 2147548266 / u01/app/oracle/oradata/oggdb2/system01.dbf
2 2147548266 / u01/app/oracle/oradata/oggdb2/sysaux01.dbf
3 2147548266 / u01/app/oracle/oradata/oggdb2/undotbs01.dbf
4 2147548266 / u01/app/oracle/oradata/oggdb2/users01.dbf
5 2147548266 / u01/app/oracle/oradata/oggdb2/example01.dbf
6 2147548266 / u01/app/oracle/oradata/oggdb2/gguser.dbf
7 2147548266 / u01/app/oracle/oradata/oggdb2/p2pdata01.dbf
7 rows selected.
7 rows selected.
SQL > alter database open
Database altered.
So far, the database has been started successfully.
On "how to use BBED in kingsql to modify Oracle data file headers to promote SCN" this article is shared here, I hope the above content can be of some help to you, so that you can learn more knowledge, if you think the article is good, please share it out for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.