|
@@ -25,135 +25,135 @@ class TestGangliaServer(RMFTestCase):
|
|
|
|
|
|
def test_configure_default(self):
|
|
|
self.executeScript("2.0.6/services/GANGLIA/package/scripts/ganglia_server.py",
|
|
|
- classname="GangliaServer",
|
|
|
- command="configure",
|
|
|
- config_file="default.json"
|
|
|
+ classname="GangliaServer",
|
|
|
+ command="configure",
|
|
|
+ config_file="default.json"
|
|
|
)
|
|
|
self.assertResourceCalled('Directory', '/usr/libexec/hdp/ganglia',
|
|
|
- owner = 'root',
|
|
|
- group = 'root',
|
|
|
- recursive = True,
|
|
|
- )
|
|
|
+ owner = 'root',
|
|
|
+ group = 'root',
|
|
|
+ recursive = True,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/etc/init.d/hdp-gmetad',
|
|
|
- content = StaticFile('gmetad.init'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('gmetad.init'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/etc/init.d/hdp-gmond',
|
|
|
- content = StaticFile('gmond.init'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('gmond.init'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/checkGmond.sh',
|
|
|
- content = StaticFile('checkGmond.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('checkGmond.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/checkRrdcached.sh',
|
|
|
- content = StaticFile('checkRrdcached.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('checkRrdcached.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/gmetadLib.sh',
|
|
|
- content = StaticFile('gmetadLib.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('gmetadLib.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/gmondLib.sh',
|
|
|
- content = StaticFile('gmondLib.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('gmondLib.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/rrdcachedLib.sh',
|
|
|
- content = StaticFile('rrdcachedLib.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('rrdcachedLib.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/setupGanglia.sh',
|
|
|
- content = StaticFile('setupGanglia.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('setupGanglia.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/startGmetad.sh',
|
|
|
- content = StaticFile('startGmetad.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('startGmetad.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/startGmond.sh',
|
|
|
- content = StaticFile('startGmond.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('startGmond.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/startRrdcached.sh',
|
|
|
- content = StaticFile('startRrdcached.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('startRrdcached.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/stopGmetad.sh',
|
|
|
- content = StaticFile('stopGmetad.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('stopGmetad.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/stopGmond.sh',
|
|
|
- content = StaticFile('stopGmond.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('stopGmond.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/stopRrdcached.sh',
|
|
|
- content = StaticFile('stopRrdcached.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('stopRrdcached.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('File', '/usr/libexec/hdp/ganglia/teardownGanglia.sh',
|
|
|
- content = StaticFile('teardownGanglia.sh'),
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ content = StaticFile('teardownGanglia.sh'),
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('TemplateConfig', '/usr/libexec/hdp/ganglia/gangliaClusters.conf',
|
|
|
- owner = 'root',
|
|
|
- template_tag = None,
|
|
|
- group = 'root',
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ owner = 'root',
|
|
|
+ template_tag = None,
|
|
|
+ group = 'root',
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('TemplateConfig', '/usr/libexec/hdp/ganglia/gangliaEnv.sh',
|
|
|
- owner = 'root',
|
|
|
- template_tag = None,
|
|
|
- group = 'root',
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ owner = 'root',
|
|
|
+ template_tag = None,
|
|
|
+ group = 'root',
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('TemplateConfig', '/usr/libexec/hdp/ganglia/gangliaLib.sh',
|
|
|
- owner = 'root',
|
|
|
- template_tag = None,
|
|
|
- group = 'root',
|
|
|
- mode = 0755,
|
|
|
- )
|
|
|
+ owner = 'root',
|
|
|
+ template_tag = None,
|
|
|
+ group = 'root',
|
|
|
+ mode = 0755,
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPNameNode -m -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
+ path = ['/usr/libexec/hdp/ganglia',
|
|
|
+ '/usr/sbin',
|
|
|
+ '/sbin:/usr/local/bin',
|
|
|
+ '/bin',
|
|
|
+ '/usr/bin'],
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPHBaseMaster -m -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
+ path = ['/usr/libexec/hdp/ganglia',
|
|
|
+ '/usr/sbin',
|
|
|
+ '/sbin:/usr/local/bin',
|
|
|
+ '/bin',
|
|
|
+ '/usr/bin'],
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPResourceManager -m -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
+ path = ['/usr/libexec/hdp/ganglia',
|
|
|
+ '/usr/sbin',
|
|
|
+ '/sbin:/usr/local/bin',
|
|
|
+ '/bin',
|
|
|
+ '/usr/bin'],
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPNodeManager -m -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
+ path = ['/usr/libexec/hdp/ganglia',
|
|
|
+ '/usr/sbin',
|
|
|
+ '/sbin:/usr/local/bin',
|
|
|
+ '/bin',
|
|
|
+ '/usr/bin'],
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPHistoryServer -m -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
+ path = ['/usr/libexec/hdp/ganglia',
|
|
|
+ '/usr/sbin',
|
|
|
+ '/sbin:/usr/local/bin',
|
|
|
+ '/bin',
|
|
|
+ '/usr/bin'],
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPDataNode -m -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
+ path = ['/usr/libexec/hdp/ganglia',
|
|
|
+ '/usr/sbin',
|
|
|
+ '/sbin:/usr/local/bin',
|
|
|
+ '/bin',
|
|
|
+ '/usr/bin'],
|
|
|
+ )
|
|
|
self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -c HDPHBaseRegionServer -m -o root -g hadoop',
|
|
|
path = ['/usr/libexec/hdp/ganglia',
|
|
|
'/usr/sbin',
|
|
@@ -175,14 +175,6 @@ class TestGangliaServer(RMFTestCase):
|
|
|
'/bin',
|
|
|
'/usr/bin'],
|
|
|
)
|
|
|
-
|
|
|
- self.assertResourceCalled('Execute', '/usr/libexec/hdp/ganglia/setupGanglia.sh -t -o root -g hadoop',
|
|
|
- path = ['/usr/libexec/hdp/ganglia',
|
|
|
- '/usr/sbin',
|
|
|
- '/sbin:/usr/local/bin',
|
|
|
- '/bin',
|
|
|
- '/usr/bin'],
|
|
|
- )
|
|
|
self.assertResourceCalled('Directory', '/var/lib/ganglia/dwoo',
|
|
|
owner = 'nobody',
|
|
|
recursive = True,
|