zabbix监控oracle数据库
一、简介 Orabbix 是设计用来为 zabbix 监控 Oracle 数据库的插件,它提供多层次的监控,包括可用性和服务器性能指标。 它提供了从众多 Oracle 实例采集数据的有效机制,进而提供此信息的监控和性能指标。然后,您可以利用的 zabbix 的报告功能为收集的所有
一、简介
Orabbix 是设计用来为 zabbix 监控 Oracle 数据库的插件,它提供多层次的监控,包括可用性和服务器性能指标。
它提供了从众多 Oracle 实例采集数据的有效机制,进而提供此信息的监控和性能指标。然后,您可以利用的 zabbix 的报告功能为收集的所有数据,并提供分析。目前的发行版中包含了一组预先定义的模板,包括从初始部署警报和图形功能。然而,这些可以进行微调,以满足您的需求和数据/监控要求。
Orabbix 监控什么?
-
数据库版本
-
归档日志与生产趋势分析
-
触发器,表/过程等命中率
-
逻辑 I/O 性能
-
物理 I/O 性能
-
PGA
-
SGA
-
共享池
-
Sessions
数据库大小
二、安装配置 # mkdir /opt/orabbix # cd /opt/orabbix # unzip orabbix-1.2.3.zip # mvconf/config.props.sample conf/config.props # cp init.d/orabbix /etc/init.d/ # chmod 755 /etc/init.d/orabbix # chkconfig orabbix on 三、修改 orabbix 配置 # vim conf/config.props #comma separed list of Zabbix servers ZabbixServerList=ZabbixServer ZabbixServer.Address=192.168.0.180 ZabbixServer.Port=10051 #pidFile OrabbixDaemon.PidFile=./logs/orabbix.pid #frequency of item's refresh OrabbixDaemon.Sleep=300 #MaxThreadNumber should be >= thanthe number of your databases OrabbixDaemon.MaxThreadNumber=100 #put here your databases in a commaseparated list DatabaseList=192.168.0.70 # 名称与该机在 zabbix 中监控的主机名称保持一致 #Configuration of Connection pool #if not specified Orabbis is going touse default values (hardcoded) #Maximum number of active connectioninside pool DatabaseList.MaxActive=10 #The maximum number of milliseconds thatthe pool will wait #(when there are no availableconnections) for a connection to be returned #before throwing an exception, or <=0 to wait indefinitely. DatabaseList.MaxWait=100 DatabaseList.MaxIdle=1 #define here your connection string foreach database 192.168.0.70.Url=jdbc:oracle:thin:@192.168.0.70:32778:southdb # 需要 jdk 环境,因为这里是通过 JDBC 连接的,southdb 为数据库实例名称 192.168.0.70.User=ZABBIX # 用来监控 oracle 数据库的用户名和密码,需要在 oracle 中创建并赋予一定的权限 192.168.0.70.Password=ZABBIX #Those values are optionals if notspecified Orabbix is going to use the general values 192.168.0.70.MaxActive=10 192.168.0.70.MaxWait=100 192.168.0.70.MaxIdle=1 192.168.0.70.QueryListFile=./conf/query.props #DB2.Url=jdbc:oracle:thin:@server2.domain.example.com:<LISTENER_PORT>:DB2 #DB2.User=zabbix #DB2.Password=zabbix_password #DB2.QueryListFile=./conf/query.props #DB3.Url=jdbc:oracle:thin:@server3.domain.example.com:<LISTENER_PORT>:DB3 #DB3.User=zabbix #DB3.Password=zabbix_password #DB3.QueryListFile=./conf/query.props 关于 jdbc: Oracle = jdbc:oracle:thin:@<host>:<LISTENER_PORT>:<instance> PostgreSQL = jdbc:postgresql://<host>:<port>/<database> MS Sql Server = jdbc:jtds:sqlserver://<host>:<port>/<instancename> MySQL Server = jdbc:mysql://[host:port],[host:port].../[database] DB2 = jdbc:db2://<servername>:<port>/<installation> 四、创建 oracle 监控账户 1、登录 oracle 命令行 su - oracle # 切换到 oracle 用户 sqlplus /nolog # 不连接任何数据库 conn /as sysdba # 用sysdba 登陆 或 conn 用户名/密码 select instance_name from v$instance; # 查看实例 2、创建用户 CREATE USER ZABBIX IDENTIFIED BY ZABBIX DEFAULT TABLESPACE SYSTEM TEMPORARY TABLESPACE TEMP PROFILE DEFAULT ACCOUNT UNLOCK; 3、赋予角色权限 GRANT CONNECT TO ZABBIX; GRANT RESOURCE TO ZABBIX; ALTER USER ZABBIX DEFAULT ROLEALL; 4、赋予系统权限 GRANT SELECT ANY TABLE TOZABBIX; GRANT CREATE SESSION TO ZABBIX; GRANT SELECT ANY DICTIONARY TOZABBIX; GRANT UNLIMITED TABLESPACE TOZABBIX; GRANT SELECT ANY DICTIONARY TOZABBIX; 五、启动服务 /etc/init.d/orabbix start 或 /opt/orabbix/run.sh 在启动服务过程中通过 tail -f /opt/orabbix/logs/orabbix.log日志查看报错信息。 六、zabbix server 端配置 将该模板 Orabbix_export_full.xml 下载到本机,差导入 zabbix server template # sz orabbix/template/Orabbix_export_full.xml
将模板绑定到要监控的主机上:
附:官方文档
http://www.smartmarmot.com/wiki/index.php/Orabbix
Assumptions
Theinstallation instructions have been created based on instructions for most *nixdeployments (i.e. RHEL/CentOS), and is assumed that any alterations requiredfor your specific environment are to be taken into account accordingly.
Thisguide is based upon there being two (2) Hosts, 1x Zabbix Server and 1x OracleServer. If you are planning on monitoring an Oracle instance that is running onyour Zabbix Server, the steps are the same, with minor adjustments required foryour connection information.
Thesteps also assume you are configuring Orabbix to monitor a new installation orsetup of Oracle. The installation steps will have you GRANT access for theZabbix user to all tables, and this will include any USER tables present at thetime of execution. If you do not want Zabbix to have access to specific tablesor resources within your database, you will need to set a DENY to the Zabbixusers access as required. Consult your DBA for details, as this is beyond thescope of these instructions.
Stepsfor Installation
Download Orabbix to your Zabbix Server
On your Zabbix server, unzip Orabbix to: /opt/orabbix
Copy file /opt/orabbix/init.d/orabbix to /etc/init.d/orabbix
Grant execute permissions to the following files:
/etc/init.d/orabbix
/opt/orabbix/run.sh
Create a User (ZABBIX) for Orabbix to access your Oracle Database. You can use the following script:
CREATE USER ZABBIX
IDENTIFIED BY ZABBIX
DEFAULT TABLESPACE SYSTEM
TEMPORARY TABLESPACE TEMP
PROFILE DEFAULT
ACCOUNT UNLOCK;
– 2 Roles for ZABBIX
GRANT CONNECT TO ZABBIX;
GRANT RESOURCE TO ZABBIX;
ALTER USER ZABBIX DEFAULT ROLE ALL;
– 5 System Privileges for ZABBIX
GRANT SELECT ANY TABLE TO ZABBIX;
GRANT CREATE SESSION TO ZABBIX;
GRANT SELECT ANY DICTIONARY TO ZABBIX;
GRANT UNLIMITED TABLESPACE TO ZABBIX;
GRANT SELECT ANY DICTIONARY TO ZABBIX;
NOTE if you need an User (ZABBIX) for Orabbix with the minimum grants available, you can use the following script:
CREATE USER ZABBIX
IDENTIFIED BY ZABBIX
DEFAULT TABLESPACE USERS
TEMPORARY TABLESPACE TEMP
PROFILE DEFAULT
ACCOUNT UNLOCK;
GRANT ALTER SESSION TO ZABBIX;
GRANT CREATE SESSION TO ZABBIX;
GRANT CONNECT TO ZABBIX;
ALTER USER ZABBIX DEFAULT ROLEALL;
GRANT SELECT ON V_$INSTANCE TOZABBIX;
GRANT SELECT ON DBA_USERS TOZABBIX;
GRANT SELECT ON V_$LOG_HISTORYTO ZABBIX;
GRANT SELECT ON V_$PARAMETER TOZABBIX;
GRANT SELECT ON SYS.DBA_AUDIT_SESSIONTO ZABBIX;
GRANT SELECT ON V_$LOCK TOZABBIX;
GRANT SELECT ON DBA_REGISTRY TOZABBIX;
GRANT SELECT ON V_$LIBRARYCACHETO ZABBIX;
GRANT SELECT ON V_$SYSSTAT TOZABBIX;
GRANT SELECT ON V_$PARAMETER TOZABBIX;
GRANT SELECT ON V_$LATCH TOZABBIX;
GRANT SELECT ON V_$PGASTAT TOZABBIX;
GRANT SELECT ON V_$SGASTAT TOZABBIX;
GRANT SELECT ON V_$LIBRARYCACHETO ZABBIX;
GRANT SELECT ON V_$PROCESS TOZABBIX;
GRANT SELECT ON DBA_DATA_FILESTO ZABBIX;
GRANT SELECT ON DBA_TEMP_FILESTO ZABBIX;
GRANT SELECT ON DBA_FREE_SPACETO ZABBIX;
GRANT SELECT ON V_$SYSTEM_EVENTTO ZABBIX;
NOTE : If you are using Oracle 11g, you will need to add the following:
exec dbms_network_acl_admin.create_acl(acl=> 'resolve.xml',description => 'resolve acl', principal =>'ZABBIX',is_grant => true, privilege => 'resolve');
exec dbms_network_acl_admin.assign_acl(acl=> 'resolve.xml', host =>'*');
commit;
Youcan verify the above is correct by running:
select utl_inaddr.get_host_name('127.0.0.1')from dual;
For this example on RedHat, run:
chkconfig -add orabbix
Verify with:
chkconfig -list
Create a Host entry in Zabbix for the DB Instance/s you are planning to monitor, and import the templates found at: /opt/orabbix/template
Please note, instructions for this step can befound in the Zabbix Manual at
http://www.zabbix.com/documentation.php
With this step, ensure the name of yourhost in Zabbix is the same name of the SID or Oracle instance name.
Configuration
Nowwe need to configure your Orabbix setup. The tags below are listed as they willappear within the respective configuration files. The first you will need tomodify is your config.props file to define your connection properties forZabbix and Oracle.
config.props
Theconfig.props file can be found at /opt/orabbix/conf/config.props
ZabbixServerList
#comma separed list of Zabbix servers
Thesettings under this tag allow you to configure your Zabbix Server information.Orabbix can also be configured to send your Oracle data to multiple Zabbixservers.
This can be beneficial for distributedmonitoring scenarios, server migrations or replicating Orabbix data to a Disaster Recovery site or server.
Replacewith your Zabbix Server info where appropriate;
ZabbixServerList=ZabbixServer1,ZabbixServer2
ZabbixServer1.Address=192.168.0.1
ZabbixServer1.Port=10051
ZabbixServer2.Address=192.168.0.2
ZabbixServer2.Port=10051
OrabbixDaemon
Entriesunder this tag allow you to set your Orabbix Daemon parameters.
#MaxThreadNumber should be >= than thenumber of your databases
Setthe number of threads the Orabbix Daemon should have inside his internal poolof DB Jobs. This number should be at least equal to (or more than) then numberof databases monitored by Orabbix, now this parameter if not set isautomatically calculated.
e.g.For 50 Databases, we are using 100 threads
OrabbixDaemon.MaxThreadNumber=100
#pidFile
Nextyou can set the location of the Daemons PID file. Default location is:/opt/orabbix/logs
OrabbixDaemon.PidFile=./logs/orabbix.pid
NOTE: Relative path is permitted here
TIP: With the features of the OrabbixDaemon, it is possible to clone Orabbix and use different configurations.
As such, it is therefore possible to haveone Daemon that checks your TEST databases, another iteration that checks your
DEVELOPMENT databases and a third thatchecks your PRODUCTION databases, each with different timings and check loops!
DatabaseList
Thisis where you define your database instances. You can specify more than oneinstance here, separated using a comma.
DatabaseList=EXAMPLE1,EXAMPLE2
NOTE: The names of the instances must match those you have specified asyour HOST name in Zabbix
#Configuration of Connection pool
Fromhere, you will configure settings that are specific to the connection pool. Asthe comments in config.props suggest, if you do not specify these values,Orabbix will use default values which have been hard-coded.
#Maximum number of active connection insidepool
Setthe maximum number of connections that can be allocated to this pool at anytime,or alternatively set a negative value for no limit.
DatabaseList.MaxActive=10
#The maximum number of milliseconds
Hereyou define how long that the pool will wait (when there are no available connections)for a connection to be returned before throwing an exception, or set the value
DatabaseList.MaxWait=100
Alsounder the same section, you can define the maximum number of connections thatcan remain idle within the connection pool, without being released.Alternatively, you can set a negative value for no limit.
DatabaseList.MaxIdle=1
TIP: You can specify the Database connection parameters for each database youwish to monitor individually, underneath your Database Connection Parameters.This allows you to customise your connection settings based on the Databaseconstraints I.e one connection pool for your PRODUCTION DB and another for youTEST DB, for example;
DB1.MaxActive=10
DB1.MaxWait=100
DB1.MaxIdle=1
Notethat any settings defines this way will override the general settings for yourgeneric connection pool.
Database Connection Parameters
Thissection sets your connection string to the Oracle Database. This string invokesa Java Database Connector (JDBC) to your Oracle Databases, and as such does notneed the Oracle Client to be installed.
#define here your connection string for eachdatabase
Hereyou will define the connection string. These are formatted as: DBName.Url(asspecified in your DatabaseList) followed by the jdbc string and your DatabaseServer information.
EXAMPLE1.Url=jdbc:oracle:thin:@SERVER1.EXAMPLE.COM:1521:DB1
Setyour Database username and password below. e.g.
EXAMPLE1.User=zabbix
EXAMPLE1.Password=zabbix_password
TIP: Setting connections to multiple databases is made easy by adding moreconnection strings, with their corresponding credentials. Example given below.
EXAMPLE2.Url=jdbc:oracle:thin:@server2.domain.example.com:
EXAMPLE2.User=zabbix
EXAMPLE2.Password=zabbix_password
EXAMPLE3.Url=jdbc:oracle:thin:@server3.domain.example.com:
EXAMPLE3.User=zabbix
EXAMPLE3.Password=zabbix_password
NOTE:After these entries, you can set your MaxActive, MaxWait and MaxIdle forthe individual database connections if you so wish.
Thereis a pair of default parameter:
DefaultUser =
DefaultPassword =
thisdefault parameter can be overridden using the following pair
Itis only possible to override Username or Password.
Query List File
Thisdefines where the file containing the Oracle (SQL) queries can be found. Thisis a customisable file. You can find the query parameter file at:
QueryListFile=/opt/orabbix/conf/query.props
youcan also specify :
TIP: This is really useful to use different query file for differentdatabases or to have a pool of query file one for each
OracleRelease (if you have different release) and/or to have different query filesfor Production environment, Test environment, Developement environment etc..
thefollowing parameter
addsanother custom query to the default query file. If there are duplicates theExtraQueryListFile will override them.
query.props
Configurationof query.props file
Thequery.props file can be modified or added to, so you can supply your owncustomised queries through Orabbix against your Oracle instances/databases.Each query created has an associated 'Item' or item name that Zabbix will useto identify the query.
NOTE: Item names must be unique.
Theconfigurable items are formatted as follows.
Youhave to set the query name under the QueryList in the query.props file. Eachquery name is comma separated. For example;
QueryList=queryName1,queryName2,queryName3
Youmust identify the query by the unique item name you specified in the QueryList,followed by '.Query' for Orabbix to recognize that this is the query string.Its important to remember NOT to add the semi-colon “;”to the end of your custom query.
customQueryItemName.Query=yourQueryHere
Nowyou can define what you want Orabbix to return to your Zabbix Server if no datais found for your query.
customQueryItemName.NoDataFound=none
TIP: In the example above, Orabbix would send the string “none”to the Zabbix Server.
Youcan specify if you want a different execution period for your query
customQueryItemName.Period=
TIP:You can change the execution time of dbversion that don’t change often
Nextyou can specify a query that will be executed and if return RaceCondiftionValuethe query customQueryItemName is executed otherwise is skipped
customQueryItemName.ACTIVE=[true|false] iftrue query is executed otherwise skipped
archive.Query=select round(A.LOGS*B.AVG/1024/1024/10 ) \
from ( SELECT COUNT (*) LOGS FROM V$LOG_HISTORYWHERE \
FIRST_TIME >= (sysdate -10/60/24)) A, \
( SELECT Avg(BYTES) AVG, Count(1), Max(BYTES) Max_Bytes,Min(BYTES)Min_Bytes FROM v$log) B
archive.RaceConditionQuery=select value \
from \
v$parameter where name='log_archive_start'
archive.RaceConditionValue=FALSE
TIP:In the example above, Orabbix would execute “archive.Query”only if the query“archive.RaceConditionQuery” return the value “archive.RaceConditionValue”. Pratically the “Archive”query is execute only if database is in arhivelogmode (Parameter “log_archive_start” set to TRUE)
iftrue the resultset is trimmed (default is true)
iftrue the add a space between columns of resultset(default is true)
excludefrom result set the 1st, the 2nd etc.. columns from resultset
isused to specify a value or a string to send if a database is not working, doingsuch will "clean" the graphs generated in Zabbix with a"set" value.
Addedthe following parameter on main configuration file:
DefaultUser =
DefaultPassword =
onquery's properties file I've added the following parameter:
withthese parameter you can define a default username and password for all thedatabase.
DefaultUser =
DefaultPassword =
thisdefault parameter can be overridden using the couple
Ispossible to override only Username or Password.
thefollowing parameter
addanother custom query to a default query file. if there are duplicate theExtraQueryListFile will override them.
thefollowing parameter
isused to specify a value or a string to send if a database is not working, doingso you are going to "clean" the graphs generated in Zabbix with a"set" value.
Howto Use Orabbix/FAQ
How do I start/stop the Daemon?
Tostart the Orabbix Daemon, simply run:
/etc/init.d/orabbix start
Tostop the Orabbix Daemon, simply run:
/etc/init.d/orabbix start
How does Logging work?
TheOrabbix daemon outputs its log file to the default location of/opt/orabbix/logs/
How to modify Log format?
Loggingproperties can be modified by making your required changes to
/opt/orabbix/conf/log4j.properties
Theproperty setting responsible for defining the output location is:
log4j.appender.Orabbix.File=logs/orabbix.log
TIP:From this properties file, you can modify the location, file name and logformat as desired. For additional information, please refer to the officiallog4j documentation, found at: http://logging.apache.org/log4j/1.2/index.html
Is there a way for orabbix to connect to RAC or DataGuard?
Yesis possible.
e.g.
Ifyou have two host RAC1 and RAC2 and one instance RACINST
youshould write the connection string as follow:
RACINST.Url=jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=RAC1.EXAMPLE.COM)\
(PORT=1521))(ADDRESS=(PROTOCOL=TCP)(HOST=RAC2.EXAMPLE.COM)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=RACINST)))
Whatcan I modify without restarting the daemon?
Theparameters that are dynamically read at each iteration of “OrabbixDaemon.Sleep”are as follows;
Any Query added to query.props
Modifications to config.props
Database List
Currently,the only known items that don't dynamically update are theZabbixDaemon.MaxThreadNumber, and changes to Connection Pool info

