RHCS Cluster Principle Overview

Source: Internet
Author: User
Tags failover

First, what is RHCs

RHCS is the acronym for Red Hat Cluster suite, which is RHCs, a collection of cluster tools that provide high availability, high reliability, load balancing, storage sharing, and cost-effectively, combining the three clusters in a clustered system to give Web applications, database applications, etc. to provide a secure and stable operating environment.

More specifically, RHCS is a fully functional cluster application solution that provides a proven cluster architecture implementation from front-end access to back-end data storage in the application, and through RHCS provides a solution that not only ensures a durable, stable service for front-end applications, It also ensures the security of back-end data storage.

RHCS provides three cluster architectures in cluster system, namely high availability cluster, load Balancing cluster and storage cluster.

Ii. three core functions provided by RHCS

A highly available cluster is the core function of RHCs. When an application fails, or the system hardware or network fails, the application can automatically and quickly switch from one node to another through the highly available management components provided by RHCS, and the node failover function is transparent to the client, ensuring that the application continues to provide uninterrupted service to the outside, This is what the RHCS high-availability cluster implements.

RHCS provides load balancing clusters through LVS (Linux Virtual Server), and LVs is an open source, powerful IP-based load balancing technology, which consists of load scheduler and service access nodes, and the load dispatch function of LVS, The client request can be distributed evenly to the individual service nodes, but also can define a variety of load allocation policies, when a request comes in, the cluster system according to the scheduling algorithm to determine which service node should be allocated to the request, and then by the assigned node to respond to the client request, at the same time, LVS also provides the service node failover function, that is, when a service node is not able to provide services, LVS will automatically block the failure node, and then remove the failed node from the cluster, while the new node of the request smooth transfer to other normal nodes, and when this failed node returned to normal, The LVS will automatically add this node to the cluster. And this series of switching actions, for the user, are transparent, through the failover function, to ensure uninterrupted, stable operation of the service.

RHCS provides storage clustering functionality through the GFS file system, GFS is the abbreviation for the global File systems, which allows multiple services to read and write to a single shared file system at the same time. Storage clusters eliminate the hassle of synchronizing data between applications by putting shared data into a shared file system, GFS is a distributed file system that coordinates and manages the read and write operations of multiple service nodes to the same file system through a lock management mechanism.

Three, the composition of RHCS cluster

RHCs is a collection of cluster tools, consisting mainly of the following major parts:

Cluster Architecture Manager

This is a basic suite of RHCS clusters, providing the basic functionality of a cluster, which enables the cluster of nodes to work together, including distributed Cluster Manager (CMAN), member relationship management, lock Management (DLM), Profile Management (CCS), and raster devices (FENCE).

Highly available Service Manager

Provides node service monitoring and service failover capabilities to transfer services to another health node when one node service fails.

Cluster configuration management Tools

RHCs the latest version through the Luci to configure and manage RHCs clusters, Luci is a Web-based cluster configuration, the Luci can easily build a powerful cluster system.

LVS (Linux Virtual Server)

LVS is an open-source load balancer software that uses LVS to allocate client requests based on specified load policies and algorithms to each service node, enabling dynamic and intelligent load sharing.

RHCs In addition to the above core components, you can also use the following components to supplement the RHCS cluster functionality.

GFS (Global File System)

GFS is a Redhat company developed a cluster file system, the latest version is the Gfs2,gfs file system allows multiple services to read and write a disk partition, GFS can achieve centralized management of data, eliminating the hassle of data synchronization and copying, but GFs does not exist in isolation, Installing GFS requires RHCS support for the underlying components.

CLVM (Cluster Logical Volume Manager)

Cluster logical volume management, or CLVM, is an extension of LVM that allows machines in cluster to manage shared storage using LVM.

ISCSI

iSCSI is a standard for data block transmission on Internet protocols, especially Ethernet, which is a new type of storage technology based on IP storage theory, and RHCS can be used to export and distribute shared storage through iSCSI technology.

GNBD (Global Network Block Device)

The global network module, referred to as GNBD, is a supplemental component of GFS for RHCS allocation and management of shared storage, GNBD divided into client and server side, GNBD on the server to allow the export of multiple block devices or GNBD files, and GNBD clients by importing these exported block devices or files, You can use them as a local block device. As the GNBD has stopped developing now, the use of GNBD has been decreasing.

Four, RHCS cluster structure

The RHCS cluster is divided into three parts, load balancing clusters, high availability clusters, storage clusters, and:

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M00/77/EE/wKiom1ZxP26AhyanAAEA5ekWqGo409.png "title=" 113908539.png "alt=" Wkiom1zxp26ahyanaaea5ekwqgo409.png "/>

is a typical RHCS cluster topology: The entire topology is divided into three levels:

The top level is the LVS load balancer layer, the middle layer is the real server layer, is the service node part, the last layer is a shared storage layer, mainly for the GFS file system to provide shared storage space.

Five, RHCS cluster operation principle and function introduction

1. Distributed Cluster Manager (CMAN)

Cluster Manager, referred to as Cman, is a distributed cluster management tool that runs on each node of the cluster and provides cluster management tasks for RHCS.

Cman is used to manage cluster members, messages, and notifications. It is through monitoring the running state of each node to understand the relationship between node members, when a node in the cluster fails, the node member relationship will change, Cman timely notice the change to the bottom, and then make corresponding adjustments.

2. Lock Management (DLM)

