Book Image

CentOS 7 Server Deployment Cookbook

By : Timothy Boronczyk, IRAKLI NADAREISHVILI
Book Image

CentOS 7 Server Deployment Cookbook

By: Timothy Boronczyk, IRAKLI NADAREISHVILI

Overview of this book

CentOS is derived from Red Hat Enterprise Linux (RHEL) sources and is widely used as a Linux server. This book will help you to better configure and manage Linux servers in varying scenarios and business requirements. Starting with installing CentOS, this book will walk you through the networking aspects of CentOS. You will then learn how to manage users and their permissions, software installs, disks, filesystems, and so on. You’ll then see how to secure connection to remotely access a desktop and work with databases. Toward the end, you will find out how to manage DNS, e-mails, web servers, and more. You will also learn to detect threats by monitoring network intrusion. Finally, the book will cover virtualization techniques that will help you make the most of CentOS.
Table of Contents (18 chapters)
CentOS 7 Server Deployment Cookbook
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface

Configuring a MongoDB replica set


This recipe teaches you how to configure replication using MongoDB replica sets.

When replication is performed using replica sets, one installation of MongoDB identifies as the primary server while others in the cluster are secondaries. The primary server accepts writes, which are replicated to the secondaries, while the secondaries service read requests. If the primary server goes down, the secondary servers automatically call a quorum and promote one of the secondaries to fill the primary's role. The old primary rejoins the cluster when it comes back on line. This configuration provides redundancy, distributed read/write access, and automatic failover for high-availability.

Getting ready

This recipe demonstrates configuring replica sets using three systems. The first system will be the cluster's primary server and we assume that its IP address is 192.168.56.100. The other two systems will be secondary servers using the addresses 192.168.56.102 and 192.168...