如何设置lmt的空间警告阀值

                              Example—设置Locally Managed Tablespace的空间警告阀值
The following example sets the free-space-remaining thresholds in the USERS tablespace to 10 MB (warning) and 2 MB (critical), and disables the percent-full thresholds.

设置user tbs 在free 空间为10M时为-warning ,2M时为-critical,同时禁用
 percent-full thresholds.

 

--------------------------------------------------------------------------------
DB VERSION: oracle 11g
--------------------------------------------------------------------------------


BEGIN
DBMS_SERVER_ALERT.SET_THRESHOLD(
   metrics_id              => DBMS_SERVER_ALERT.TABLESPACE_BYT_FREE,
   warning_operator        => DBMS_SERVER_ALERT.OPERATOR_LE,
   warning_value           => '10240',
   critical_operator       => DBMS_SERVER_ALERT.OPERATOR_LE,
   critical_value          => '2048',
   observation_period      => 1,
   consecutive_occurrences => 1,
   instance_name           => NULL,
   object_type             =>DBMS_SERVER_ALERT.OBJECT_TYPE_TABLESPACE,
   object_name             => 'USERS');
DBMS_SERVER_ALERT.SET_THRESHOLD(
   metrics_id                 => DBMS_SERVER_ALERT.TABLESPACE_PCT_FULL,
   warning_operator          => DBMS_SERVER_ALERT.OPERATOR_GT,
   warning_value           => '0',
   critical_operator         => DBMS_SERVER_ALERT.OPERATOR_GT,
   critical_value             => '0',
   observation_period      => 1,
   consecutive_occurrences => 1,
   instance_name           => NULL,
   object_type             => DBMS_SERVER_ALERT.OBJECT_TYPE_TABLESPACE,
   object_name             => 'USERS');
END;
/

 

你可能感兴趣的:(设置)