핫 AI 도구

Undresser.AI Undress
사실적인 누드 사진을 만들기 위한 AI 기반 앱

AI Clothes Remover
사진에서 옷을 제거하는 온라인 AI 도구입니다.

Undress AI Tool
무료로 이미지를 벗다

Clothoff.io
AI 옷 제거제

AI Hentai Generator
AI Hentai를 무료로 생성하십시오.

인기 기사

뜨거운 도구

메모장++7.3.1
사용하기 쉬운 무료 코드 편집기

SublimeText3 중국어 버전
중국어 버전, 사용하기 매우 쉽습니다.

스튜디오 13.0.1 보내기
강력한 PHP 통합 개발 환경

드림위버 CS6
시각적 웹 개발 도구

SublimeText3 Mac 버전
신 수준의 코드 편집 소프트웨어(SublimeText3)

뜨거운 주제











MySQL은 오픈 소스 관계형 데이터베이스 관리 시스템으로, 주로 데이터를 신속하고 안정적으로 저장하고 검색하는 데 사용됩니다. 작업 원칙에는 클라이언트 요청, 쿼리 해상도, 쿼리 실행 및 반환 결과가 포함됩니다. 사용의 예로는 테이블 작성, 데이터 삽입 및 쿼리 및 조인 작업과 같은 고급 기능이 포함됩니다. 일반적인 오류에는 SQL 구문, 데이터 유형 및 권한이 포함되며 최적화 제안에는 인덱스 사용, 최적화 된 쿼리 및 테이블 분할이 포함됩니다.

