Oracle TFA系列4:工具

1. TFA中包括的工具


从上图看,TFA将ORACLE比较重要的诊断工具,全部整合起来了。
这些工具的安装位置:/oracle/product/11.2.0/grid/tfa/xxxxxxdb01/tfa_home/ext

查看工具状态

tfactl> toolstatus                                                              
.-----------------------------------------.
|          External Support Tools         |
+------------+--------------+-------------+
| Host       | Tool         | Status      |
+------------+--------------+-------------+
| xxxxxxdb01 | alertsummary | DEPLOYED    |
| xxxxxxdb01 | exachk       | DEPLOYED    |
| xxxxxxdb01 | ls           | DEPLOYED    |
| xxxxxxdb01 | pstack       | DEPLOYED    |
| xxxxxxdb01 | orachk       | DEPLOYED    |
| xxxxxxdb01 | sqlt         | DEPLOYED    |
| xxxxxxdb01 | grep         | DEPLOYED    |
| xxxxxxdb01 | summary      | DEPLOYED    |
| xxxxxxdb01 | prw          | NOT RUNNING |
| xxxxxxdb01 | vi           | DEPLOYED    |
| xxxxxxdb01 | tail         | DEPLOYED    |
| xxxxxxdb01 | param        | DEPLOYED    |
| xxxxxxdb01 | dbglevel     | DEPLOYED    |
| xxxxxxdb01 | darda        | DEPLOYED    |
| xxxxxxdb01 | history      | DEPLOYED    |
| xxxxxxdb01 | oratop       | DEPLOYED    |
| xxxxxxdb01 | oswbb        | RUNNING     |
| xxxxxxdb01 | dbperf       | DEPLOYED    |
| xxxxxxdb01 | changes      | DEPLOYED    |
| xxxxxxdb01 | events       | DEPLOYED    |
| xxxxxxdb01 | ps           | DEPLOYED    |
| xxxxxxdb01 | srdc         | DEPLOYED    |
'------------+--------------+-------------'

我们通过几个案例看下怎么使用

2. orachk

# /oracle/product/11.2.0/grid/bin/tfactl
tfactl>

就进入了tfactl的shell环境,在tfactl中运行orachk就开始执行orachk命令

tfactl> orachk                                                                  

CRS stack is running and CRS_HOME is not set. Do you want to set CRS_HOME to /oracle/product/11.2.0/grid?[y/n][y]

Checking for prompts on xxxxxxdb01 for grid user...


Checking ssh user equivalency settings on all nodes in cluster

Node xxxxxxdb02 is configured for ssh user equivalency for root user
 

Checking for prompts for grid user on all nodes...


Searching for running databases . . . . .

. . 
List of running databases registered in OCR
1. xxxxxx
2. None of above

Select databases from list for checking best practices. For multiple databases, select 1 for All or comma separated number like 1,2 etc [1-2][1].1
. . . . 

. 
Checking Status of Oracle Software Stack - Clusterware, ASM, RDBMS

. . 
Checking for prompts for oracle user on all nodes...

. . . . . . . . . . . . .. . . . . . . . . . . .. . . . . . 
-------------------------------------------------------------------------------------------------------
                                                 Oracle Stack Status                            
-------------------------------------------------------------------------------------------------------
Host Name  CRS Installed  RDBMS Installed  CRS UP    ASM UP    RDBMS UP  DB Instance Name
-------------------------------------------------------------------------------------------------------
xxxxxxdb01  Yes             Yes             Yes        No       Yes      xxxxxx1   
xxxxxxdb02  Yes             Yes             Yes        No       Yes      xxxxxx2   
-------------------------------------------------------------------------------------------------------
.....
Detailed report (html) - /oracle/grid/tfa/repository/suptools/xxxxxxdb01/orachk/root/orachk_xxxxxxdb01_xxxxxx_021017_141810/orachk_xxxxxxdb01_xxxxxx_021017_141810.html
UPLOAD(if required) - /oracle/grid/tfa/repository/suptools/xxxxxxdb01/orachk/root/orachk_xxxxxxdb01_xxxxxx_021017_141810.zip

