2010년 12월 1일 수요일

[11G]ADRCI PURGE , IPS 기능 활용하기

아래 내용을 보시면 11G 부터는 alert log 및 trace 관리 정책이 바뀌었다는 것을 아실 겁니다.

[11g] ADR - AlertLog와 Tracefile의 새로운 위치

아래 내용은 ADRCI PUGE 기능과 IPS 기능에 대해 테스트 한 것을 기입해 봅니다.

/oracle > adrci

ADRCI: Release 11.2.0.2.0 - Production on Tue Nov 30 10:59:54 2010

Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.

ADR base = "/oracle/app/oracle"
adrci> show incident

ADR Home = /oracle/app/oracle/diag/clients/user_oracle/host_206825830_76:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/clients/user_root/host_206825830_76:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/rdbms/test/TEST2:
*************************************************************************
INCIDENT_ID PROBLEM_KEY CREATE_TIME
-------------------- ----------------------------------------------------------- ----------------------------------------
3968573 ORA 4030 2010-07-28 16:10:37.454000 +09:00
3968533 ORA 4030 2010-07-28 16:10:37.454000 +09:00
3968557 ORA 4030 2010-07-28 16:10:37.454000 +09:00
3968589 ORA 4030 2010-07-28 16:10:37.542000 +09:00
3968541 ORA 4030 2010-07-28 16:10:37.542000 +09:00
3968733 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-28 17:26:58.531000 +09:00
3968577 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 13:16:11.467000 +09:00
3968565 ORA 4030 2010-07-29 17:46:55.237000 +09:00
3968545 ORA 4030 2010-07-29 17:46:55.239000 +09:00
3968537 ORA 4030 2010-07-29 17:46:55.249000 +09:00
3968584 ORA 4030 2010-07-29 17:46:55.257000 +09:00
3968549 ORA 4030 2010-07-29 17:46:55.306000 +09:00
3968773 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 18:09:57.796000 +09:00
3968593 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 19:07:05.754000 +09:00
3968639 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 19:09:57.510000 +09:00
3968669 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 19:12:40.298000 +09:00
3968594 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 19:14:02.333000 +09:00
3968816 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-29 19:18:16.677000 +09:00
3968357 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-30 08:25:10.893000 +09:00
3968645 ORA 7445 [kkocsMarkBindFroCB()+40] 2010-07-30 11:43:34.633000 +09:00
3992524 ORA 4030 2010-08-02 20:59:03.066000 +09:00
3992525 ORA 4030 2010-08-02 20:59:09.414000 +09:00
3992526 ORA 4030 2010-08-02 20:59:16.147000 +09:00
3992527 ORA 4030 2010-08-02 20:59:23.259000 +09:00
3992528 ORA 4030 2010-08-02 20:59:26.024000 +09:00
3992588 ORA 4030 2010-08-03 09:16:49.520000 +09:00
4040570 ORA 7445 [evaopn3()+212] 2010-08-13 19:27:54.942000 +09:00

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener1_testdb1:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener1_testdb2:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener2_testdb1:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener2_testdb2:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener3_testdb2:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener_testdb1:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/listener_testdb2:
*************************************************************************
0 rows fetched

ADR Home = /oracle/app/oracle/diag/tnslsnr/testdb2/sid_list_listener_testdb1:
*************************************************************************
First 0 rows fetched (*** more available ***)

adrci>
adrci> show homepath
ADR Homes:
diag/clients/user_oracle/host_206825830_76
diag/clients/user_root/host_206825830_76
diag/rdbms/test/TEST2
diag/tnslsnr/testdb2/listener
diag/tnslsnr/testdb2/listener1_testdb1
diag/tnslsnr/testdb2/listener1_testdb2
diag/tnslsnr/testdb2/listener2_testdb1
diag/tnslsnr/testdb2/listener2_testdb2
diag/tnslsnr/testdb2/listener3_testdb2
diag/tnslsnr/testdb2/listener_testdb1
diag/tnslsnr/testdb2/listener_testdb2
diag/tnslsnr/testdb2/sid_list_listener_testdb1
adrci>
adrci> PURGE
adrci> show homepath
ADR Homes:
diag/rdbms/test/TEST2
adrci>
adrci> purge -age 60 -type incident
adrci> purge -age 10 -type incident
adrci> purge -age 10 -type ALERT
adrci> purge -age 10 -type INCIDENT
adrci> purge -age 10 -type TRACE
adrci> purge -age 10 -type CDUMP
adrci> purge -age 10 -type HM
adrci> purge -age 10 -type UTSCDMP


adrci> ips generate package 2 in /oracle/DBAWORK
DIA-48448: This command does not support multiple ADR homes

adrci>