MySQL은 성능, 신뢰성, 사용 편의성 및 커뮤니티 지원을 위해 선택됩니다. 1.MYSQL은 효율적인 데이터 저장 및 검색 기능을 제공하여 여러 데이터 유형 및 고급 쿼리 작업을 지원합니다. 2. 고객-서버 아키텍처 및 다중 스토리지 엔진을 채택하여 트랜잭션 및 쿼리 최적화를 지원합니다. 3. 사용하기 쉽고 다양한 운영 체제 및 프로그래밍 언어를 지원합니다. 4. 강력한 지역 사회 지원을 받고 풍부한 자원과 솔루션을 제공합니다.

Oracle Cursor Closure 문제를 해결하는 방법에는 다음이 포함됩니다. Close 문을 사용하여 커서를 명시 적으로 닫습니다. For Update 절에서 커서를 선언하여 범위가 종료 된 후 자동으로 닫히십시오. 연관된 PL/SQL 변수가 닫히면 자동으로 닫히도록 사용 절에서 커서를 선언하십시오. 예외 처리를 사용하여 예외 상황에서 커서가 닫혀 있는지 확인하십시오. 연결 풀을 사용하여 커서를 자동으로 닫습니다. 자동 제출을 비활성화하고 커서 닫기를 지연시킵니다.

