From 0fdf3ea7d3f054a66bf8cca3893acb12db3cd075 Mon Sep 17 00:00:00 2001 From: phamt Date: Wed, 12 Oct 2011 15:24:10 +0000 Subject: [PATCH] Configure ganglia in gangliastart(). git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@10753 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-UI/xcat/plugins/web.pm | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/xCAT-UI/xcat/plugins/web.pm b/xCAT-UI/xcat/plugins/web.pm index a7f6bdf33..b45f878f4 100644 --- a/xCAT-UI/xcat/plugins/web.pm +++ b/xCAT-UI/xcat/plugins/web.pm @@ -436,7 +436,7 @@ sub web_gangliaconf() { # Run the ganglia configuration script on node if ($nr) { - $output = `moncfg gangliamon $nr -r`; + $output = `moncfg gangliamon $nr -r`; } else { # If no node range is given, then assume all nodes @@ -466,14 +466,23 @@ sub web_gangliastart() { my $info; my $output; + # Add gangliamon to the monitoring table (if not already) + $output = `monadd gangliamon`; + # Start the gmond daemon on node if ($nr) { - $output = `monstart gangliamon $nr -r`; + $output = `moncfg gangliamon $nr -r`; + $output .= `monstart gangliamon $nr -r`; } else { # If no node range is given, then assume all nodes - + # Handle localhost (this needs to be 1st) - $output = `monstart gangliamon`; + $output = `moncfg gangliamon`; + # Handle remote nodes + $output .= `moncfg gangliamon -r`; + + # Handle localhost (this needs to be 1st) + $output .= `monstart gangliamon`; # Handle remote nodes $output .= `monstart gangliamon -r`; }