每當故障監視器嘗試將包含資源的資源群組之故障轉移至其他節點時,RGM 均將呼叫 Monitor_check 方法。 xfnts_monitor_check 方法呼叫 svc_validate() 方法,以確認正確配置已就緒可支援 xfs 常駐程式 (請參閱xfnts_validate 方法以取得詳細資訊)。 xfnts_monitor_check 的程式碼如下所示。
/* Process the arguments passed by RGM and initialize syslog */ if (scds_initialize(&scds_handle, argc, argv) != SCHA_ERR_NOERR) { scds_syslog(LOG_ERR, "Failed to initialize the handle."); return (1); } rc = svc_validate(scds_handle); scds_syslog_debug(DBG_LEVEL_HIGH, "monitor_check method " "was called and returned <%d>.", rc); /* Free up all the memory allocated by scds_initialize */ scds_close(&scds_handle); /* Return the result of validate method run as part of monitor check */ return (rc); }