[munin.conf] passage en prod
This commit is contained in:
parent
51a6ba41e1
commit
8690447ffc
2 changed files with 33 additions and 11 deletions
|
@ -1,5 +1,5 @@
|
||||||
<Bundle name="munin-server">
|
<Bundle name="munin-server">
|
||||||
<!-- Todo: avoir un package à installer -->
|
<Package name="munin-server" />
|
||||||
<!-- Fichier de config en test -->
|
<Package name="rrdcached" comment="speed up graphing" />
|
||||||
<Python name="/etc/munin/munin-test.conf"/>
|
<Python name="/etc/munin/munin.conf"/>
|
||||||
</Bundle>
|
</Bundle>
|
||||||
|
|
|
@ -1,8 +1,17 @@
|
||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
# This is work in progress, please do not commit
|
header("munin-server : configuration des hôtes
|
||||||
# --
|
(cette liste est générée par bcfg2)")
|
||||||
# Daniel STAN
|
|
||||||
|
info['owner'] = 'munin'
|
||||||
|
info['group'] = 'adm'
|
||||||
|
|
||||||
|
# TODO (reste à faire)
|
||||||
|
# * Plus d'aggrégation de graphes (voir plus bas)
|
||||||
|
# * Corriger hostnames des serveurs de la ferme (trouver solution moins crade)
|
||||||
|
# * Éventuellement, splitter ce fichier en plusieurs parties (ie les bornes
|
||||||
|
# dans un fichier à part)
|
||||||
|
|
||||||
|
|
||||||
include("ldap_conn")
|
include("ldap_conn")
|
||||||
import annuaires_pg
|
import annuaires_pg
|
||||||
|
@ -16,14 +25,28 @@ htmldir /var/www/munin
|
||||||
logdir /var/log/munin
|
logdir /var/log/munin
|
||||||
rundir /var/run/munin
|
rundir /var/run/munin
|
||||||
|
|
||||||
|
# Communication avec rrdcached (accelère le graphing et le stockage)
|
||||||
|
rrdcached_socket /var/run/rrdcached.sock
|
||||||
|
|
||||||
|
# Where to look for the HTML templates
|
||||||
|
tmpldir /etc/munin/templates
|
||||||
|
|
||||||
# Envoi automatique des alertes par mail.
|
# Envoi automatique des alertes par mail.
|
||||||
contact.roots.command mail -s "Munin - ${var:host} : ${var:graph_title}" nobody@crans.org
|
contact.roots.command mail -s "Munin - ${var:host} : ${var:graph_title}" nobody@crans.org
|
||||||
contact.impression.command mail -s "Munin - ${var:graph_title}" impression@crans.org
|
contact.impression.command mail -s "Munin - ${var:graph_title}" impression@crans.org
|
||||||
|
|
||||||
|
# Nagios
|
||||||
|
contact.nagios.command /usr/sbin/send_nsca -H localhost -c /etc/send_nsca.cfg -to 120 > /dev/null
|
||||||
|
contacts nagios
|
||||||
|
|
||||||
# Les graphes sont réalisés via le CGI
|
# Les graphes sont réalisés via le CGI
|
||||||
graph_strategy cgi
|
graph_strategy cgi
|
||||||
cgiurl /cgi-bin
|
cgiurl /munin-bin
|
||||||
cgiurl_graph /cgi-bin/munin-cgi-graph
|
cgiurl_graph /munin-cgi/munin-cgi-graph
|
||||||
|
|
||||||
|
# Et l'html aussi
|
||||||
|
html_strategy cgi
|
||||||
|
munin_cgi_graph_jobs 6
|
||||||
|
|
||||||
#============================== Les switchs ================================
|
#============================== Les switchs ================================
|
||||||
#Il ne s'agit pas de clients bcfg2 et ne sont par ailleurs pas des nœuds munin
|
#Il ne s'agit pas de clients bcfg2 et ne sont par ailleurs pas des nœuds munin
|
||||||
|
@ -53,12 +76,13 @@ for ap in ldap_conn.search(u'objectClass=borneWifi'):
|
||||||
profile = fqdn.split('.',1)[0]
|
profile = fqdn.split('.',1)[0]
|
||||||
print """[wifi.crans.org;%(profile)s]
|
print """[wifi.crans.org;%(profile)s]
|
||||||
address localhost
|
address localhost
|
||||||
|
update no
|
||||||
|
|
||||||
wifi_clients.graph_title Clients connectés
|
wifi_clients.graph_title Clients connectés
|
||||||
wifi_clients.update no
|
wifi_clients.update no
|
||||||
wifi_clients.graph_category wifi
|
wifi_clients.graph_category wifi
|
||||||
wifi_clients.graph_order \\
|
wifi_clients.graph_order \\
|
||||||
clients=crans.org;gordon.crans.org:wifi_clients.%(profile)s
|
clients=crans.org;dyson.crans.org:wifi_clients.%(profile)s
|
||||||
|
|
||||||
""" % { 'hostname': fqdn,
|
""" % { 'hostname': fqdn,
|
||||||
'profile': profile,
|
'profile': profile,
|
||||||
|
@ -106,8 +130,6 @@ print """
|
||||||
# postfix_all_maildrop(postfix_mailqueue.maildrop)
|
# postfix_all_maildrop(postfix_mailqueue.maildrop)
|
||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
print # Listes des serveurs
|
|
||||||
print """
|
print """
|
||||||
#===================== Serveurs réguliers ==================================
|
#===================== Serveurs réguliers ==================================
|
||||||
# """
|
# """
|
Loading…
Add table
Add a link
Reference in a new issue