SlideShare a Scribd company logo
MySQL/NoSQL/Cloud
Monitoring with New
Relic
Ronald Bradford
http://ronaldbradford.com
Buenos Aires, Argentina
2013-10
EffectiveMySQL.com - Performance, Scalability & Business Continuity
ABOUT AUTHOR
Ronald Bradford
24 years of RDBMS experience,14 years with MySQL
MySQL Inc (2006-2008)
Oracle Corporation (1996-1999)
Published Author (4 books)
Oracle ACE Director
MySQL community member of the year (2009 & 2013)
All time top MySQL blogger
Provide independent MySQL/
LAMP/Cloud consulting
EffectiveMySQL.com - Performance, Scalability & Business Continuity
Why Monitor?

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Text
Text
Monitoring your technology stack with New Relic
Zabbix
OpenTSDB

Zenoss
Hyperic

Cacti
Nagios
Munin

MySQL Enterprise Monitor

Monitoring
Options

Ganglia
CollectD
StatsD

http://en.wikipedia.org/wiki/Comparison_of_network_monitoring_systems

New Relic

Boundary

DataDog

EffectiveMySQL.com - Performance, Scalability & Business Continuity
New Relic

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
New Relic
Application Monitoring

Historically

Server Monitoring
Software as a Service (SaaS)
Agent-like

EffectiveMySQL.com - Performance, Scalability & Business Continuity
The cloud - SaaS
Minimal installation
Minimal administration
Cloud based management
Web
Mobile
Integrations to other products
EffectiveMySQL.com - Performance, Scalability & Business Continuity
New Relic
Application Monitoring

Introducing

Server Monitoring
NOW - New Relic Platform
<insert product here>

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
NEw Relic
Subscription per server
Standard ($24 p.s. p.m.)
Pro

($149 p.s. p.m.)

YOU CAN GET UNLIMITED
STANDARD FREE BECAUSE BY THE
MySQL PLUGIN AUTHOR
http://j.mp/newrelic-mysql
EffectiveMySQL.com - Performance, Scalability & Business Continuity
1
2
3

No Credit Card Details required

4

http://j.mp/newrelic-mysql
Monitoring your technology stack with New Relic
NAVIGATION

EffectiveMySQL.com - Performance, Scalability & Business Continuity
LICENSE

EffectiveMySQL.com - Performance, Scalability & Business Continuity
ALERTs

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Server
Ubuntu/Debian/RedHat/CentOS/Linux/Windows

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
SERVER INSTALL
LICENSE_KEY="<enter key here>"
sudo rpm -Uvh http://download.newrelic.com/pub/newrelic/
el5/x86_64/newrelic-repo-5-3.noarch.rpm
sudo yum install -y newrelic-sysmond
sudo nrsysmond-config --set license_key=${LICENSE_KEY}
sudo /etc/init.d/newrelic-sysmond start

Helps to use good hostnames

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Application
PHP/Ruby/.NET/Java/Python/Node.js

EffectiveMySQL.com - Performance, Scalability & Business Continuity
PHP, Ruby, .NET, Java, Python, Node.js
PHP INSTALL
LICENSE_KEY="<enter key here>"
sudo rpm -Uvh http://download.newrelic.com/pub/newrelic/
el5/x86_64/newrelic-repo-5-3.noarch.rpm
sudo yum install -y newrelic-php5
sudo newrelic-install install
# prompted for LICENSE_KEY
sudo service httpd restart

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Platform
MySQL/Memcached/Apache/Redis/MongoDB/AWS/...

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
JRE (on some server)

https://github.com/newrelic-platform/newrelic_mysql_java_plugin/
MYSQL INSTALL
Version 1 - Needs streamlining

