-
Notifications
You must be signed in to change notification settings - Fork 0
/
site.pp
105 lines (92 loc) · 2.56 KB
/
site.pp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
#
# Hadoop frontend manifest.
#
# global parameters
$master1 = 'hador-c1.ics.muni.cz'
$master2 = 'hador-c2.ics.muni.cz'
$zookeepers = [
$master1,
$master2,
'hador.ics.muni.cz',
]
$cluster_name = 'hador-cluster'
$user_group = 'hadoopusers'
$user_gid = 10070
$realm = 'ICS.MUNI.CZ'
include ::stdlib
# java installed separately here to invoke custom parameters
# (hiera would be the better way)
class { '::java_ng':
flavor => 'jdk',
set_default => true,
version => 8,
stage => 'setup',
}
class { '::hadoop':
hdfs_hostname => $master1,
hdfs_hostname2 => $master2,
yarn_hostname => $master2,
yarn_hostname2 => $master1,
historyserver_hostname => $master2,
slaves => [],
journalnode_hostnames => $zookeepers,
zookeeper_hostnames => $zookeepers,
cluster_name => $cluster_name,
# needed for 'yarn logs' also on the client
features => {
'aggregation' => true,
},
properties => {
'dfs.replication' => 4,
# make sense only on the server side (just cosmetics)
'dfs.namenode.name.dir' => '::undef',
'dfs.namenode.checkpoint.dir' => '::undef',
'dfs.datanode.data.dir' => '::undef',
'dfs.journalnode.edits.dir' => '::undef',
'dfs.hosts' => '::undef',
'dfs.ha.automatic-failover.enabled' => '::undef',
'hadoop.http.authentication.signature.secret.file' => '::undef',
'yarn.nodemanager.local-dirs' => '::undef',
},
realm => $realm,
}
class { '::hbase':
hdfs_hostname => $master1,
zookeeper_hostnames => $zookeepers,
# for asynchbase (required also on the client)
properties => {
'hbase.rpc.protection' => '::undef',
},
realm => $realm,
}
class { '::hive':
metastore_hostname => $master1,
server2_hostname => $master1,
zookeeper_hostnames => $zookeepers,
group => $user_group,
realm => $realm,
}
# not deployed yet
#class { '::impala':
#}
class { '::spark':
hdfs_hostname => $cluster_name,
historyserver_hostname => $master2,
historyserver_port => 18088,
jar_enable => true,
realm => $realm,
}
class { '::site_hadoop':
mirror => 'scientific',
# java installed separately
java_enable => false,
# requires additional capabilities
nfs_frontend_enable => false,
# not deployed yet
impala_enable => false,
}
group { $user_group:
gid => $user_gid,
}
include ::site_hadoop::role::frontend
Group[$user_group] -> Class['::site_hadoop::role::frontend']