Show Table of Contents
A.2. Red Hat Enterprise Linux 6.5 および Red Hat Enterprise Linux 7 で Pacemaker を用いたクラスターの作成
Red Hat Enterprise Linux 6.5 リリースは
pcs 設定ツールを使用して、Pacemaker を用いたクラスター設定をサポートします。Pacemaker を使用する場合、Red Hat Enterprise Linux 6.5 と Red Hat Enterprise Linux 7 とでは、クラスターのインストールおよび作成に若干の違いがあります。ここでは、これらのリリースで異なるコマンドを簡単に説明します。Red Hat Enterprise Linux 7 におけるクラスターのインストールおよび作成の詳細は、1章Red Hat High Availability Add-On の設定と管理のリファレンス概要 および 4章クラスターの作成と管理 を参照してください。
A.2.1. Red Hat Enterprise Linux 6.5 および Red Hat Enterprise Linux 7 での Pacemaker のインストール
以下のコマンドは、Pacemaker が必要とする Red Hat High Availability Add-On ソフトウェアパッケージを Red Hat Enterprise Linux 6.5 にインストールし、
cman を使用して corosync が開始されるようにします。クラスターの各ノードでこれらのコマンドを実行する必要があります。
[root@rhel6]#yum install pacemaker cman[root@rhel6]#yum install pcs[root@rhel6]#chkconfig corosync off
Red Hat Enterprise Linux 7 では、Pacemaker が必要とする Red Hat High Availability Add-On ソフトウェアパッケージをインストールするだけでなく、
hacluster という名前の pcs 管理アカウントのパスワードを設定し、pcsd サービスを開始および有効にします。また、クラスターのノードの管理アカウントも認証します。
Red Hat Enterprise Linux 7 では、以下のコマンドをクラスターの各ノードで実行します。
[root@rhel7]#yum install pcs fence-agents-all[root@rhel7]#passwd hacluster[root@rhel7]#systemctl start pcsd.service[root@rhel7]#systemctl enable pcsd.service
Red Hat Enterprise Linux 7 では、以下のコマンドをクラスターのノードの 1 つで実行します。
[root@rhel7]# pcs cluster auth [node] [...] [-u username] [-p password]A.2.2. Red Hat Enterprise Linux 6.5 および Red Hat Enterprise Linux 7 で Pacemaker を用いたクラスターの作成
Red Hat Enterprise Linux 6.5 で Pacemaker クラスターを作成する場合はクラスターの各ノードでクラスターを作成し、クラスターサービスを開始する必要があります。たとえば、
z1.example.com と z2.example.com のノードで構成される my_cluster というクラスターを作成し、これらのノードでクラスターサービスを開始するには、z1.example.com と z2.example.com の両方で以下のコマンドを実行します。
[root@rhel6]#pcs cluster setup --name my_cluster z1.example.com z2.example.com[root@rhel6]#pcs cluster start
Red Hat Enterprise Linux 7 では、クラスターのノードの 1 つでクラスター作成のコマンドを実行します。以下のコマンドを 1 つのノードのみで実行すると、
z1.example.com および z2.example.com というノードで構成される my_cluster という名前のクラスターが作成され、これらのノードでクラスターサービスが開始されます。
[root@rhel7]# pcs cluster setup --start --name my_cluster z1.example.com z2.example.com
Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.