sudo su LICENSE_KEY="<enter key here>"
wget -O /tmp/newrelic.tar.gz https://raw.github.com/newrelic-platform/
newrelic_mysql_java_plugin/master/dist/newrelic_mysql_plugin-1.0.6.tar.gz
cd /usr/local
tar xvfz /tmp/newrelic.tar.gz
mv newrelic_mysql_plugin-1.* newrelic_mysql_plugin
cd /usr/local/newrelic_mysql_plugin
echo "licenseKey=${LICENSE_KEY}" > config/newrelic.properties
echo "java.util.logging.ConsoleHandler.level = INFO
com.newrelic.metrics.publish.handlers = java.util.logging.ConsoleHandler" >
config/logging.properties
echo '[
{
"name" : "'`hostname -s`'",
"host" : "localhost",
"metrics" : "status,newrelic,innodb,innodb_status,innodb_mutex,slave"
}
]' > config/mysql.instance.json
#mysql < mysql_user.sql
nohup java -jar newrelic_mysql_plugin-*.jar &

https://github.com/newrelic-platform/newrelic_mysql_java_plugin/
EffectiveMySQL.com - Performance, Scalability & Business Continuity
General Views

EffectiveMySQL.com - Performance, Scalability & Business Continuity
navigation

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Summary View
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
More
More
Monitoring your technology stack with New Relic
MYSQL Sources
SHOW GLOBAL STATUS
SHOW MASTER STATUS
SHOW SLAVE STATUS
SHOW ENGINE INNODB STATUS
SHOW ENGINE INNODB MUTEX
<Any SQL statement>
EffectiveMySQL.com - Performance, Scalability & Business Continuity
Coding Features
SHOW ENGINE INNODB MUTEX
Dynamic metric names

Rollup, supporting different formats
in 5.5, 5.6, Percona etc

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Coding Features
SHOW ENGINE INNODB STATUS

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Version 1
Your input and feedback
See limitations

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
Default is “PHP Application”
/etc/php.d/newrelic.inc
newrelic.appname = "PHP Application"
Monitoring your technology stack with New Relic
Other Products

EffectiveMySQL.com - Performance, Scalability & Business Continuity
MEMCACHE INSTALL
LICENSE_KEY="<enter key here>"
sudo pip install newrelic-plugin-agent
sudo cp /opt/newrelic_plugin_agent/newrelic_plugin_agent.cfg 
/etc/newrelic/newrelic_plugin_agent.cfg
sudo
sudo
sudo
sudo
sudo