Distributed lock manager, referred to as DLM, represents a distributed lock manager, which is a basic component of RHCS and provides a common locking mechanism for the cluster, in which the DLM runs on each node of the cluster in the RHCs cluster system. GFS accesses file system metadata synchronously through the lock mechanism of the lock manager. CLVM synchronizes update data to LVM volumes and volume groups through the lock manager.

DLM does not need to set the lock Management Server, it adopts the equivalent lock management mode, greatly improves the processing performance. At the same time, DLM avoids a performance bottleneck that requires overall recovery when a single node fails, and the DLM request is local and does not require a network request, so the request takes effect immediately. Finally, DLM can implement the parallel lock mode of multiple lock spaces through the layered mechanism.

3. Configuration file Management (CCS)

Cluster configuration System, referred to as CCS, is primarily used for cluster configuration file management and synchronization of configuration files between nodes. CCS runs on each node of the cluster, monitoring the state of the single profile/etc/cluster/cluster.conf on each cluster node, updating the change to each node in the cluster whenever the file changes, keeping the profile of each node synchronized at all times. For example, the administrator updates the cluster configuration file on Node A, and when CCS discovers that a node's configuration file changes, the change is propagated to the other nodes immediately.

RHCs's configuration file is cluster.conf, which is an XML file that contains the cluster name, cluster node information, cluster resources and service information, fence devices, and so on, which is described later.

4. Grating equipment (FENCE)

Fence equipment is an essential part of the RHCS cluster, through the fence device can avoid the unpredictable situation caused by the "brain crack" phenomenon, fence equipment, is to solve similar problems, Fence equipment is mainly through the server or storage itself hardware management interface, or external power management device, to the server or storage directly issued hardware management instructions, the server restart or shutdown, or disconnected from the network.

Fence working principle is: when the unexpected cause of the host exception or downtime, the opportunity to first call the fence device, and then through the fence device to restart the exception host or from the network isolation, when the fence operation successfully executed, the return of information to the standby machine, after receiving the fence successful information, Start taking over the services and resources of the host. This frees up the resources occupied by the exception node through the fence device, ensuring that the resources and services are always running on a single node.

RHCs's fence devices can be divided into two types: internal fence and external fence, common internal fence with IBM Rsaii cards, HP's ILO cards, and IPMI devices, and external fence devices with UPS, SAN SWITCH, NETWORK Switch, etc.

5. Highly Available Service Manager

High Availability service management is primarily used to monitor, start, and stop clusters of applications, services, and resources. It provides a management capability for cluster services, when a node's service fails, the High Availability Cluster service management process can transfer services from this failed node to other health nodes, and the service transfer capability is automatic and transparent.

RHCS manages the Cluster service through Rgmanager, Rgmanager runs on each cluster node, and the corresponding process on the server is CLURGMGRD.

In a RHCS cluster, high Availability * * includes cluster services and cluster resources two aspects, Cluster service is actually application services, such as Apache, MySQL, etc., cluster resources have many kinds, such as an IP address, a running script, Ext3/gfs file system.

In a RHCS cluster, a highly available * * is combined with a failed transfer domain, which is a collection of cluster nodes that run a particular service. In the failover domain, you can prioritize each node, prioritize the service transfer when the node fails, and if the node is not assigned a priority, the cluster high-availability service will be transferred between any nodes. Therefore, by creating a failover domain, you can not only set the order in which services are transferred between nodes, but you can restrict a service to switch only within the nodes specified by the failover domain.

6. Cluster Configuration management Tools

RHCS provides a variety of cluster configuration and management tools, commonly used GUI-based system-config-cluster, conga, etc., but also provides command-line-based management tools.

System-config-cluster is a graphical management tool for creating clusters and configuring cluster nodes, which has two components for cluster node configuration and cluster management, which are used to create cluster node profiles and maintain node running status respectively. It is generally used in earlier versions of RHCs.

Conga is a new network-based cluster configuration tool, unlike System-config-cluster, where conga is configured and managed by the Web for cluster nodes. The conga consists of two parts, Luci and Ricci,luci, installed on a single-machine computer for configuring and managing clusters, Ricci installed on each cluster node, and Luci communicating through Ricci and each node in the cluster.

RHCS also provides a number of powerful cluster command-line management tools, commonly used are clustat, Cman_tool, Ccs_tool, Fence_tool, Clusvcadm, and so on, the use of these commands will be described below.

7. Redhat GFS

GFS is a storage solution provided by RHCS for the cluster system, which allows multiple nodes in the cluster to share storage at the block level, each node by sharing a storage space to ensure consistency of access data, more realistically, GFS is a clustered file system provided by RHCS, Multiple nodes simultaneously mount a file system partition, and the file system data is not destroyed, this is a single file system, such as EXT3, EXT2 can not do.

To enable multiple nodes to read and write to a filesystem concurrently, GFS uses a lock manager to manage I/O operations, and when a write process operates a file, the file is locked, and no other process is allowed to read and write until the write process is finished to release the lock, only if the lock is released. Other read and write processes can operate on this file, and when a node modifies data on the GFS file system, this modification is immediately visible to the other nodes through the RHCS underlying communication mechanism.

When building a RHCS cluster, GFS is generally run on each node as a shared store, and GFS can be configured and managed through the RHCS management tool. These need to explain the relationship between RHCs and GFs, the general beginner is easy to confuse the concept: running Rhcs,gfs is not necessary, only need to share storage, only need GFS support, and build GFS cluster file system, must have RHCS of the underlying support, So installing the GFs File system node, you must install the RHCs component.





This article is from the "Little Water Drop" blog, please make sure to keep this source http://wangzan18.blog.51cto.com/8021085/1725373

RHCS Cluster Principle Overview

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.