tfactl> exit

3. oswbb

# export DISPLAY=132.228.187.40:0.0
# /oracle/product/11.2.0/grid/bin/tfactl
tfactl> oswbb                                                                   

Starting OSW Analyzer V7.3.3
OSWatcher Analyzer Written by Oracle Center of Expertise
Copyright (c)  2014 by Oracle Corporation

Parsing Data. Please Wait...

Scanning file headers for version and platform info...


Parsing file xxxxxxdb01_iostat_17.02.09.0900.dat ...
Parsing file xxxxxxdb01_iostat_17.02.09.1000.dat ...
Parsing file xxxxxxdb01_iostat_17.02.09.1100.dat ...
Parsing file xxxxxxdb01_iostat_17.02.09.1200.dat ...
Parsing file xxxxxxdb01_iostat_17.02.09.1300.dat ...
Parsing file xxxxxxdb01_iostat_17.02.09.1400.dat ...
Parsing file xxxxxxdb01_iostat_17.02.09.1500.dat ...
......
Parsing file xxxxxxdb01_ps_17.02.10.1400.dat ...
Parsing file xxxxxxdb01_ps_17.02.10.1500.dat ...
Parsing file xxxxxxdb01_ps_17.02.10.1600.dat ...


Parsing Completed.

Enter 1 to Display CPU Process Queue Graphs
Enter 2 to Display CPU Utilization Graphs
Enter 3 to Display CPU Other Graphs
Enter 4 to Display Memory Graphs
Enter 5 to Display Disk IO Graphs

Enter 6 to Generate All CPU Gif Files
Enter 7 to Generate All Memory Gif Files
Enter 8 to Generate All Disk Gif Files

Enter L to Specify Alternate Location of Gif Directory
Enter T to Alter Graph Time Scale Only (Does not change analysis dataset)
Enter D to Return to Default Graph Time Scale
Enter R to Remove Currently Displayed Graphs

Enter A to Analyze Data
Enter S to Analyze Subset of Data(Changes analysis dataset including graph time scale)

Enter P to Generate A Profile
Enter X to Export Parsed Data to File
Enter Q to Quit Program

Please Select an Option:4
  • 内存信息:
  • CPU信息:
  • 4. summary

    tfactl> summary                                                                 
    
    
    Output from host : xxxxxxdb01
    ------------------------------
    
    =====
    Nodes
    =====
    xxxxxxdb01
    xxxxxxdb02
    
    =====
    Homes
    =====
    
    .----------------------------------------------------------------------------------------------------.
    | Home                        | Type | Version    | Database | Instance | Patches                    |
    +-----------------------------+------+------------+----------+----------+----------------------------+
    | /oracle/product/11.2.0/grid | GI   | 11.2.0.4.0 |          |          | 22502505,23054319,24006111 |
    | /oracle/product/11.2.0/db_1 | DB   | 11.2.0.4.0 | xxxxxx   | xxxxxx1  |          23054319,24006111 |
    '-----------------------------+------+------------+----------+----------+----------------------------'
    
    
    Output from host : xxxxxxdb02
    ------------------------------
    
    =====
    Homes
    =====
    
    .----------------------------------------------------------------------------------------------------.
    | Home                        | Type | Version    | Database | Instance | Patches                    |
    +-----------------------------+------+------------+----------+----------+----------------------------+
    | /oracle/product/11.2.0/grid | GI   | 11.2.0.4.0 |          |          | 22502505,23054319,24006111 |
    | /oracle/product/11.2.0/db_1 | DB   | 11.2.0.4.0 | xxxxxx   | xxxxxx2  |          23054319,24006111 |
    '-----------------------------+------+------------+----------+----------+----------------------------'
    

    关于紫砂壶

    感悟技术人生
    此条目发表在工具分类目录,贴了标签。将固定链接加入收藏夹。