If you can't see the disk I/O utilization in New Relic it may be because you run your server in a OpenVZ container. New Relic does not support this because an OpenVZ container doesn't behave exactly like a real VM--it's a piece of a machine, not running its own full OS, and they don't have capability to monitor disk because OS-level stats are not accessible from the OpenVZ container.
This plugin allows you to monitor your server's disk usage in a OpenVZ container. It does not provide you with i/o information about reads and writes. The purpose of this plugin is to warn you when your disks are almost full.
In order to use this plugin, you must have an active New Relic account.
Plugin should work on any generic Unix environment with the following software components installed:
- Ruby (>= 1.8.7)
- bundler for Ruby: https://github.com/carlhuda/bundler
- cd /opt
git clone https://github.com/Happyr/NewRelic-Disk-Monitor-plugin.git
- Run
cd /opt/NewRelic-Disk-Monitor-plugin
- Run
bundle install
to install required gems - Edit
config/newrelic_plugin.yml
and replace "YOUR_LICENSE_KEY_HERE" with your New Relic license key - Copy the init file for your distribution e.g.
sudo cp /opt/newrelic-disk-monitor/init.d/debian /etc/init.d/newrelic-disk-monitor
- Give the init file the correct permissions with
sudo chmod +x /etc/init.d/newrelic-disk-monitor
- Start the plugin by running
sudo /etc/init.d/newrelic-disk-monitor start
- Make sure you get a representable response from
hostname -f
. - Make sure to update the init file or
/etc/default/newrelic-disk-monitor
with a proper path to the repository clone. - For some init.d scripts make sure that the
newrelic
user has a shell -usermod -s /bin/sh newrelic
. - Check if the plugin has started with
ps aux | grep newrelic-disk-monitor
. If you don't find any running process (except from the ´pscommand) you may remove the pid file.
sudo rm /var/run/newrelic-disk-monitor.pid`.