While Ganglia is a well known monitoring solution, it was difficult to find and regroup information for a successful and clean install on a 12.04.1 Ubuntu cluster of 30 nodes. In particular, linking the UI and Apache was a bit hackish until I found the symbolic link trick (ie the alias).
What is Ganglia?
Overview/Concepts
Major components
There are 3 main parts to Ganglia: The nodes generating the statistics, the node(s) collecting the statistics, and a web front-end for displaying them.
- gmond: A process running on the monitored nodes. For Ubuntu, this is installed with the ganglia-monitor package:
sudo apt-get install ganglia-monitor
Configuration in /etc/gmond.conf, and associated service is ganglia-monitor.
- gmetad: A process running on one or multiple machines that collects the statistics sent by the various gmond processes in the associated grid. For Ubuntu, this is the package ganglia-webfrontend package:
sudo apt-get install ganglia-webfrontend
Configuration in /etc/gmetad.conf, and associated service is gmetad.
- A web UI: The web front end is installed/contained within the same package as gmetad. The UI is used to display the collected data.
On a multi-nodes deployment, it is possible to verify (or test) the gmond process and to receive an XML dump:
telnet localhost 8649
Note: The above example uses the default port. This port can be changed in /etc/gmond.conf.
Installation
On each Ubuntu nodes used to collect statistics:
# Install service ganglia-monitor -> gmond
sudo apt-get install ganglia-monitor
For the Ubuntu node that collects data and that is used to run the web UI:
# Install ganglia frontend + gmetad
sudo apt-get install ganglia-webfrontend
Note that the above is not sufficient for ganglia to be accessible via HTTP. The Ganglia UI must be deployed within a web application server (e.g. Apache tomcat) to be accessible.
Note: Apache tomcat is installed as a dependency when the ganglia-frontend package is installed. It it also possible to install it separately by entering the following command:
sudo apt-get install apache2
In order to deploy and run Ganglia in Apache tomcat, it is required to copy the apache.conf file from /etc/ganglia-webfrontend/apache.conf to /etc/apache2/sites-enabled/:
sudo cp /etc/ganglia-webfrontend/apache.conf /etc/apache2/sites-enabled/ganglia.conf
Note: The file is renamed to clarify what it is used for.
The /etc/ganglia-webfrontend/apache.conf contains a simple alias for /ganglia towards /sur/share/ganglia-webfrontend.
In my opinion, it is simpler and cleaner to create a symbolic link from etc/ganglia-webfrontend/apache.conf to /etc/apache2/sites-enabled/ such as:
cd /etc/apache2/sites-enabled
sudo ln -s /etc/ganglia-webfrontend/apache.conf ganglia.conf
sudo service apache2 stop
sudo service apache2 start
With the above, and the Apache tomcat server running, the Ganglia UI is available at: <host ip>/ganglia.
Stop/start
Uing Ubuntu services:
sudo service gmetad start
sudo service ganglia-monitor start
Monitoring hadoop 1.0.4
Ganglia can be used to monitor a Hadoop cluster.
In file $HADOOP_HOME/conf/hadoop-metrics2.properties, enable the various sink properties referring to ganglia (remove '#'). Near the end of the file, when specifying the addresses to sink to, use the same address as the mcast_join value found in /etc/gmond.conf, i.e if using multicast:
In file $HADOOP_HOME/conf/hadoop-metrics2.properties, enable the various sink properties referring to ganglia (remove '#'). Near the end of the file, when specifying the addresses to sink to, use the same address as the mcast_join value found in /etc/gmond.conf, i.e if using multicast:
namenode.sink.ganglia.servers=239.2.11.71:8649
datanode.sink.ganglia.servers=239.2.11.71:8649
tasktracker.sink.ganglia.servers=239.2.11.71:8649
...
Monitoring HBase 0.94.5
Ganglia can also be used to monitor an HBase cluster.
In the file $HBASE_HOME/conf/hadoop-metrics.properties, enable the various configuration options for ganglia.
In the file $HBASE_HOME/conf/hadoop-metrics.properties, enable the various configuration options for ganglia.
In the example below, ganglia 3.1.7 is used, and ganglia collects data using multicast (mcast_join value set to =239.2.11.71):
hbase.class=org.apache.hadoop.metrics.ganglia.GangliaContext31
hbase.period=10
hbase.servers=239.2.11.71:8649
jvm.class=org.apache.hadoop.metrics.ganglia.GangliaContext31
jvm.period=10
jvm.servers=239.2.11.71:8649
hbase.class=org.apache.hadoop.metrics.ganglia.GangliaContext31
hbase.period=10
hbase.servers=239.2.11.71:8649
jvm.class=org.apache.hadoop.metrics.ganglia.GangliaContext31
jvm.period=10
jvm.servers=239.2.11.71:8649
References
Ganglia official wiki: http://sourceforge.net/apps/trac/ganglia/wiki/ganglia_readme
extremely useful, managed to setup Ganlia under 30 mins on my Laptop.
ReplyDeleteCheers
please tell me step by step procedure to integrate ganglia.
DeleteAfter the command "sudo apt-get install ganglia-monitor" i am getting this error-
Reading package lists... Error!
E: Encountered a section with no Package: header
E: Problem with MergeList /var/lib/apt/lists/extras.ubuntu.com_ubuntu_dists_precise_main_i18n_Translation-en
Might be that some dependencies were not properly added. Try:
Deletesudo apt-get update
sudo apt-get install ganglia-monitor --fix-missing
Can it be activated from a user terminal, lets say hduser
ReplyDeleteYes surely it is possible
DeleteWhat do you mean?
ReplyDeletethe god save you for us.
ReplyDeleteThe knowledge of technology you have been sharing thorough this post is very much helpful to develop new idea. here by i also want to share this.
ReplyDeleteDigital Marketing Training in Chennai
Digital Marketing Training in Bangalore
digital marketing training in tambaram
digital marketing training in annanagar
All the points you described so beautiful. Every time i read your i blog and i am so surprised that how you can write so well.
ReplyDeletepython training institute in chennai
python training in Bangalore
python training institute in chennai
Great thoughts you got there, believe I may possibly try just some of it throughout my daily life.
ReplyDeleteBlueprism training in marathahalli
Blueprism training in btm
Blueprism online training
A very nice guide. I will definitely follow these tips. Thank you for sharing such detailed article. I am learning a lot from you.
ReplyDeleteData Science training in Chennai
Data science training in bangalore
Data science online training
Data science training in pune
Superb. I really enjoyed very much with this article here. Really it is an amazing article I had ever read. I hope it will help a lot for all. Thank you so much for this amazing posts and please keep update like this excellent article. thank you for sharing such a great blog with us.
ReplyDeletejava training in chennai | java training in bangalore
java training in tambaram | java training in velachery
Some us know all relating to the compelling medium you present powerful steps on this blog and therefore strongly encourage contribution from other ones on this subject while our own child is truly discovering a great deal. Have fun with the remaining portion of the year.
ReplyDeleteangularjs Training in bangalore
angularjs Training in btm
angularjs Training in electronic-city
angularjs online Training
angularjs Training in marathahalli
Thanks for posting useful information.
ReplyDeleteSelenium Training in Chennai
selenium testing training in chennai
iOS Training in Chennai
Digital Marketing Training in Chennai
android training center in chennai
best android training center in chennai
Hello, I read your blog occasionally, and I own a similar one, and I was just wondering if you get a lot of spam remarks? If so how do you stop it, any plugin or anything you can advise?
ReplyDeleteiosh course in chennai
This is exceedingly helpful information, very good work. Thanks for sharing and let me wait for further updates.
ReplyDeleteMachine Learning course in Chennai
Machine Learning Training in Chennai
Data Science Course in Chennai
Data Science Training in Chennai
DevOps certification in Chennai
DevOps Training in Chennai
Machine Learning Training in Velachery
Machine Learning Training in Tambaram
Fantastic work! This is the type of information that should follow collective approximately the web. Embarrassment captivating position Google for not positioning this transmit higher! Enlarge taking place greater than and visit my web situate
ReplyDeleteMicrosoft Azure online training
Selenium online training
Java online training
Java Script online training
Share Point online training
Thanks a lot very much for the high quality and results-oriented help. I won’t think twice to endorse your blog post to anybody who wants and needs support about this area.
ReplyDeleteData Science Training in Chennai
Robotic Process Automation Training in Chennai
Cloud Computing Training in Chennai
Data Warehousing Training in Chennai
Dev Ops Training in Chennai
I recently came across your blog and have been reading along. I thought I would leave my first comment.
ReplyDeletedevops online training
aws online training
data science with python online training
data science online training
rpa online training
It’s always so sweet and also full of a lot of fun for me personally and my office colleagues to search your blog a minimum of thrice in a week to see the new guidance you have got.
ReplyDeleteDotnet Training in Chennai | Dotnet Training course in Chennai
Android Training in Chennai |Best Android Training course in Chennai
CCNA Training in Chennai | CCNA Training course in Chennai
MCSE Training in Chennai | MCSE Training course in Chennai
Embedded Systems Training in Chennai |Embedded Systems Training course in Chennai
Matlab Training in Chennai | Matlab Training course in Chennai
C C++ Training in Chennai | C C++ Training course in Chennai
linux Training in Chennai | NO.1 linux Training in Chennai
Unix Training in Chennai | NO.1 Unix Training in Chennai
Sql Training in Chennai | NO.1 Sql Training in Chennai
My rather long internet look up has at the end of the day been compensated with pleasant insight to talk about with my family and friends.
ReplyDeleteBest PHP Training Institute in Chennai|PHP Course in chennai
Best .Net Training Institute in Chennai
Dotnet Training in Chennai
Dotnet Training in Chennai
Dotnet Training in Chennai
"Thanks for sharing this information with us...
ReplyDeleteDigital Marketing Training Course in Chennai | Digital Marketing Training Course in Anna Nagar | Digital Marketing Training Course in OMR | Digital Marketing Training Course in Porur | Digital Marketing Training Course in Tambaram | Digital Marketing Training Course in Velachery
"
Thanks for the informative article. This is one of the best resources I have found in quite some time. Nicely written and great info. I really cannot thank you enough for sharing.
ReplyDeleteDigital Marketing Training Course in Chennai | Digital Marketing Training Course in Anna Nagar | Digital Marketing Training Course in OMR | Digital Marketing Training Course in Porur | Digital Marketing Training Course in Tambaram | Digital Marketing Training Course in Velachery
Good work and thank you for sharing this information. I congratulate your effort to do this.
ReplyDeleteDigital Marketing Training in Chennai | Certification | SEO Training Course | Digital Marketing Training in Bangalore | Certification | SEO Training Course | Digital Marketing Training in Hyderabad | Certification | SEO Training Course | Digital Marketing Training in Coimbatore | Certification | SEO Training Course | Digital Marketing Online Training | Certification | SEO Online Training Course
I am really enjoying reading your well written articles. It looks like you spend a lot of effort and time on your blog. I have bookmarked it and I am looking forward to reading new articles. Keep up the good work.
ReplyDeleteData Science Training In Chennai
Data Science Online Training In Chennai
Data Science Training In Bangalore
Data Science Training In Hyderabad
Data Science Training In Coimbatore
Data Science Training
Data Science Online Training
This post is so interactive and informative.keep update more information...
ReplyDeleteIELTS Coaching in Pune
IELTS Coaching in Gurgaon
Really nice blog. thanks for sharing
ReplyDeletepython training centre in chennai
best python institute in chennai
This post is so interactive and informative.keep update more information...
ReplyDeleteAndroid Training in Velachery
Android Training in Chennai
This post is so interactive and informative.keep update more information...
ReplyDeleteEthical Hacking Course in Tambaram
Ethical Hacking Course in Chennai