EmergencyEMERGENCY? Get 24/7 Help Now!

Installing Percona Monitoring and Management on Google Container Engine (Kubernetes)

 | December 21, 2016 |  Posted In: Docker, Percona Monitoring and Management, PMM

PREVIOUS POST
NEXT POST

This blog discusses installing Percona Monitoring and Management on Google Container Engine.

I am working with a client that is on Google Cloud Services (GCS) and wants to use Percona Monitoring and Management (PMM). They liked the idea of using Google Container Engine (GKE) to manage the docker container that pmm-server uses.

The regular install instructions are here: https://www.percona.com/doc/percona-monitoring-and-management/install.html

Since Google Container Engine runs on Kubernetes, we had to do some interesting changes to the server install instructions.

First, you will want to get the gcloud shell. This is done by clicking the gcloud shell button at the top right of your screen when logged into your GCS project.

Installing Percona Monitoring and Management

Once you are in the shell, you just need to run some commands to get up and running.

Let’s set our availability zone and region:

Then let’s set up our auth:

Now we are ready to go.

Normally, we create a persistent container called pmm-data to hold the data the server collects and survive container deletions and upgrades. For GCS, we will create persistent disks, and use the minimum (Google) recommended size for each.

Ignoring messages about disk formatting, we are ready to create our Kubernetes cluster:

You should now see something like:

Now that our container manager is up, we need to create 2 configs for the “pod” we are creating to run our container. One will be used only to initialize the server and move the container drives to the persistent disks and the second one will be the actual running server.

Then create it:

Now we need to move data to persistent disks:

Now recreate the pmm-server container with the actual configuration:

It’s up!

Now let’s get access to it by exposing it to the internet:

You can get more information on this by running:

To find the public IP of your PMM server, look under “EXTERNAL-IP”

That’s it, just visit the external IP in your browser and you should see the PMM landing page!

One of the things we didn’t resolve was being able to access the pmm-server container within the vpc. The client had to go through the open internet and hit PMM via the public IP. I hope to work on this some more and resolve this in the future.

I have also talked to our team about making mounts for persistent disks easier so that we can use less mounts and make the configuration and setup easier.

 

 

PREVIOUS POST
NEXT POST
Manjot Singh

Manjot Singh is an Architect with Percona in California. He loves to learn about new technologies and apply them to real world problems. Manjot is a veteran of startup and Fortune 50 enterprise companies alike with a few years spent in government, education, and hospital IT.

2 Comments

  • Hi – if you’re deploying on google with kubernetes, did you consider using sysdig for monitoring? That would provide visibility into the entire infrastructure, containers, network, as well as application-specific metrics. https://www.sysdig.com

    Also – it looks like your first paragraph got cut off.

Leave a Reply