Section | |||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
[그림] Unlink 설정 화면
기본적인 구성 시나리오의존 관계를 설정하는 일반적인 경우를 살펴보겠습니다. 네트워크 카드, IP 주소 리소스IP 리소스에서 IP를 할당하기 위해서는 먼저 물리적인 네트워크 카드가 필요합니다. 네트워크 카드 없이 IP 할당이 불가능하기 때문입니다. 네트워크 카드를 자식으로, IP를 부모로 하는 의존 관계를 설정하게 되면 IP 온라인을 시도할 때에 먼저 네트워크 카드가 정상적인 상태인지를 확인합니다. 디스크, IP, 데이터베이스많은 응용프로그램들은 디스크(혹은 스토리지)에 데이터를 기록합니다. 따라서 응용프로그램들은 디스크에 의존하는 형태로 관계가 이루어져야 합니다. 데이터베이스의 경우는 데이터를 기록할 디스크를 지정해야 합니다. 따라서 데이터베이스는 디스크에 의존하도록 데이터베이스를 부모로 디스크를 자식으로 의존 관계를 설정합니다. 클라이언트에서 데이터베이스에 접속 할 수 있는 IP 주소가 필요하다면 IP를 자식으로 데이터베이스를 부모로 의존 관계를 설정합니다. 이 의존 관계를 바탕으로 MCCS에서는 그룹을 온라인 할 때, IP와 디스크 마운트가 정상적으로 실행되었는지 확인한 후에 데이터베이스를 구동시킵니다. 따라서 데이터베이스는 IP, 디스크 모두를 의존하는 관계로 설정되어야 합니다. 지금까지의 관계로 의존성을 구성해보면 다음과 같은 형태가 됩니다. [그림] 의존 관계도 의존성에 따른 동작그룹의 시작/종료 순서는 의존성에 따라 온라인은 아래부터 위로, 오프라인은 위부터 아래로 진행됩니다. 그럼 실제 장애가 발생하였을 경우, 리소스 속성을 고려한 진행 순서에 대해 몇 가지 경우를 예로 들어 보겠습니다. 먼저, 리소스 속성과 진행 상태를 다음과 같이 그림으로 미리 정의해 놓았습니다. [그림] 리소스 상태 정보 표시도 Critical 속성critical 리소스보다 하위에서 장애발생그림 88 장애 발생 예 1 (a2를 의존하는 a1으로서는 a2가 장애이므로 a1이 정상적인 온라인이라고 보기 힘듭니다.)
그림 89 장애 발생 예 2 RestartLimit 속성'RestartLimit'는 리소스 타입에 있는 속성으로 최종 장애로 판단하기 전에 몇 번까지 복구할 것인지 결정하는 값입니다. (상세한 내용은 "챕터 5. 리소스 타입" 편을 참조해 주십시오.) [그림] 장애 발생 예 3
Column |
Panel | 이 페이지의 주요 내용 Table of Contents | maxLevel | 4If you want to represent many H/W or S/W elements as resources, you need to define the order of operation for them.
|
[Figure] Online/Offline Sequence of Dependent Resources When Starting or Terminating a Group
Dependency Configuration
define this dependency among resources, configure this link in the ‘Resource Dependency’ view.
[Figure] Dependency relationship
In MCCS, you can configure the dependency relationship of resources by using a tree.
From the above screen, we can find out about the dependency relationship among resources.
The network address resource as a parent depends on the NIC resource as its child. The application resource as a parent depends on the network address resource as its child.
MCCS performs a failover on a group basis. Thus, all the resources within a group should be connected in this dependency relationship and they need to be put into a single group before we can provide meaningful service.
If we set two resources as a parent and an child, we can see it as two vertical levels. The max level can be checked in the 'MaxDependencyLevel' value in the group attribute menu.
Link
[Figure] Setting Link
The above screen shows how to set the link between the process resource (parent) and the network address resource (child).
The network address resource (child) depends on the process resource (parent).
- Select the group relationship editor screen.
- On the right palette screen, select 'Create Dependency'.
- You can see that the mouse cursor shape is changed to support linking.
- First, select the parent resource (process resource) and then select the child resource (network address resource) to finish link setting.
Warning |
---|
※ For linking process, first selected resource is parent resource and the one selected later is the child resource. |
Dependency Removal
[Figure] Setting Unlink
- When you remove the dependency relationship, press 'Select' in the palette.
- Select a link to remove.
- The selected link will have big points at the both ends of resource to indicate the selection made.
- On the selected link, right click with your mouse button and select 'Dependency Removal' in the popup screen.
Basic Dependency Cases among resources
Following are the general cases of dependency.
Network Interface card(NIC) Resource, Network Address Resource
Before assigning an IP address to the network address resource, you need to first have a physical network card. Without a network card, you cannot assign an IP address. If you set the NIC resource as an child and the network address resource as a parent, it will check whether the network card is normal when the network address resources tries to go online.
Disk Resource, Network Address Resource, Application Resource (ex: DB)
Many applications record data in a disk or storage. Thus, applications must depend on disks in the dependency relationship.
If you use the DB, you need to designate the disk to record data in. Thus, for the DB, you must set the dependency relationship where the DB as a parent depends on the disk as a child.
If a client needs an IP address to access the DB, you must set the network address as an child and the DB as a parent. Based on this dependency relationship, when a group goes online in MCCS, first check the network address resource and confirm whether the disk are unlocked properly before running the DB.
Thus the DB should be set to depend on both the network address resource and the disk resource.
We can provide the following configurations based on the dependency relationships discussed so far.
[Figure] Dependency of database application
Actions due to dependency
Online/Offline of the group is performed from bottom to top according to the dependency in case of online, and from top to bottom in case of offline.
Following are a few examples how MCCS manages the resources after dependency link among the resources when a resource is failed.
Attributes and state of resources are defined as the figure below.
[Figure] Resource State Information Charts
Critical Attributes
- Failure occurs from a resource on which critical resource depend.
[Figure] Example of Failure Occur 1
- As a failure is occurred at resource r2, resource r1 will be taken offline. (Since resource r1 depends on resource r2 which is failed, resource r1 may cannot be online properly.)
- Since resource r1 has critical attribute, resource r3 and a4 will be taken offline in order to failover the group.
- As a result, resource r2 is considered as failure and all resources in the group will be taken offline
Non-critical Resources
[Figure] Example of Failure Occur 2
- Resource r1 which is not critical is online status.
- When resource r2 get failed, resource r1 will be taken offline because it dependent on resource r2.
- As r1 resource is not critical, group failover will be not performed. Therefore, the group will be partial online status.
RestartLimit Attribute
RestartLimit is an attribute of the resource type. This value determines how many times the recovery will be attempted until it is finally confirmed that it is failure.
(Please refer to "6. Resource Type" for more details.)
[Figure] Example of Failure Occur 3
- On the assumption that the value of RestartLimit is 1 for resource r2, the first failure has occurred.
- MCCS will bring online resource r2 again as the value of RestartLimit.
At this time, resource r1 which depends on resource r2 will be taken offline. - resource r2 restart.
- resource r1 online.
- When another failure occurs on resource r2, all of the resource will be taken offline from resource r1 to r3 by order.
- Resource r3 will be taken offline.
- As a result, resource r2 is considered as failure and all resources in the group is offline status in the node.