SQL 문은 Oracle의 동적 SQL을 사용하여 런타임 입력을 기반으로 작성 및 실행할 수 있습니다. 단계에는 다음이 포함됩니다 : 동적으로 생성 된 SQL 문을 저장할 빈 문자열 변수 준비. 즉시 실행 또는 준비 명령문을 사용하여 동적 SQL 문을 컴파일하고 실행하십시오. 바인드 변수를 사용하여 사용자 입력 또는 기타 동적 값을 동적 SQL로 전달하십시오. 동적 SQL 문을 실행하려면 즉시 실행 또는 실행을 사용하십시오.

Oracle에서 FOR 루프 루프는 커서를 동적으로 생성 할 수 있습니다. 단계는 다음과 같습니다. 1. 커서 유형을 정의합니다. 2. 루프를 만듭니다. 3. 커서를 동적으로 만듭니다. 4. 커서를 실행하십시오. 5. 커서를 닫습니다. 예 : 커서는 상위 10 명의 직원의 이름과 급여를 표시하기 위해주기별로 만들 수 있습니다.

Oracle에 대한 솔루션은 개설 할 수 없습니다. 1. 데이터베이스 서비스 시작; 2. 청취자를 시작하십시오. 3. 포트 충돌을 확인하십시오. 4. 환경 변수를 올바르게 설정하십시오. 5. 방화벽이나 바이러스 백신 소프트웨어가 연결을 차단하지 않도록하십시오. 6. 서버가 닫혀 있는지 확인하십시오. 7. RMAN을 사용하여 손상된 파일을 복구하십시오. 8. TNS 서비스 이름이 올바른지 확인하십시오. 9. 네트워크 연결 확인; 10. Oracle 소프트웨어를 다시 설치하십시오.