useradd -m -s /bin/bash newrelic
mkdir -p /var/log/newrelic /var/run/newrelic
chown newrelic:newrelic /var/*/newrelic
vi /etc/newrelic/newrelic_plugin_agent.cfg
newrelic_plugin_agent -c 
/etc/newrelic/newrelic_plugin_agent.cfg -f

https://rpm.newrelic.com/accounts/389698/plugins/directory/53
EffectiveMySQL.com - Performance, Scalability & Business Continuity
EffectiveMySQL.com - Performance, Scalability & Business Continuity
EffectiveMySQL.com - Performance, Scalability & Business Continuity
EffectiveMySQL.com - Performance, Scalability & Business Continuity
meetme plugin
PHP Cache
HTTP Server
CouchDB
Edgecast CDN API
Memcached
MongoDB
Nginx
pgBouncer
PHP FPM

PostgreSQL
RabbitMQ
Redis
Riak
uWSGI

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Other Plugins
Logwatcher

F5

Varnish

AWS EC2/RDS/ELB

Sendgrid

Rabbit MQ

Cassandra

Sphinx

Haproxy

<write your own>

Hadoop
EffectiveMySQL.com - Performance, Scalability & Business Continuity
User Interface

EffectiveMySQL.com - Performance, Scalability & Business Continuity
History

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Click and drag for subset of time
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
Configuration

EffectiveMySQL.com - Performance, Scalability & Business Continuity
MySQL Plugin
Plugin has more features than UI can
support at present
Configurable namespaces
Row/Set SQL statements
Configurable metrics

EffectiveMySQL.com - Performance, Scalability & Business Continuity
MySQL config
$ cat /path/to/config/mysql.instance.json
[
{
"name" : "db1",
"host" : "localhost",
"metrics" : "status,newrelic,innodb_status,
innodb_mutex,master"
},
One agent can collect data from
{
many MySQL Instances
"name" : "db2",
"host" : "db2.hostname.com",
"user" : "monitor",
"password" : "password",
"metrics" : "status,newrelic,slave"
}
]

EffectiveMySQL.com - Performance, Scalability & Business Continuity
namespaces
$ cat /path/to/config/metric.category.json
[
{ "category" : "status",
"SQL" : "SHOW GLOBAL STATUS",
"result" : "set",
"value_metrics":"Max_used_connections,....",
"counter_metrics" :"Bytes_received,Bytes_sent,..."
},
{
"category" : "slave",
"SQL" : "SHOW SLAVE STATUS",
"result" : "row",
"value_metrics" : "Read_Master_Log_Pos,
Slave_IO_Running,
Slave_SQL_Running,

EffectiveMySQL.com - Performance, Scalability & Business Continuity
namespaces
$ cat /path/to/config/metric.category.json
[
{
"category" : "innodb_metrics",
"SQL" : "SELECT name, count FROM
information_schema.innodb_metrics",
"result" : "set",
"comment" : "MySQL 5.6 or later",
"value_metrics" : "...",
"counter_metrics" : "..."
},
...

Current UI does not support with
default MySQL plugin, but
EffectiveMySQL.com - Performance, Scalability & Business Continuity
Modifying plugin
https://github.com/newrelic-platform/
newrelic_mysql_java_plugin
com.newrelic.plugins.mysql.instance.G
UID="new value"
Request to overload via parameter (to
help with current UI limitations)

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Limitations
(Also exist with most monitoring
products)

EffectiveMySQL.com - Performance, Scalability & Business Continuity
sampling
60 seconds (fixed)

EffectiveMySQL.com - Performance, Scalability & Business Continuity
CopperEgg Example
(15 second samples)
averaging
Deceiving

No maximum
support
EffectiveMySQL.com - Performance, Scalability & Business Continuity
alerting limits
Positive range only
Summary metrics
only
No low limits

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Custom Dashboards
Enables you to group graphs together
Does not work with plugins YET!

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Presentation
Likes lots of moving/changing data
Uninteresting values not well supported
replication lag
replication running YES/NO
Important summary alert[able] metric

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Servers
Likes to work on per server basis
Default reporting namespace
Current
com.newrelic.plugins.mysql.instance
[agent] /mysql/status/com_select
[agent] /mysql/status/com*
One Goal
com.newrelic.plugins.mysql.topology
/mysql/status/com_select/<instance>
EffectiveMySQL.com - Performance, Scalability & Business Continuity
What is monitoring the monitoring?
Usage Patterns

EffectiveMySQL.com - Performance, Scalability & Business Continuity
tmp disk tables
High disk I/O - Investigate SQL

EffectiveMySQL.com - Performance, Scalability & Business Continuity
query cache
Query Cache NOT working

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Query CAche
Enabling Query Cache benefit

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
Monitoring your technology stack with New Relic
Yes, this time the
database (servers)
are on fire!
If only I could trigger an
alert on this?
A Developers View

EffectiveMySQL.com - Performance, Scalability & Business Continuity
SQL for developers
Drill down to running queries
Look at ALL thread SQL statements
Aggregations

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Standard Feature
Monitoring your technology stack with New Relic
Standard Feature
Pro Feature
Standard Feature
Pro Feature
Pro Feature
Pro Feature
A better waterfall

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Standard Feature

Still not a DB problem, but,
I need to identify and fix
Monitoring your technology stack with New Relic
Conclusion

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Conclusion
There is no excuse to have NO monitoring
Visualization can generally help show issues
Historical reporting can help review issues
NEITHER WILL SOLVE THE PROBLEM
Hire Ronald Bradford

EffectiveMySQL.com - Performance, Scalability & Business Continuity
Monitoring your technology stack with New Relic
Ronald Bradford
ronald@effectivemysql.com

More Related Content

PDF
MySQL Scalability Mistakes - OTN
PDF
Successful Scalability Principles - Part 1
PDF
Lessons Learned Managing Large AWS Environments
PDF
The History and Future of the MySQL ecosystem
PDF
MySQL Backup and Recovery Essentials
PDF
MySQL Best Practices - OTN LAD Tour
PPT
My two cents about Mysql backup
PDF
MySQL Best Practices - OTN
MySQL Scalability Mistakes - OTN
Successful Scalability Principles - Part 1
Lessons Learned Managing Large AWS Environments
The History and Future of the MySQL ecosystem
MySQL Backup and Recovery Essentials
MySQL Best Practices - OTN LAD Tour
My two cents about Mysql backup
MySQL Best Practices - OTN

What's hot (20)

PDF
MySQL High Availability and Disaster Recovery with Continuent, a VMware company
PDF
MySQL For Oracle DBA's and Developers
PDF
MySQL Enterprise Backup - BnR Scenarios
PDF
MySQL Performance Best Practices
PDF
MySQL Performance Tuning: The Perfect Scalability (OOW2019)
PDF
MySQL 5.7 -- SCaLE Feb 2014
PDF
Posscon my sql56
PDF
MySQL Performance Tuning Variables
PDF
MySQL's new Secure by Default Install -- All Things Open October 20th 2015
KEY
Perf Tuning Short
PDF
MySQL Performance Tuning. Part 1: MySQL Configuration (includes MySQL 5.7)
PDF
MySQL Monitoring 101
PDF
MySQL For Oracle Developers
PDF
My sql 5.7-upcoming-changes-v2
ODP
MySQL 5.7 - What's new and How to upgrade
PDF
Tx lf propercareandfeedmysql
PDF
MySql's NoSQL -- best of both worlds on the same disks
PDF
Scaling MySQl 1 to N Servers -- Los Angelese MySQL User Group Feb 2014
PDF
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
PPT
MySQL 5.6 Updates
MySQL High Availability and Disaster Recovery with Continuent, a VMware company
MySQL For Oracle DBA's and Developers
MySQL Enterprise Backup - BnR Scenarios
MySQL Performance Best Practices
MySQL Performance Tuning: The Perfect Scalability (OOW2019)
MySQL 5.7 -- SCaLE Feb 2014
Posscon my sql56
MySQL Performance Tuning Variables
MySQL's new Secure by Default Install -- All Things Open October 20th 2015
Perf Tuning Short
MySQL Performance Tuning. Part 1: MySQL Configuration (includes MySQL 5.7)
MySQL Monitoring 101
MySQL For Oracle Developers
My sql 5.7-upcoming-changes-v2
MySQL 5.7 - What's new and How to upgrade
Tx lf propercareandfeedmysql
MySql's NoSQL -- best of both worlds on the same disks
Scaling MySQl 1 to N Servers -- Los Angelese MySQL User Group Feb 2014
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
MySQL 5.6 Updates
Ad

Similar to Monitoring your technology stack with New Relic (20)

PDF
MySQL on Docker and Kubernetes
PPTX
A Groovy Kind of Java (San Francisco Java User Group)
PPTX
Test Automation for NoSQL Databases
PPTX
harry presentation
PDF
MySQL Utilities -- PyTexas 2015
PPTX
MySQL 8.0 from December London Open Source Database Meetup
PDF
MySQL Shell for DBAs
PDF
MySQL Document Store
PPT
Ruby on Rails workshop for beginner
ODP
DB proxy server test: run tests on tens of virtual machines with Jenkins, Vag...
PDF
JavaScript and Friends August 20th, 20201 -- MySQL Shell and JavaScript
PDF
Incrementalism: An Industrial Strategy For Adopting Modern Automation
PDF
20201106 hk-py con-mysql-shell
PDF
MySQL up and running 30 minutes.pdf
PDF
Setting up a MySQL Docker Container
PDF
MySQL Shell - The Best MySQL DBA Tool
PDF
DevOps Meetup ansible
PDF
ivanova-samba_backend.pdf
PDF
Burn down the silos! Helping dev and ops gel on high availability websites
PDF
Postgres Vienna DB Meetup 2014
MySQL on Docker and Kubernetes
A Groovy Kind of Java (San Francisco Java User Group)
Test Automation for NoSQL Databases
harry presentation
MySQL Utilities -- PyTexas 2015
MySQL 8.0 from December London Open Source Database Meetup
MySQL Shell for DBAs
MySQL Document Store
Ruby on Rails workshop for beginner
DB proxy server test: run tests on tens of virtual machines with Jenkins, Vag...
JavaScript and Friends August 20th, 20201 -- MySQL Shell and JavaScript
Incrementalism: An Industrial Strategy For Adopting Modern Automation
20201106 hk-py con-mysql-shell
MySQL up and running 30 minutes.pdf
Setting up a MySQL Docker Container
MySQL Shell - The Best MySQL DBA Tool
DevOps Meetup ansible
ivanova-samba_backend.pdf
Burn down the silos! Helping dev and ops gel on high availability websites
Postgres Vienna DB Meetup 2014
Ad

More from Ronald Bradford (20)

PDF
My SQL Idiosyncrasies That Bite OTN
PDF
MySQL Idiosyncrasies That Bite SF
PDF
Successful MySQL Scalability
PDF
MySQL Idiosyncrasies That Bite 2010.07
PDF
Capturing, Analyzing and Optimizing MySQL
PDF
MySQL Idiosyncrasies That Bite
KEY
10x Performance Improvements
PDF
LIFTOFF - MySQLCamp for the Oracle DBA
PDF
IGNITION - MySQLCamp for the Oracle DBA
PDF
10x Performance Improvements - A Case Study
PDF
Dolphins Now And Beyond - FOSDEM 2010
PDF
Drizzle - Status, Principles and Ecosystem
PDF
SQL v No SQL
PDF
MySQL for the Oracle DBA - Object Management
PDF
Know Your Competitor - Oracle 10g Express Edition
PDF
The Ideal Performance Architecture
PDF
Getting started with MySQL on Amazon Web Services
PDF
Best Practices in Migrating to MySQL - Part 1
PDF
Extending The My Sql Data Landscape
PDF
Best Design Practices A
My SQL Idiosyncrasies That Bite OTN
MySQL Idiosyncrasies That Bite SF
Successful MySQL Scalability
MySQL Idiosyncrasies That Bite 2010.07
Capturing, Analyzing and Optimizing MySQL
MySQL Idiosyncrasies That Bite
10x Performance Improvements
LIFTOFF - MySQLCamp for the Oracle DBA
IGNITION - MySQLCamp for the Oracle DBA
10x Performance Improvements - A Case Study
Dolphins Now And Beyond - FOSDEM 2010
Drizzle - Status, Principles and Ecosystem
SQL v No SQL
MySQL for the Oracle DBA - Object Management
Know Your Competitor - Oracle 10g Express Edition
The Ideal Performance Architecture
Getting started with MySQL on Amazon Web Services
Best Practices in Migrating to MySQL - Part 1
Extending The My Sql Data Landscape
Best Design Practices A

Recently uploaded (20)

PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Machine learning based COVID-19 study performance prediction
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Encapsulation theory and applications.pdf
PPTX
Big Data Technologies - Introduction.pptx
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
cuic standard and advanced reporting.pdf
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
Modernizing your data center with Dell and AMD
Advanced methodologies resolving dimensionality complications for autism neur...
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Spectral efficient network and resource selection model in 5G networks
Building Integrated photovoltaic BIPV_UPV.pdf
Understanding_Digital_Forensics_Presentation.pptx
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
CIFDAQ's Market Insight: SEC Turns Pro Crypto
NewMind AI Weekly Chronicles - August'25 Week I
Machine learning based COVID-19 study performance prediction
MYSQL Presentation for SQL database connectivity
Mobile App Security Testing_ A Comprehensive Guide.pdf
Unlocking AI with Model Context Protocol (MCP)
Encapsulation theory and applications.pdf
Big Data Technologies - Introduction.pptx
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
cuic standard and advanced reporting.pdf
The AUB Centre for AI in Media Proposal.docx
Modernizing your data center with Dell and AMD

Monitoring your technology stack with New Relic