How to Install and Configure Cluster with Two Nodes in Linux – Part 2

Hi all. Before we start the second part, let’s review about what we have done in Part 01. In Part 01 of this clustering series, we’ve discussed about clustering technique and in which cases it can be used along with the advantages and disadvantages of clustering. And also we have covered the pre-requisites for this setup and what each package will do after we configured the kind of a setup.

Setup Cluster with Multi Nodes

Setup Cluster with Multi Nodes – Part 2

You can review Part 01 and Part 03 from below links.

  1. What is Clustering and Advantages/Disadvantages of Clustering
  2. Fencing and Adding a Failover to Cluster – Part 3

As I said in my last article, that we prefer 3 servers for this setup; one server act as a cluster server and others as nodes.

Cluster Server:



In today’s Part 2, we will see how to install and configure clustering on Linux. For this we need to install below packages in all three servers.

  1. Ricci (ricci-0.16.2-75.el6.x86_64.rpm)
  2. Luci (luci-0.26.0-63.el6.centos.x86_64.rpm)
  3. Mod_cluster (modcluster-0.16.2-29.el6.x86_64.rpm)
  4. CCS (ccs-0.16.2-75.el6_6.2.x86_64.rpm)
  5. CMAN(cman-
  6. Clusterlib (clusterlib-

Step 1: Installing Clustering in Linux

So let’s start installing these packages in all three servers. You can easily install all these packages using yum package manager.

I will start by installing “ricci” package on all these three servers.

# yum install “ricci”
Install Ricci Package

Install Ricci Package

After ricci installation is done, we can see it has installed mod_cluster and cluster lib as its dependencies.

Ricci Installed Summary

Ricci Installed Summary

Next I’m installing luci using yum install “luci” command.

# yum install "luci"
Install Luci Package

Install Luci Package

After the installation of luci, you can see it has installed the dependencies it needed.

Luci Package Installed Summary

Luci Package Installed Summary

Now, let’s install ccs package in the servers. For that I entered yum install ccs.x86_64 which is shown in the list when I issued yum list |grep “ccs” or else you can simply issue yum install “ccs”.

# yum install “ccs”
Install CSS Package

Install CSS Package

Let’s install cman as the last requirement for this particular setup. The command is yum install “cman” or yum install cman.x86_64 as shown in the yum list as I mentioned earlier.

# yum install “cman”
Install CMAN Package

Install CMAN Package

We need to confirm the installations are in place. Issue below command to see whether the packages we needed are installed properly in all three servers.

# rpm -qa | egrep "ricci|luci|modc|cluster|ccs|cman"
All Packages Installed

All Packages Installed

Perfect all the packages are installed and all we need to do is configuring the setup.

Step 2: Configure Cluster in Linux

1. As the first step for setting up the cluster, you need to start the ricci service on all three servers.

# service ricci start 
# /etc/init.d/ricci start 
Start Ricci Service on Cluster Server

Start Ricci Service on Cluster Server

Start Ricci On Node 01

Start Ricci On Node 01

Start Ricci On Node 02

Start Ricci On Node 02

2. Since ricci is started in all servers, now it’s time to create the cluster. This is where ccs package comes to our help when configuring the cluster.

If you don’t want to use ccs commands then you will have to edit the “cluster.conf” file for adding the nodes and do other configs. I guess easiest way is to use following commands. Let’s have a look.

Since I haven’t created the cluster yet, there’s no cluster.conf file created in /etc/cluster location yet as shown below.

# cd /etc/cluster
# pwd
# ls
Check Cluster Configuration File

Check Cluster Configuration File

In my case, I do this in which is dedicated for cluster management. Now onwards, everytime we try to use ricci server, it will ask for ricci’s password. So you will have to set the password of ricci user in all servers.

Enter passwords for ricci user.

# passwd ricci
Set Ricci Password

Set Ricci Password

Now enter the command as shown below.

# ccs -h --createcluster tecmint_cluster

You can see after entering above command, cluster.conf file is created in /etc/cluster directory.

Create Cluster Configuration

Create Cluster Configuration

This is how my default cluster.conf looks like before I do the configs.

Cluster Configuration

Cluster Configuration

3. Now let’s add the two nodes to the system. In here also we use ccs commands to make the configurations. I’m not going to manually edit the cluster.conf file but use the following syntax.

# ccs -h --addnode
Add Nodes to Cluster

Add Nodes to Cluster

Add the other node too.

# ccs -h --addnode
Add Second Node to Cluster

Add Second Node to Cluster

This is how cluster.conf file looks like after adding the node servers.

Cluster Configuration with Nodes

Cluster Configuration with Nodes

You also can enter below command to verify node details.

# ccs –h --lsnodes
Confirm Cluster Node Details

Confirm Cluster Node Details

Perfect. You have successfully created the cluster yourself and added two nodes. For further details about ccs command options, enter ccs –help command and study the details. Since now you know how to create the cluster and add nodes to it, I will post Part 03 soon for you.

Thank you, till then keep connected with Tecmint for handy and latest How To’s.

If You Appreciate What We Do Here On TecMint, You Should Consider:

TecMint is the fastest growing and most trusted community site for any kind of Linux Articles, Guides and Books on the web. Millions of people visit TecMint! to search or browse the thousands of published articles available FREELY to all.

If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.

Support Us

We are thankful for your never ending support.

Thilina Uvindasiri

I'm a BSc Special (Hons) graduate in Information Technology and works as an Engineer-Systems. Love to work, explore and research Linux and play rugby as a hobby.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide
The Complete Linux System Administrator Bundle
Become an Ethical Hacker Bonus Bundle

You may also like...

46 Responses

  1. Dinesh says:

    Dependency missing. Where I can get with all needed dependency

  2. shubham gupta says:

    [[email protected] ~]# ccs -h node01 –createcluster clus_cluster
    Unable to connect to node01, make sure the ricci server is started.

    [[email protected] ~]# service ricci status
    ricci (pid 2416) is running…

    sir , can help me to figure this out , why its showing like “make sure the ricci server is started.” as i ain’t able to proceed further

  3. Gurudatta N.R says:

    Good one mate.

  4. Sujoy KR Batyabyal says:

    Cannot install ricci in Centos 7. It says”No package ricci available.Error: Nothing to do”. Please help in configuring the clustering in Centos 7.

    • Thilina Uvindasiri says:

      As I’ve mentioned in some other queries on the same publish, some packages are deprecated in CentOS 7and RedHat 7. There are new packages introduced.

  5. Enroen says:

    Hi Thilina,
    great article, appriciate.
    but i’m stuck at –>
    $ ccs -h –addfenceinst dsfence Method1
    Method ‘Method1’ not found in node ‘’

    I was installing all cluster package (ricci, clusterlib, modcluster, luci, ccs, cman) on master-server
    should i install luci, ccs and cman on others 2 servers?

    pls advice

  6. premkumar says:

    can anyone share the DRBD configuration steps.

  7. Nauman says:

    I am unable to install ricci on my Centos 7.

  8. Rakesh Negi says:

    Hi Thilina,

    I have created Clusters using LUCI Cluster.conf is created in Nodes but it did not created in master server. I transferred cluster.conf to master using scp.

    I have already raised this query in other posts also, that after creating clusters i am unable to start cman service in master server.

    Unable to get the configuration.
    Cannot find node name in cluster.conf
    cman_tool :Corosync daemon could not start.Check Cluster logs for details.

  9. Clark says:

    Wait, so are all three servers serving content? Such that the CMS server, Node 1, and Node 2 could all be running an Apache webserver? Or is the CMS server not affiliated in this matter?

    • Hi Clark,

      The CMS does not affiliated in any content serving activity. It only serves the purpose of handling Nodes. But if you want the CMS too to serve the content, it not impossible but not recommended by the good standards.

  10. Duncan says:

    Has anyone tried this on Fedora? I am looking to use this for a school project and I want to use more up to date software.

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.