取得DBMS_MONITOR包的信息

SELECT * FROM DBA_SOURCE where TYPE='PACKAGE' AND NAME LIKE 'DBMS_MONITOR%';

 

 

text 字段信息如下:

 

package dbms_monitor is

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

  --  OVERVIEW

  --

  --  This package provides database monitoring functionality, initially

  --  in the area of statistics aggregation and SQL tracing

 

  --  SECURITY

  --

  --  runs with SYS privileges.

 

  --  CONSTANTS to be used as OPTIONS for various procedures

  --  refer comments with procedure(s) for more detail

 

  all_modules                    CONSTANT VARCHAR2(14) := '###ALL_MODULES';

  all_actions                    CONSTANT VARCHAR2(14) := '###ALL_ACTIONS';

 

  -- Indicates that tracing/aggregation for a given module should be enabled

  -- for all actions

 

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

 

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

  --  PROCEDURES AND FUNCTIONS

  --

  PROCEDURE client_id_stat_enable(

    client_id IN VARCHAR2);

 

  --  Enables statistics aggregation for the given Client ID

  --  Input arguments:

  --   client_id           - Client Identifier for which the statistics

  --                         colection is enabled

 

  PROCEDURE client_id_stat_disable(

    client_id IN VARCHAR2);

 

  --  Disables statistics aggregation for the given Client ID

  --  Input arguments:

  --   client_id           - Client Identifier for which the statistics

  --                         colection is disabled

 

  PROCEDURE serv_mod_act_stat_enable(

    service_name IN VARCHAR2,

    module_name IN VARCHAR2,

    action_name IN VARCHAR2 DEFAULT ALL_ACTIONS);

 

  --  Enables statistics aggregation for the given service/module/action

  --  Input arguments:

  --   service_name        - Service Name for which the statistics

  --                         colection is enabled

  --   module_name         - Module Name for which the statistics

  --                         colection is enabled

  --   action_name         - Action Name for which the statistics

  --                         colection is enabled. The name is optional.

  --                         if omitted, statistic aggregation is enabled

  --                         for all actions in a given module

 

  PROCEDURE serv_mod_act_stat_disable(

    service_name IN VARCHAR2,

    module_name IN VARCHAR2,

    action_name IN VARCHAR2 DEFAULT ALL_ACTIONS);

 

  --  Disables statistics aggregation for the given service/module/action

  --  Input arguments:

  --   service_name        - Service Name for which the statistics

  --                         colection is disabled

  --   module_name         - Module Name for which the statistics

  --                         colection is disabled

  --   action_name         - Action Name for which the statistics

  --                         colection is disabled. The name is optional.

  --                         if omitted, statistic aggregation is disabled

  --                         for all actions in a given module

 

  PROCEDURE client_id_trace_enable(

    client_id IN VARCHAR2,

    waits IN BOOLEAN DEFAULT TRUE,

    binds IN BOOLEAN DEFAULT FALSE);

 

  --  Enables SQL for the given Client ID

  --  Input arguments:

  --   client_id           - Client Identifier for which SQL trace

  --                         is enabled

  --   waits               - If TRUE, wait information will be present in the

  --                         the trace

  --   binds               - If TRUE, bind information will be present in the

  --                         the trace

 

  PROCEDURE client_id_trace_disable(

    client_id IN VARCHAR2);

 

  --  Disables SQL trace for the given Client ID

  --  Input arguments:

  --   client_id           - Client Identifier for which SQL trace

  --                         is disabled

 

  PROCEDURE serv_mod_act_trace_enable(

    service_name IN VARCHAR2,

    module_name IN VARCHAR2 DEFAULT ALL_MODULES,

    action_name IN VARCHAR2 DEFAULT ALL_ACTIONS,

    waits IN BOOLEAN DEFAULT TRUE,

    binds IN BOOLEAN DEFAULT FALSE,

    instance_name IN VARCHAR2 DEFAULT NULL);

 

  --  Enables SQL trace for the given service/module/action

  --  Input arguments:

  --   service_name        - Service Name for which SQL trace

  --                         is enabled

  --   module_name         - Module Name for which SQL trace

  --                         is enabled. The name is optional.

  --                         if omitted, SQL trace is enabled

  --                         for all modules and actions actions in a given

  --                         service

  --   action_name         - Action Name for which SQL trace

  --                         is enabled. The name is optional.

  --                         if omitted, SQL trace is enabled

  --                         for all actions in a given module

  --   waits               - If TRUE, wait information will be present in the

  --                         the trace

  --   binds               - If TRUE, bind information will be present in the

  --                         the trace

  --   instance_name       - if set, restricts tracing to the named instance

 

  PROCEDURE serv_mod_act_trace_disable(

    service_name IN VARCHAR2,

    module_name IN VARCHAR2 DEFAULT ALL_MODULES,

    action_name IN VARCHAR2 DEFAULT ALL_ACTIONS,

    instance_name IN VARCHAR2 DEFAULT NULL);

 

  --  Disables SQL trace for the given service/module/action

  --  Input arguments:

  --   service_name        - Service Name for which SQL trace

  --                         is disabled

  --   module_name         - Module Name for which SQL trace

  --                         is disabled. The name is optional.

  --                         if omitted, SQL trace is disabled

  --                         for all modules and actions actions in a given

  --   action_name         - Action Name for which SQL trace

  --                         is disabled. The name is optional.

  --                         if omitted, SQL trace is disabled

  --                         for all actions in a given module

  --                         the trace

  --   instance_name       - if set, restricts disabling to the named instance

 

  PROCEDURE session_trace_enable(

    session_id IN BINARY_INTEGER DEFAULT NULL,

    serial_num IN BINARY_INTEGER DEFAULT NULL,

    waits IN BOOLEAN DEFAULT TRUE,

    binds IN BOOLEAN DEFAULT FALSE);

 

  --  Enables SQL trace for the given Session ID

  --  Input arguments:

  --   session_id          - Session Identifier for which SQL trace

  --                         is enabled. If omitted (or NULL), the

  --                         user's own session is assumed

  --   serial_num          - Session serial number for which SQL trace

  --                         is enabled. If omitted (or NULL), only

  --                         the session ID is used to determine a session

  --   waits               - If TRUE, wait information will be present in the

  --                         the trace

  --   binds               - If TRUE, bind information will be present in the

  --                         the trace

 

  PROCEDURE session_trace_disable(

    session_id IN BINARY_INTEGER DEFAULT NULL,

    serial_num IN BINARY_INTEGER DEFAULT NULL);

 

  --  Disables SQL trace for the given Session ID

  --  Input arguments:

  --   session_id          - Session Identifier for which SQL trace

  --                         is disabled

  --   serial_num          - Session serial number for which SQL trace

  --                         is disabled

 

  PROCEDURE database_trace_enable(

    waits IN BOOLEAN DEFAULT TRUE,

    binds IN BOOLEAN DEFAULT FALSE,

    instance_name IN VARCHAR2 DEFAULT NULL);

 

  --  Enables SQL trace for the whole database or given instance

  --  Input arguments:

  --   waits               - If TRUE, wait information will be present in the

  --                         the trace

  --   binds               - If TRUE, bind information will be present in the

  --                         the trace

  --   instance_name       - if set, restricts tracing to the named instance

 

  PROCEDURE database_trace_disable(

    instance_name IN VARCHAR2 DEFAULT NULL);

 

  --  Disables SQL trace for the whole database or given instance

  --  Input arguments:

  --   instance_name       - if set, restricts disabling to the named instance

end;

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值