Today we will present Vector, an open-source performance monitoring framework that exposes hand-picked system and application metrics to your web browser. Having the right metrics available on-demand and at a high resolution is key to understand how a system behaves and correctly troubleshoot performance issues. It's released under Apache License, Version 2.0.
At the time of writing this tutorial the first version of Vector was just released, as such, you can expect to find bugs and issues.
Installing PCP
Before installing Vector you will first have to install Performance Co-Pilot (PCP). It's an open-source toolkit designed for monitoring and managing system-level performance. It offers support for a wide variety of Operating Systems, including Linux, MacOSX, FreeBSD, IRIX, Solaris and Windows. PCP Is available in all popular distributions.
You can install it in Debian/Ubuntu with:
$ sudo apt-get install pcp
And in Fedore/CentOS with:
$ sudo yum install pcp
You can also install it on Os X, for more information you can check the PCP website.
Installing Vector
First, we will need to install NPM to be able to install bower that vector will be using to install. You can do this on Ubuntu by using the package manager or using the following command:
$ sudo apt-get install npm
Next install bower, an open-source package manager for your web projects, you will also need nodejs for it to work, you can install them using the following commands:
$ sudo apt-get install nodejs-legacy $ sudo npm install -g bower
Now we can start dowloading vector, you can do so in any user directory you wish using git as here:
$ git clone https://github.com/Netflix/vector.git
$ cd vector
We will now use bower package manager to install it:
$ bower install
Next, you will need a webserver to run the files in app, Vector team suggests gulp to do so, you can install gulp using the npm package manager you installed earlier, to install it and run vector use the following commands from the vector folder:
$ npm install --global gulp
$ npm install
$ gulp
You should get the following output:
You can now access your Vector insulation by accessing http://localhost:8080 in your favorite Web browser.
At the moment Vector comes with the following list of widgets and dashboards that can be easily extended. Here is a shortlist of metrics available by default.
CPU
- Load Average
- Runnable
- CPU Utilization
- Per-CPU Utilization
- Context Switches
Memory
- Memory Utilization
- Page Faults
Disk
- Disk IOPS
- Disk Throughput
- Disk Utilization
- Disk Latency
Network
- Network Drops
- TCP Retransmits
- TCP Connections
- Network Throughput
- Network Packets
Conclusion
Vector work on the top of pcp which is really lightweight. It provided system admins to analyze the system and application-level stats in a very real-time manner. Good luck and enjoy your metrics.
Vector requires PCP 3.10.4 or newer, but most distributions have an older version that won't work with Vector. You can get newer packages or build from source as described here: https://github.com/Netflix/vector/wiki/Installing-Performance-Co-Pilot
root0day@ubuntu:~/vector$ npm install
npm WARN deprecated wrench@1.5.9: wrench.js is deprecated! You should check out fs-extra (https://github.com/jprichardson/node-fs-extra) for any operations you were using wrench for. Thanks for all the usage over the years.
How to deal with this error?