adrci> show homepath
ADR Homes:
diag/clients/user_oracle/host_206825830_76
diag/clients/user_root/host_206825830_76
diag/rdbms/test/TEST2
diag/tnslsnr/testdb2/listener
diag/tnslsnr/testdb2/listener1_testdb1
diag/tnslsnr/testdb2/listener1_testdb2
diag/tnslsnr/testdb2/listener2_testdb1
diag/tnslsnr/testdb2/listener2_testdb2
diag/tnslsnr/testdb2/listener3_testdb2
diag/tnslsnr/testdb2/listener_testdb1
diag/tnslsnr/testdb2/listener_testdb2
diag/tnslsnr/testdb2/sid_list_listener_testdb1
adrci>
adrci> set homepath diag/rdbms/test/TEST2
adrci> IPS GENERATE PACKAGE 1 IN /oracle/DBAWORK
Generated package 1 in file /oracle/DBAWORK/IPSPKG_20101130111546_COM_1.zip, mode complete
adrci>


/oracle/DBAWORK > ls -lart IPSPKG*
-rw-r--r-- 1 oracle dba 73294 Nov 30 11:20 IPSPKG_20101130111546_COM_1.zip
/oracle/DBAWORK >


###################### Note ID 738732.1 ##################################################

ADR Different Methods to Create IPS Package [ID 738732.1]
--------------------------------------------------------------------------------
Modified 26-MAY-2010 Type HOWTO Status PUBLISHED

In this Document Goal
Solution
References

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

Applies to:
Oracle Server - Enterprise Edition - Version: 11.1.0.6 to 11.2.0.1.0 - Release: 11.1 to 11.2
Information in this document applies to any platform.

Goal
Oracle has introduced several new Diagnosability features in 11g. One of them is Incident Packaging Service (IPS).
IPS uses rules to correlate all relevant dumps and traces from ADR for a given problem and allows you to package them to ship to Oracle Support.

Refer to the note : 443529.1 for the quick steps to create package.

You can access IPS through EM or ADRCI.

This document provides instructions to create package using different methods.
Solution
Invoke adrci and set ADR_HOME.

You can create a logical package based on an incident number, a problem number, a problem key, or a time interval.
Create a logical package such that it will be most useful to diagnose the error of your concern.

I) Creating package based on incident.

Select correct incident if there are many incidents.

adrci>SHOW INCIDENT
adrci>IPS CREATE PACKAGE INCIDENT incident_number

II) Creating Empty package.

adrci>IPS CREATE PACKAGE

This creates an empty package. You must use the IPS ADD INCIDENT or IPS ADD FILE commands to
add diagnostic data to the package before generating it.


III) Creating package based on problem ID


adrci>IPS CREATE PACKAGE PROBLEM problem_ID

This creates a package and includes diagnostic information for incidents that reference the specified
problem ID. (Problem IDs are integers.) You can obtain the problem ID for an incident from the
report displayed by the SHOW INCIDENT -MODE BRIEF command. Because there can be many incidents with the same problem ID,
ADRCI adds to the package the diagnostic information for the first three incidents ("early incidents") that occurred
and last three incidents ("late incidents") that occurred with this problem ID, excluding any incidents that are older than 90 days.

IV) Creating package based on problem key

adrci>IPS CREATE PACKAGE PROBLEMKEY "problem_key"

The problem key must be enclosed in single quotes (') or double quotes (") if it contains spaces or quotes.

V)Creating package based on time interval.

This creates a package and includes diagnostic information for all incidents that occurred from sec
seconds ago until now. sec must be an integer.

adrci>IPS CREATE PACKAGE SECONDS sec adrci>IPS CREATE PACKAGE TIME 'start_time' TO 'end_time'

This creates a package and includes diagnostic information for all incidents that occurred within the
specified time range. start_time and end_time must be in the format 'YYYY-MM-DD HH24:MI:SS.FF TZR'.
This is a valid string for the NLS_TIMESTAMP_TZ_FORMAT initialization parameter.
The fraction (FF) portion of the time is optional,
and the HH24:MI:SS delimiters can be colons or periods.


Adding Incidents and files to the logical package :
You can add more files or more incidents to the package.

adrci>IPS ADD INCIDENT incident_number PACKAGE package_number
adrci>IPS ADD FILE filespec PACKAGE package_number

filespec is the complete path and name of the trace file to add .

package_number is the package id.

Generate a physical incident package :
Once you have created a logical package using one of the above methods, next step is to generate a physical package.

adrci>IPS GENERATE PACKAGE package_number IN path

This generates a complete physical package (zip file) in the designated path. For example, the
following command creates a complete physical package in the directory /home/steve/diagnostics
from logical package number 2:

adrci>IPS GENERATE PACKAGE 2 IN /home/steve/diagnostics
Upload this package to the SR for diagnosing the problem.

You can also create and generate package with one command : IPS Pack .

adrci>IPS PACK INCIDENT incident_id IN path

All the methods discussed above apply to 'IPS pack' as well.



참고 문서 :
ADRCI IPS 기능
ADRCI PURGE 기능

댓글 없음:

댓글 쓰기

팔로어