First Shut down the Database and have a backup.
****************************************************
Then :>>
_ALLOW_RESETLOGS_CORRUPTION
can be set to TRUE in the INIT.ORA using which the database can be forced
to be started without applying changes from the online redo logs. Once the
database is up with this parameter set, consistency of the data and data
dictionary is no longer guaranteed. The database must be rebuilt by exporting the
full database, creating a new database and importing into it.
Having 17 year of experince in variety of field including 14 year as IT and As a Oracle DBA Having 7 year of Experince With PT , Backup and Recovery , Database Migration (sql to ORACLE ),Creating Stand By Database. New Projects Installation. Have experice in any kind of Trouble shooting in Database. Knowledge of RAC and Dataguard. Financial prospective of projects and cost reduction
Thursday, January 13, 2011
Monday, January 10, 2011
Redo log Corruption Recovery incomplete
Conditions for incomplete recovery:
- Must be in archive log mode
- Must have recent cold or hot backups
- Necessary archive log files must exist to roll forward
*********************************************
Recovery Procedure:
1.) Make sure that the database is shut down.
2.) Restore from last cold or hot backup all datafiles and controlfile(s).
3.) Open Server Manager.
4.) Open the database in mount mode:
Startup mount pfile=d:\orant\database\init[sid].ora
5.) Recover using:
Recover database using backup controlfile until cancel
6.) When prompted to apply existing archive logs, press [return]
ORA-00279: Change 11532 generated at 11/05/99 10:47:59 needed for thread 1
ORA-00289: Suggestion: d:\orant\database\archive\arch127.arc
ORA-00280: Change 11532 for thread 1 is in sequence #127
Specify log: ((RET)=suggested | filename | AUTO | CANCEL)
7.) When prompted to apply archive log that does not exist (current
redo log), type "CANCEL" (this is current/active redo log file when
database crashed).
ORA-00279: Change 11548 generated at 11/05/99 10:55:17 needed for thread 1
ORA-00289: Suggestion: d:\orant\database\archive\arch129.arc
ORA-00280: Change 11532 for thread 1 is in sequence #129
ORA-00278: Logfile 'd:\orant\database\archive\arch128.arc' no longer
needed for this recovery
Specify log: ((RET)=suggested | filename | AUTO | CANCEL)
8.) Copy the control file by typing:
Alter database backup controlfile to trace
9.) Issue "Shutdown Immediate".
10.) Edit/rename the trace file generated.
- Delete all lines before and including the line "Startup Nomount"
- Change "Noresetlogs" with "Resetlogs"
- Change the location of all redo logs away from corrupted disk
- Delete every line after the "Datafile" entry
Result Sample file (recotest.sql):
CREATE CONTROLFILE REUSE DATABASE "ITOR" RESETLOGS ARCHIVELOG
MAXLOGFILES 32
MAXLOGMEMBERS 4
MAXDATAFILES 50
MAXINSTANCES 16
MAXLOGHISTORY 1600
LOGFILE
GROUP 1 (
'D:\ORANT\DATABASE\LOGITOR\newlogdir\LOGITOR1A.LOG',
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR1B.LOG'
) SIZE 500K,
GROUP 2 (
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR2A.LOG',
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR2B.LOG'
) SIZE 500K,
GROUP 3 (
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR3A.LOG',
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR3B.LOG'
) SIZE 512K
DATAFILE
'D:\ORANT\DATABASE\LOGITOR\SYSTEMITOR.DBF',
'D:\ORANT\DATABASE\LOGITOR\DATA_1.TBL',
'D:\ORANT\DATABASE\LOGITOR\RBS_ITOR.DBF'
;
11.) Start server manager.
12.) Start database in nomount mode:
Startup nomount pfile=d:\orant\database\init[sid].ora
13.) Run controlfile script:
svrmgrl> @recotest.sql
14.) Open the database with redo logs in new location:
Alter database open resetlogs;
15.) Shutdown the database and perform a full backup.
- Must be in archive log mode
- Must have recent cold or hot backups
- Necessary archive log files must exist to roll forward
*********************************************
Recovery Procedure:
1.) Make sure that the database is shut down.
2.) Restore from last cold or hot backup all datafiles and controlfile(s).
3.) Open Server Manager.
4.) Open the database in mount mode:
Startup mount pfile=d:\orant\database\init[sid].ora
5.) Recover using:
Recover database using backup controlfile until cancel
6.) When prompted to apply existing archive logs, press [return]
ORA-00279: Change 11532 generated at 11/05/99 10:47:59 needed for thread 1
ORA-00289: Suggestion: d:\orant\database\archive\arch127.arc
ORA-00280: Change 11532 for thread 1 is in sequence #127
Specify log: ((RET)=suggested | filename | AUTO | CANCEL)
7.) When prompted to apply archive log that does not exist (current
redo log), type "CANCEL" (this is current/active redo log file when
database crashed).
ORA-00279: Change 11548 generated at 11/05/99 10:55:17 needed for thread 1
ORA-00289: Suggestion: d:\orant\database\archive\arch129.arc
ORA-00280: Change 11532 for thread 1 is in sequence #129
ORA-00278: Logfile 'd:\orant\database\archive\arch128.arc' no longer
needed for this recovery
Specify log: ((RET)=suggested | filename | AUTO | CANCEL)
8.) Copy the control file by typing:
Alter database backup controlfile to trace
9.) Issue "Shutdown Immediate".
10.) Edit/rename the trace file generated.
- Delete all lines before and including the line "Startup Nomount"
- Change "Noresetlogs" with "Resetlogs"
- Change the location of all redo logs away from corrupted disk
- Delete every line after the "Datafile" entry
Result Sample file (recotest.sql):
CREATE CONTROLFILE REUSE DATABASE "ITOR" RESETLOGS ARCHIVELOG
MAXLOGFILES 32
MAXLOGMEMBERS 4
MAXDATAFILES 50
MAXINSTANCES 16
MAXLOGHISTORY 1600
LOGFILE
GROUP 1 (
'D:\ORANT\DATABASE\LOGITOR\newlogdir\LOGITOR1A.LOG',
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR1B.LOG'
) SIZE 500K,
GROUP 2 (
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR2A.LOG',
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR2B.LOG'
) SIZE 500K,
GROUP 3 (
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR3A.LOG',
'D:\ORANT\DATABASE\LOGITOR\newlog\LOGITOR3B.LOG'
) SIZE 512K
DATAFILE
'D:\ORANT\DATABASE\LOGITOR\SYSTEMITOR.DBF',
'D:\ORANT\DATABASE\LOGITOR\DATA_1.TBL',
'D:\ORANT\DATABASE\LOGITOR\RBS_ITOR.DBF'
;
11.) Start server manager.
12.) Start database in nomount mode:
Startup nomount pfile=d:\orant\database\init[sid].ora
13.) Run controlfile script:
svrmgrl> @recotest.sql
14.) Open the database with redo logs in new location:
Alter database open resetlogs;
15.) Shutdown the database and perform a full backup.
Friday, February 26, 2010
How to configure Xmanager to CentOS
Can any help in this issue, it would be really appreciated.
I did the following, but it didnt help....
For XDMCP connection to Red Hat 5 EL
1. XDM Configuration
1. Change runlevel to 5
Open/etc/inittab and set the initial runlevel to 5 as following:
id:5:initdefault:
2. Enable XDMCP
For GDM:
Open /etc/gdm/custom.conf and set the Enable entry to 1 in the [xdmcp]
section as following.
[xdmcp]
Enable=1
For KDM:
Open /usr/share/config/kdm/Xaccess and remove the initial "#"
character for the following line:
#* #any host can get a login window ==>
* #any host can get a login window
Open /usr/share/config/kdm/kdmrc and set the Enable entry to true in
the [xdmcp] section as following.
[xdmcp]
Enable=true
2. Firewall (TCP/UDP Ports) Configuration
Open UDP port 177 from the PC to the remote host direction.
Open incoming TCP ports 6000~6010 from the remote host to your PC.
3. Reboot the remote host and start Xmanager
# init 3; init 5
I did the following, but it didnt help....
For XDMCP connection to Red Hat 5 EL
1. XDM Configuration
1. Change runlevel to 5
Open/etc/inittab and set the initial runlevel to 5 as following:
id:5:initdefault:
2. Enable XDMCP
For GDM:
Open /etc/gdm/custom.conf and set the Enable entry to 1 in the [xdmcp]
section as following.
[xdmcp]
Enable=1
For KDM:
Open /usr/share/config/kdm/Xaccess and remove the initial "#"
character for the following line:
#* #any host can get a login window ==>
* #any host can get a login window
Open /usr/share/config/kdm/kdmrc and set the Enable entry to true in
the [xdmcp] section as following.
[xdmcp]
Enable=true
2. Firewall (TCP/UDP Ports) Configuration
Open UDP port 177 from the PC to the remote host direction.
Open incoming TCP ports 6000~6010 from the remote host to your PC.
3. Reboot the remote host and start Xmanager
# init 3; init 5
Wednesday, December 2, 2009
To check the RPM of Disk
For Linux
hdparm -I /dev/dsk/c3t2d0s0
For Windows
form my computer > Manage > Device manager > HDD > Model no
hdparm -I /dev/dsk/c3t2d0s0
For Windows
form my computer > Manage > Device manager > HDD > Model no
Tuesday, October 13, 2009
sql on '&' character in Oracle
Escape ampersand (&) characters in SQL*Plus
When using SQL*Plus, the DEFINE setting can be changed to allow &'s (ampersands) to be used in text:
SET DEFINE ~
SELECT 'Lorel & Hardy' FROM dual;
Other methods:
Define an escape character:
SET ESCAPE '\'
SELECT '\&abc' FROM dual;
Don't scan for substitution variables:
SET SCAN OFF
SELECT '&ABC' x FROM dual;
When using SQL*Plus, the DEFINE setting can be changed to allow &'s (ampersands) to be used in text:
SET DEFINE ~
SELECT 'Lorel & Hardy' FROM dual;
Other methods:
Define an escape character:
SET ESCAPE '\'
SELECT '\&abc' FROM dual;
Don't scan for substitution variables:
SET SCAN OFF
SELECT '&ABC' x FROM dual;
Wednesday, September 16, 2009
to convert systimestamp to Any other time zone
The fuction is from_tz
SELECT FROM_TZ(to_timestamp(to_char(systimestamp,'DD-MON-YYYY HH:MI:SS PM')) ,'+05:30') AT TIME ZONE '-06:00',systimestamp from dual;
and one more fn.
select LOCALTIMESTAMP AT TIME ZONE '-6:00' from dual;
SELECT FROM_TZ(to_timestamp(to_char(systimestamp,'DD-MON-YYYY HH:MI:SS PM')) ,'+05:30') AT TIME ZONE '-06:00',systimestamp from dual;
and one more fn.
select LOCALTIMESTAMP AT TIME ZONE '-6:00' from dual;
Monday, September 14, 2009
ORA-31626 - ORA-31650
Error is as below:-
/*****************************************************************/
-bash-3.00$ expdp "'/ as sysdba'" directory=backup dumpfile=full_expor_1.dmp
logfile=full_export_1.log schemas=scoot
Export: Release 10.2.0.1.0 - Production on Monday, 14 September, 2009 11:04:37
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
ORA-31626: job does not exist
ORA-31650: timeout waiting for master process response
/****************************************************************************/
solution :-
select Table_name from dba_tables where table_name like '%EXPORT%' and owner='SYS';
Delete all the Table Created by Export Utility while Creating the Metadata.
/*****************************************************************/
-bash-3.00$ expdp "'/ as sysdba'" directory=backup dumpfile=full_expor_1.dmp
logfile=full_export_1.log schemas=scoot
Export: Release 10.2.0.1.0 - Production on Monday, 14 September, 2009 11:04:37
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
ORA-31626: job does not exist
ORA-31650: timeout waiting for master process response
/****************************************************************************/
solution :-
select Table_name from dba_tables where table_name like '%EXPORT%' and owner='SYS';
Delete all the Table Created by Export Utility while Creating the Metadata.
Subscribe to:
Posts (Atom)