Installing and Setting up mongoDB replica set PREPARED BY SUDHEER KONDLA SOLUTIONS ARCHITECT.

Slides:



Advertisements
Similar presentations
High Availability Deep Dive What’s New in vSphere 5 David Lane, Virtualization Engineer High Point Solutions.
Advertisements

The Premier Software Usage Analysis and Reporting Toolset CELUG Presentation – May 12, 2010 LT-Live : License Tracker’s License Server Monitor.
Optinuity Confidential. All rights reserved. C2O Configuration Requirements.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment Chapter 8: Implementing and Managing Printers.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment, Enhanced Chapter 8: Implementing and Managing Printers.
MCTS Guide to Microsoft Windows Server 2008 Network Infrastructure Configuration Chapter 8 Introduction to Printers in a Windows Server 2008 Network.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment Chapter 8: Implementing and Managing Printers.
Creating Clusters in a Virtual Environment Purpose: To create a development environment with limited hardware resources that allows the testing of parallel.
Virtual Machine and UNIX. What is a VM? VM stands for Virtual Machine. It is a software emulation of hardware. By using a VM, you can have the same hardware.
1 Chapter Overview Introduction to Windows XP Professional Printing Setting Up Network Printers Connecting to Network Printers Configuring Network Printers.
Microsoft ® Application Virtualization 4.5 Infrastructure Planning and Design Series.
Copyright © 2014 EMC Corporation. All Rights Reserved. Exporting NFS File Systems to UNIX/ESXi Upon completion of this module, you should be able to: Export.
Patch Management Module 13. Module You Are Here VMware vSphere 4.1: Install, Configure, Manage – Revision A Operations vSphere Environment Introduction.
VMware vCenter Server Module 4.
Monitor Linux OS health & performance Monitor log files Monitor JEE app servers Monitor line-of-business applications Monitor databases and web.
Virtual Machine Management
Paper on Best implemented scientific concept for E-Governance Virtual Machine By Nitin V. Choudhari, DIO,NIC,Akola By Nitin V. Choudhari, DIO,NIC,Akola.
Microsoft ® Application Virtualization 4.6 Infrastructure Planning and Design Published: September 2008 Updated: February 2010.
System Center 2012 Setup The components of system center App Controller Data Protection Manager Operations Manager Orchestrator Service.
Fundamentals of Networking Discovery 1, Chapter 2 Operating Systems.
1 Web Server Administration Chapter 3 Installing the Server.
Software Engineer, #MongoDBDays.

© 2010 VMware Inc. All rights reserved Patch Management Module 13.
Hands-On Virtual Computing
Module 13: Maintaining Software by Using Windows Server Update Services.
Chapter 8 Implementing Disaster Recovery and High Availability Hands-On Virtual Computing.
Weekly Report By: Devin Trejo Week of May 30, > June 5, 2015.
1 Web Server Administration Chapter 3 Installing the Server.
Module 1: Installing and Upgrading to Exchange Server 2003.
Please Note: Information contained in this document is considered LENOVO CONFIDENTIAL For Lenovo Internal Use Only Do Not Copy or Distribute!! For Lenovo.
MongoDB Replica,Shard Cluster 中央大學電算中心 楊素秋
Linux in a Virtual Environment Nagarajan Prabakar School of Computing and Information Sciences Florida International University.
1 FreeBSD Installation ISOC/AfNOG Michuki Mwangi (Original materials by Hervey Allen – NSRC)
Guide to Linux Installation and Administration, 2e1 Chapter 2 Planning Your System.
VICTORIA UNIVERSITY OF WELLINGTON Te Whare Wananga o te Upoko o te Ika a Maui SWEN 432 Advanced Database Design and Implementation MongoDB Architecture.
1 MONGODB: CH ADMIN CSSE 533 Week 4, Spring, 2015.
 Database Administration Installing Oracle 11g & Creating Database.
Ubuntu, SUSE, OpenSUSE, CentOS & Oracle EL + hundreds on VM Depot Bring your own framework! Ecosystem Supported Microsoft 1st Party Support.
 Load balancing is the process of distributing a workload evenly throughout a group or cluster of computers to maximize throughput.  This means that.
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 12: Planning and Implementing Server Availability and Scalability.
1 Copyright © 2015 Pexus LLC Patriot PS Personal Server Installing Patriot PS ISO Image on.
High Availability in DB2 Nishant Sinha
Chapter 8: Installing Linux The Complete Guide To Linux System Administration.
VirtualBox: How to create a Linux Virtual Machine.
Replication Store it in multiple places.... Literature Colouris, Dollimore, Kindberg, 2000 –Gets deep into the details of reliable communication, byzantine.
Alessandro Cardoso, Microsoft MVP Creating your own “Private Cloud” with Windows 10 Hyper- V WIN443.
Linux Operations and Administration
Installing VERITAS Cluster Server. Topic 1: Using the VERITAS Product Installer After completing this topic, you will be able to install VCS using the.
Deploying Highly Available SQL Server in Windows Azure A Presentation and Demonstration by Microsoft Cluster MVP David Bermingham.
Planning Server Deployments Chapter 1. Server Deployment When planning a server deployment for a large enterprise network, the operating system edition.
SMOOTHWALL FIREWALL By Nitheish Kumarr. INTRODUCTION  Smooth wall Express is a Linux based firewall produced by the Smooth wall Open Source Project Team.
Architecting Enterprise Workloads on AWS Mike Pfeiffer.
CompTIA Server+ Certification (Exam SK0-004)
bitcurator-access-webtools Quick Start Guide
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 12: Planning and Implementing Server Availability and Scalability.
Creating Clusters in a Virtual Environment
Backup A backup of the cluster includes the system state, the node, and the cluster disk.
COP 4343 Unix System Administration
Ops Manager API, Puppet and OpenStack – Fully automated orchestration from scratch! MongoDB World 2016.
MongoDB Distributed Write and Read
Learning MongoDB ZhangGang
VceTests VCE Test Dumps
Lab 1 introduction, debrief
SAP R/3 Installation on WIN NT-ORACLE
ODP node monitoring and maintenance
Different types of Linux installation
bitcurator-access-webtools Quick Start Guide
PerformanceBridge Application Suite and Practice 2.0 IT Specifications
Presentation transcript:

Installing and Setting up mongoDB replica set PREPARED BY SUDHEER KONDLA SOLUTIONS ARCHITECT

 If you have multiple virtual machines, bring up VMs that you want to install mongoDB and set up a replica set.  The presentation is based on VMs created using VMWare’s ESXi/Vsphere and RHEL/Oracle Linux.  This presentation is based on setting up replica set on local machine (Ubuntu 14.14) and  with 6 VMs in the MongoDB cluster (RedHat Linux).  Each VM consists of 2 vCPUs and 4 GB of RAM  Each VM is created with 80 GB of disk space. No special mounts/ file systems are used.  Linux version used: 6.5

Bring up VIRTUAL MACHINES

ESXi Hardware configuration

VM Configuration

Installing mongdb  The following steps guide you through installing mongodb software on Linux.  set yum repository and download packages using yum package installer.  ~]# cd /etc/yum.repos.d/  yum.repos.d]# ls -l  -rw-r--r-- 1 root root 122 Dec 17 20:50 mongodb.repo  yum.repos.d]# scp mongodb.repo bigdata6:/etc/yum.repos.d/  Before you run “yum install”, be sure to check internet is working.  yum.repos.d]# yum install -y mongodb-org mongodb- org-server mongodb-org-shell mongodb-org-mongos mongodb-org-tools-2.6.1

Create yum repository for mongodb

Yum Install mongodb

Setting up mongodb  Make sure to create /data/configdb and /data/db directories on each servers  The above directories should be owned by mongod user and mongod group.  Change ownership to mongod  As a root user run “chown mongod:mongod /data/configdb” and “chown mongod:mongod /data/db”  Without above directories mongod process will not start  When you start mongo daemon process it will create “/data/configdb/mongod.lock” file  You can also start mongod process with service option as root. For example “service mongod start”  You can also configure mongo daemon to start at system boot.

Creating a replica set  This procedure describes deploying a replica set in a development or test environment.  Three member replica sets provide enough redundancy to survive most network partitions and other system failures.replica sets  These sets also have sufficient capacity for many distributed read operations.  Replica sets should always have an odd number of members.  This ensures that elections will proceed smoothly. elections  Before you can deploy a replica set, you must install MongoDB on each system that will be part of yourreplica set.replica set  For test and development systems, you can run your mongod instances on a local system.  The examples in this procedure create a new replica set named rs0.  If your application connects to more than one replica set, each set should have a distinct name.  Some drivers group replica set connections by replica set name.

Setting up local replica sets  Make 3 directories to set up 3 replicas on local node.  mkdir -p /data/mongodb/rs0-0 /data/mongodb/rs0-1 /data/mongodb/rs0-2  Start 3 mongo daemons on local node with 3 different available ports.  mongod --port dbpath /data/mongodb/rs0-0 --replSet rs0 --smallfiles -- oplogSize 128  mongod --port dbpath /data/mongodb/rs0-1 --replSet rs0 --smallfiles -- oplogSize 128  mongod --port dbpath /data/mongodb/rs0-2 --replSet rs0 --smallfiles -- oplogSize 128  Check the mongo daemons running with “ps –ef|grep mongo” command

Initialize and add replica sets on local node.  Connect to first mongo process and initialize mongoDB replica. mongo --port MongoDB shell version: connecting to: :27017/test > rs.initiate() { "info2" : "no configuration explicitly specified -- making one", "me" : "hadoop:27017", "info" : "Config now saved locally. Should come online in about a minute.", "ok" : 1 } > rs.conf() { "_id" : "rs0", "version" : 1, "members" : [ { "_id" : 0, "host" : "hadoop:27017" } ] }

Adding replicas  rs0:PRIMARY> rs.add("hadoop:27018")  { "ok" : 1 }  rs0:PRIMARY> rs.add("hadoop:27019")  { "ok" : 1 }

Replica status

Connect to local replicas

Setting 3 node mongo replica  Install mongodb software on all nodes in the cluster.  Start mongod, mongoes and config servers on all nodes.

Add replica sets on other nodes

Primary and Secondary replica

Connections to Primary replica sets

Connections secondary replica set

CRUD operations on replica sets

Reading from secondary replica

Setting up and Working with MMS  Mongo Management Service (MMS ) automates, monitors, admisters your mongo instances.  Compatible with mongoDB version 2.4 or later.  To use Automation, you must have an agent running on every host where a managed MongoDB instance runs.  Agents do not transmit any data from a MongoDB deployment. The agents only communicate cluster configuration information  You can configure all MongoDB deployment types, including standalones, replica sets, and sharded clusters. You can also configure replica set-member types, such as arbiter, hidden, and delayed secondary, and can configure replica set options, such as priority level.  You can deploy MongoDB to Amazon Web Services (AWS).  MMS Monitoring will scale its request cycle to limit more expensive statistics gathering. The DB Stats information updates every 10 minutes, and the agent will throttle the frequency to reduce the impact on the database  MMS Backup creates backups of MongoDB replica sets and sharded clusters.

Configure Monitor and Backup Agents

MMS Deployment Page

Monitor MongoDB server with MMS