DB2 故障监视器工具 Linux® 版和 UNIX 版

DB2® 故障监视器工具仅在基于 UNIX® 的系统上可用,该工具通过监视 DB2 数据库管理器实例并重新启动任何过早退出的实例来使 DB2 数据库正常运行。

故障监视器协调程序(FMC)是在 UNIX 引导序列中启动的“故障监视器工具”的进程。init 守护程序启动 FMC,并在 FMC 异常终止时重新启动 FMC。FMC 对每个 DB2 实例启动一个故障监视器。每个故障监视器都作为一个守护进程来运行,并且具有与 DB2 实例相同的用户特权。

一旦启动了故障监视器,就会监视 DB2 实例以确保它不会过早退出。如果故障监视器发生故障,那么将通过 FMC 将它重新启动。每个故障监视器将依次负责监视一个 DB2 实例。如果 DB2 实例过早退出,那么故障监视器会将其重新启动。仅当发出 db2stop 命令时,故障监视器才变为不活动状态。如果 DB2 实例以任何其他方式关闭,故障监视器都会将其再次启动。

DB2 故障监视器限制

由于实例的启动和关闭是由集群产品控制的,所以,如果正在使用高可用性集群产品(例如,HACMP™、MSCS 或 IBM® Tivoli® System Automation for titolatforms),那么必须关闭故障监视器工具。

DB2 故障监视器与 DB2 运行状况监视器之间的差别

运行状况监视器和故障监视器是作用于单个数据库实例的工具。运行状况监视器使用运行状况指示器来评估数据库管理器性能或数据库性能特定方面的运行状况。运行状况指示器测量特定种类数据库对象(例如表空间)某些方面的运行状况。可以针对特定条件评估运行状况指示器以确定该类数据库对象的运行状况。此外,当某个运行状况指示器超出阈值或指示某个数据库对象处于非正常状态时,运行状况指示器可以生成警报以通知您。

与之对比,故障监视器仅仅负责保持它所监视的实例正常运行。如果它所监视的 DB2 实例意外终止,那么故障监视器就会重新启动该实例。故障监视器在 Windows® 上不可用。

db2fm - DB2 fault monitor command

Controls the DB2® fault monitor daemon. You can use db2fm to configure the fault monitor.

This command is only available on UNIX operating systems.

Authorization

Authorization over the instance against which you are running the command.

Required connection

None

Command syntax

>>-db2fm--+- -t--service--+-- -m--module path------------------->
          '- -i--instance-'                     

>--+--------------+--------------------------------------------><
   +- -u----------+   
   +- -d----------+   
   +- -s----------+   
   +- -k----------+   
   +- -U----------+   
   +- -D----------+   
   +- -S----------+   
   +- -K----------+   
   +- -f--+-on--+-+   
   |      '-off-' |   
   +- -a--+-on--+-+   
   |      '-off-' |   
   +- -T--T1/T2---+   
   +- -l--I1/I2---+   
   +- -R--R1/R2---+   
   +- -n--email---+   
   +- -h----------+   
   '- -?----------'   

Command parameters

-m module-path
Defines the full path of the fault monitor shared library for the product being monitored. The default is $INSTANCEHOME/sqllib/lib/libdb2gcf.
-t service
Gives the unique text descriptor for a service.
-i instance
Defines the instance of the service.
-u
Brings the service up.
-U
Brings the fault monitor daemon up.
-d
Brings the instance down.
-D
Brings the fault monitor daemon down.
-k
Kills the service.
-K
Kills the fault monitor daemon.
-s
Returns the status of the service.
-S
Returns the status of the fault monitor daemon. The status of the service or fault monitor can be one of the following
  • Not properly installed,
  • INSTALLED PROPERLY but NOT ALIVE,
  • ALIVE but NOT AVAILABLE (maintenance),
  • AVAILABLE, or
  • UNKNOWN
-f on | off
Turns fault monitor ON or OFF. If this option is set off, the fault monitor daemon will not be started, or the daemon will exit if it was running.
-a on | off
Activates or deactivates fault monitoring. If this option if set to OFF, the fault monitor will not be actively monitoring, which means if the service goes down it will not try to bring it back.
-T T1/T2
Overwrites the start and stop time-out.
For example:
  • -T 15/10 updates the two time-outs respectively
  • -T 15 updates the start time-out to 15 secs
  • -T /10 updates the stop time-out to 10 secs
-I I1/I2
Sets the status interval and time-out respectively.
-R R1/R2
Sets the number of retries for the status method and action before giving up.
-n email
Sets the email address for notification of events.
-h | -?
Displays command usage help.

Usage notes

  • If you want to set up e-mail notifications to be sent by the fault monitor daemon, you must have SMTP running on the local host.

你可能感兴趣的:(linux,db2,监视器,db2fm,DB2故障监视器)