zoukankan      html  css  js  c++  java
  • ols.pl

    APPLIES TO:

    Oracle Database - Enterprise Edition - Version 12.1.0.1 to 12.1.0.2 [Release 12.1]
    Oracle Database Cloud Schema Service - Version N/A and later
    Oracle Database Exadata Cloud Machine - Version N/A and later
    Oracle Cloud Infrastructure - Database Service - Version N/A and later
    Oracle Database Backup Service - Version N/A and later
    Information in this document applies to any platform.

    MAIN CONTENT

    Oracle Clusterware command olsnodes displays node number/status/type/VIP, this is useful but not enough. To clearly display a node's functional role in 12c, including but not limited to CRSD PE Master/Standby, CTSS/UI/ONS Master as well as Leaf-to-Hub connectionship etc, ols.pl is written to automatically present these info in a clear and handy way.

    1. Where to download?

    Click here to download the tool.

    网盘下载地址  https://pan.baidu.com/s/1ak-m-7hiTWsmuR3yo9iqag

    2. What the tool does?


    12c OLS Utility Tool can automatically list following contents:

    * Cluster inventory, GI&RAC owner/group, databases created

    * Node number, status, role from olsnodes

    * Leaf-to-Hub relationship, i.e., which leaf node connects to which hub node

    * Relationship between ASM instances and all their clients, i.e., what instances connect to an ASM instance

    * Relationship between IOS instances and all their clients, i.e., what instances connect to an IOS instance

    * OCR/CRSD Master node

    * CRSD PE Master node

    * CRSD PE Standby node(s)

    * CTSS Master node

    * UI Master node

    * ONS Master node

    * crsd.bin's OCR role and its connectionship to ASM instance, i.e., whether crsd.bin on a node is an OCR Writer or Cache local and which ASM instance it connects to

    Note:

    1) This script is supported on all UNIX platforms including Linux/Solaris/AIX/HP-UX

    2) This script also supports 11.2.x.x.x, except some 12c specific contents are missing.

    3) To get accurate result for above info, related logs on all cluster nodes are retrieved via password-less SSH, which is assumed to be already existent for CRS_OWNER during RAC installation. 

    4) All Master/Standby info is obtained by searching related keywords in crsd/ctssd/agent logs, so if all related logs have been flushed out, "N/A" would be returned. This also applies to Leaf-to-Hub relationship and OCR-to-ASM's connectionship.

    3. How to use the tool?

     

    Main usage:

    * Please use "-h" to get the detailed help information

    ols.pl [-full] [-master] [-verbose] [-debug] [-help]

    Options:

    -[full|f] Print full info including CTSS/UI/ONS Master
    -[master|f] Print only OCR Master, PE Master/Standby(12c only) info
    -[verbose|v] Print verbose info including OCR/CRS Standby Rank(12c only), CRSPE Role|State Update info
    -[debug|d] Print detailed info for debugging purpose
    -[help|h] Print this help info

    4. Sample Output

    $ ./ols.pl -f -v
    
    
    The Cluster Nodes are : "NodeA, NodeB, NodeC, NodeD"
    The Local Node is : "NodeA"
    The Remote Nodes are : "NodeB, NodeC, NodeD"
    
    Major Clusterware Version is : "12.1.0.1.0"
    
    CRS_HOME is installed at : "/u01/app/12.1.0/grid"
    CRS_BASE is installed at : "/u01/app/crsusr"
    CRS_OWNER is : "crsusr"
    CRS_GROUP is : "oinstall"
    
    ORACLE_HOMES[0] is installed at : "/u01/app/crsusr/product/12.1.0/dbhome_1"
    ORACLE_BASES[0] is installed at : "/u01/app/crsusr"
    ORACLE_OWNERS[0] is : "crsusr"
    
     
    
    All databases created:
    
     
    
    NodeA 1 Active Hub
    NodeB 2 Active Hub
    NodeC 100 Active Leaf
    NodeD 101 Active Leaf
    
     
    
    cNodes attaches pNodes
    ====== ======== ======
    NodeA(1,Active) <--- NodeC(100,Active),NodeD(101,Active)
    NodeB(2,Active) <--- None
    
     
    
    ASM Host connects Client
    ======== ======== ======
    NodeA(+ASM1) <--- +APX1
    NodeA(+ASM1) <--- +ASM1
    NodeA(+ASM1) <--- +IOS1
    NodeA(+ASM1) <--- -MGMTDB
    NodeB(+ASM2) <--- +APX2
    NodeB(+ASM2) <--- +IOS2
    
     
    
    IOS Host connects Client
    ======== ======== ======
    NodeA(+IOS1) <--- None
    NodeB(+IOS2) <--- None
    
     
    
    OCR/CRSD Master: NodeA
    
     
    
    CRSD PE Master : NodeA
    
     
    
    CRSD PE Standby: NodeB
    
     
    
    <NodeA> 07-10 02:22:06.185: My R:3 = Min R:3 R of OCR:1 R of CRS Standby:0 R of ASM Inst:2 OCR on ASM:1 ASM mode:2
    <NodeB> 07-10 02:27:56.532: My R:4 > Min R:3 R of OCR:1 R of CRS Standby:1 R of ASM Inst:2 OCR on ASM:1 ASM mode:2
    <NodeC> 07-10 02:30:47.515: My R:0 < Min R:1 R of OCR:0 R of CRS Standby:0 R of ASM Inst:0 OCR on ASM:0 ASM mode:2
    <NodeD> 07-10 02:30:48.730: My R:0 < Min R:1 R of OCR:0 R of CRS Standby:0 R of ASM Inst:0 OCR on ASM:0 ASM mode:2
    
     
    
    <NodeA> 07-10 02:22:07.079: PE Role|State Update: old role [MASTER] new [MASTER]; old state [Starting] new [Running]
    <NodeB> 07-10 02:27:41.629: PE Role|State Update: old role [SLAVE] new [SLAVE]; old state [Starting] new [Running]
    <NodeC> 07-10 02:30:58.108: PE Role|State Update: old role [SLAVE] new [SLAVE]; old state [Starting] new [Running]
    <NodeD> 07-10 02:30:58.494: PE Role|State Update: old role [SLAVE] new [SLAVE]; old state [Starting] new [Running]
    
     
    
    CTSS Master : NodeA
    
     
    
    UI Master : NodeA
    
     
    
    ONS Master : N/A
    
     
    
    OCR Local/Writer connects ASM Instance
    ================ ======== ============
    NodeA(Hub,OCR Writer) ---> NodeA(+ASM1)
    NodeB(Hub,OCR Local) ---> NodeA(+ASM1)
    NodeC(Leaf,OCR Local) ---> NodeB(+ASM2)
    NodeD(Leaf,OCR Local) ---> NodeB(+ASM2)
    

      

  • 相关阅读:
    win2008服务器,fastCGI完美设置教程
    IIS7中配置FastCGI运行PHP
    Apple 移动设备绑定动态生成元素点击事件$(document).on('click',element,callback)失效解决方法
    MacOS Catalina 10.15 brew 安装 PHP 和 使用 pecl 安装 Mcrypt
    Redis 列表命令记录
    Redis hash类型命令
    Redis 字符串命令
    Redis 通用命令记录
    Redis 三种启动方式
    Mac 使用 wget 安装 Redis3.0
  • 原文地址:https://www.cnblogs.com/zylong-sys/p/12150561.html
Copyright © 2011-2022 走看看