AWR 보고서는 데이터베이스 성능 및 활동 스냅 샷을 표시하는 보고서입니다. 해석 단계에는 다음이 포함됩니다 : 활동 스냅 샷의 날짜 및 시간 식별. 활동 및 자원 소비에 대한 개요를 봅니다. 세션 활동을 분석하여 세션 유형, 자원 소비 및 대기 이벤트를 찾으십시오. 느린 SQL 문, 자원 경합 및 I/O 문제와 같은 잠재적 성능 병목 현상을 찾으십시오. 대기 이벤트를보고, 성능을 위해 식별하고 해결하십시오. 래치 및 메모리 사용 패턴을 분석하여 성능 문제를 일으키는 메모리 문제를 식별하십시오.

Oracle의 트리거는 특정 이벤트 (삽입, 업데이트 또는 삭제) 후 자동으로 작업을 수행하는 데 사용되는 저장된 절차입니다. 데이터 검증, 감사 및 데이터 유지 관리를 포함한 다양한 시나리오에서 사용됩니다. 트리거를 만들 때 트리거 이름, 협회 테이블, 트리거 이벤트 및 트리거 시간을 지정해야합니다. 트리거에는 두 가지 유형이 있습니다. 이전 트리거가 작동하기 전에 발사되고 작업 후 트리거가 발사됩니다. 예를 들어, 이전 삽입 트리거는 삽입 된 행의 연령 열이 음수가 아닌지 확인합니다.
