Getting Started With Mesos

Table of contents
Reading Time: 2 minutes

In our earlier blog Introduction to Mesos , we have talked about basic idea of Mesos. And How it works and its basic terminology.

Till now we have discussed the theoretical concepts to get ourselves familiar with Mesos and now we will be going to install the mesos and see how we can monitor mesos using UI, So let’s get onto it.

Step1: Download Mesos Tar File

Download the Mesos 1.4.0 release from here and untar it using the following command on your terminal, and then move to the directory containing our extracted Mesos.

tar -zxf mesos-1.4.0.tar.gz

Follow the following instructions to install required packages and other Mesos dependencies.

# Update the packages.
$ sudo apt-get update

# Install a few utility tools.
$ sudo apt-get install -y tar wget git

# Install the latest OpenJDK.
$ sudo apt-get install -y openjdk-8-jdk

# Install other Mesos dependencies.
$ sudo apt-get -y install build-essential python-dev python-six python-virtualenv libcurl4-nss-dev libsasl2-dev libsasl2-modules maven libapr1-dev libsvn-dev zlib1g-dev

After downloading Mesos and installing required packages and dependencies. Next step is to build Mesos.

# Change working directory.
$ cd mesos

# Configure and build.
$ mkdir build
$ cd build
$ ../configure
$ make
# Run test suite.
$ make check
# Install (optional)
$ make install

It will take little time to build mesos. After building, mesos is ready to use now.

Step2: To run Mesos, first start the Mesos Master

# Change into build directory.
$ cd build

# Start Mesos master (ensure work directory exists and has proper permissions).
$ ./bin/ –ip= –work_dir=/var/lib/mesos

Step3: After starting master, start slave

#start slave
./bin/ –master= –work_dir=/tmp/mesos

#If facing permission issue
./bin/ –master= –work_dir=/tmp/mesos –no-systemd_enable_support

Mesos is running now, to monitor it visit the Mesos Webpage

$ localhost:5050

Screenshot from 2017-10-08 11-15-04

Just for test purpose, we have run c++ and java framework.

$ cd build

# Run C++ framework (exits after successfully running some tasks).
$ ./src/test-framework –master=

# Run Java framework (exits after successfully running some tasks).
$ ./src/examples/java/test-framework

We can see them in completed framework.

Screenshot from 2017-10-08 11-19-33

So, we are done with basic installation of Mesos. I hope you liked it and wanted to know more about usage of Mesos, which we will explore more in future blogs.

Please feel free to suggest or comment!


  1. Mesos Documentation



Written by 

I am a Software Consultant with experience of more than 1.5 years. I am a Functional Programing i.e Scala and Big Data technology enthusiast.I am a active blogger, love to travel, explore and a foodie.

3 thoughts on “Getting Started With Mesos2 min read

Comments are closed.