Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Section

 

Column

 

 

Column
width350px

 

Panel

이 페이지의 주요 내용

Table of Contents
maxLevel4

 

 

에이전트란?

에이전트는 리소스를 관리하기 위한 MCCS 내부 프로그램입니다.

MCCS에서는 리소스에 명령을 내리거나 모니터링 하는 것을 에이전트를 통해서 합니다. 에이전트는 리소스 타입에 따라 각자에 리소스에 맞는 기능을 수행합니다.

예를 들면 공유 디스크를 온라인 하는 것은 디스크를 마운트 시키고, 잠금을 풀고, 쓰기 접근(write access)이 가능하도록 처리하는 것이지만 기본 응용프로그램을 온라인 하는 것은 해당 경로의 프로그램을 실행시키는 것을 의미합니다.

에이전트 상태변화

에이전트 상태

...

What is an Agent?

Agent is a program designed to manage the resources.

Each resource type has a corresponding agent. Agents control resources according to its state. The agent aware the resource state and communicates them to MCCS.

A resource cannot be brought online or taken offline without an agent, and the actions required to do either differ from resource to resource. 

For an example, filesystem will be mounted, unlocked, and have the write access to make a disk resource online. However, to make a process resource online is to execute the program.

MCCS agents are multithreaded which means a single agent manages multiple resources in the its type in a cluster.

MCCS provides the following agents.

Agent State Change

Agent State

Agent state can be checked from agent state value from resource state view of detailed information panel.

에이전트 상태

상태 설명

Detached

비활성 상태로서 에이전트 스레드가 시작되지 않은, 따라서 리소스 모니터링을 하지 않는 상태입니다. 
리소스 속성 중에서 Enabled 값이 false인 경우입니다.

Opening

Detached에서 리소스 활성화가 되어 모니터링을 시작할 때의 상태입니다. 
Enabled 값을 true로 변경하는 '리소스 활성화' 설정 명령을 실행할 때에 최초로 진입하는 상태입니다.

Probing

리소스 모니터링을 하는 상태이며 모니터링 결과값을 최초로 판단하게 되면 Online 혹은 Offline로 진입하게 됩니다.

Online

리소스가 온라인 상태에서 모니터링을 하는 상태입니다.

Offline

리소스가 오프라인 상태에서 모니터링 하는 상태입니다. 장애가 발생하여 리소스가 종료되었을 경우에도 에이전트에서는 Offline로 간주합니다.

GoingOffline

온라인 상태인 리소스를 오프라인 상태로 만들기 위한 종료 명령이 실행되고 있는 상태입니다.

GoingOfflineWait

리소스 종료 명령의 실행이 끝난 뒤에 모니터링 결과, 리소스 상태가 오프라인 되기 전의 상태입니다.

GoingOnline

오프라인 상태인 리소스를 온라인 상태로 만들기 위한 시작 명령이 실행되고 있는 상태입니다.

GoingOnlineWait

리소스 시작 명령의 실행이 끝난 뒤에 모니터링 결과, 리소스 상태가 온라인 되기 전의 상태입니다.

에이전트 상태 변화

리소스를 활성화 시키면 Probing에서 모니터링을 시작하게 됩니다.

모니터링 결과에 따라 상태를 결정한 후에 에이전트는 필요한 명령을 받으며 상태가 변화하게 됩니다.

에이전트의 일반적인 상태가 변화하는 흐름은 다음과 같습니다.

Image Removed

[그림] 에이전트 상태 머신

...

It is in disabled state where agent thread hasn't started yet, therefore resource is not monitored yet.
In this case, Enabled value is false in the resource attribute.

Opening

It is preparing to monitor where resource is enabled. 
Enabled value has been changed to true in the resource attribute.

Probing

It is probing and verifying stage where the resource is ready to be used.

Online

Resource is in Online state and is being monitored.

Offline

Resource is in Offline state and is being monitored.
When resource is taken offline for failure, agent considers its state as Offline.

GoingOffline

Agent is taking offline a resource which it is online state.

GoingOfflineWait

It is a state command which agent takes online a resource was completed and resource is ready to offline state.

GoingOnline

Agent is bringing online a resource which it is offline state.

GoingOnlineWait

It is a state command which agent brings online a resource is completed and resource is ready to online.

Agent State Change

When a resource has been enabled, an agent will start monitor a resource after probing and its state will be changed. 

After determining the state based on the results of the monitoring, agent gets the command and 

Below is the flow of the change of agent state. 

Image Added

[Figure] Cycle of Agent State

  1. When a resource is first added, it will be 'Disabled' state and its corresponding agent will be 'Detached' state.
  2. When a resource is 'Enabled', an agent starts monitoring this after process of ‘Opening’ and ‘Probing’.
  3. If a resource in online state is taken offline, an agent becomes 'GoingOffine' and when the command is done, it becomes 'GoingOfflineWait'.
  4. If monitoring result is Offline, agent state is Offline.
    If monitoring result is still Online, it repeats monitoring according to the set number interval it becomes Offline.
    If the time of offline command has exceeded the time value defined in 'OfflineTimeout' attribute, offline process will be canceled and a resource state will go back to online state.
  5. If a resource in offline state has been brought online, agent becomes ‘GoingOnline.’
  6. After 'Online' command is done and becomes 'GoingOnlineWait' monitoring begins and will repeat the monitoring according to value of 'OnlineWaitLimit' attribute in value of 'OfflineMonitorInterval' attributes until it comes online.
    If the monitoring result is that a resource in online state, agent is also online state, and if it does not become online in value of  'OnlineWaitLimit', it is considered as a failure. An agent state will be changed and cycled as above figure according to result of a resource state. But if a resource state is changed by external reasons not by operation through MCCS, this cycle wasn’t applied.
  7. If a resource state changes straight from Online to Offline without operation by MCCS, it is considered as a failure or abnormal state.
    MCCS goes through a change of sending a command and while monitoring, agent state changes as well according to the state. It will go through a state change of 'Going~' and this only applies to MCCS.
  8. For an example, if an online application is terminated due to an external error, it is considered as a failure.
    Also, in case that a resource is brought online on a standby node by force even though a group including this resource has been online on a active node in failover mode group, MCCS considers that this is abnormal state and take offline the resource on a standby node.
  9. If there is no change in the state as shown in the diagram above, it is considered as a failure or abnormal state.