diff options
Diffstat (limited to 'roles/munin-master')
-rw-r--r-- | roles/munin-master/tasks/main.yml | 2 | ||||
-rw-r--r-- | roles/munin-master/templates/etc/munin/munin.conf.j2 | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/roles/munin-master/tasks/main.yml b/roles/munin-master/tasks/main.yml index 9ed3577..aa22ac6 100644 --- a/roles/munin-master/tasks/main.yml +++ b/roles/munin-master/tasks/main.yml @@ -1,32 +1,32 @@ - name: Install munin apt: pkg={{ packages }} vars: packages: - munin - rrdcached - libcgi-fast-perl - name: Configure rrdcached lineinfile: "dest=/etc/default/rrdcached regexp='^#?OPTS=' - line='OPTS=\"-s munin -m 660 -l unix:/var/run/rrdcached.sock -w 1800 -z 1800 -f 3600 -j /var/lib/rrdcached/journal -F -b /var/lib/munin -B\"'" + line='OPTS=\"-s munin -m 660 -l unix:/run/rrdcached.sock -w 1800 -z 1800 -f 3600 -j /var/lib/rrdcached/journal -F -b /var/lib/munin -B\"'" register: r notify: - Restart rrdcached - name: Start rrdcached service: name=rrdcached state=started when: not r.changed - meta: flush_handlers - name: Create directory /var/lib/munin/cgi-tmp/munin-cgi-graph file: path=/var/lib/munin/cgi-tmp/munin-cgi-graph state=directory owner=www-data group=www-data mode=0755 - name: Configure munin template: src=etc/munin/munin.conf.j2 dest=/etc/munin/munin.conf owner=root group=root diff --git a/roles/munin-master/templates/etc/munin/munin.conf.j2 b/roles/munin-master/templates/etc/munin/munin.conf.j2 index 401094a..b53ef0e 100644 --- a/roles/munin-master/templates/etc/munin/munin.conf.j2 +++ b/roles/munin-master/templates/etc/munin/munin.conf.j2 @@ -1,31 +1,31 @@ # Example configuration file for Munin, generated by 'make build' # The next three variables specifies where the location of the RRD # databases, the HTML output, logs and the lock/pid files. They all # must be writable by the user running munin-cron. They are all # defaulted to the values you see here. # #dbdir /var/lib/munin #htmldir /var/cache/munin/www #logdir /var/log/munin -#rundir /var/run/munin +#rundir /run/munin # Where to look for the HTML templates # #tmpldir /etc/munin/templates # Where to look for the static www files # #staticdir /etc/munin/static # temporary cgi files are here. note that it has to be writable by # the cgi user (usually nobody or httpd). # # cgitmpdir /var/lib/munin/cgi-tmp # (Exactly one) directory to include all files from. includedir /etc/munin/munin-conf.d # You can choose the time reference for "DERIVE" like graphs, and show # "per minute", "per hour" values instead of the default "per second" # @@ -66,41 +66,41 @@ graph_strategy cgi # - moving to CGI for HTML means you cannot have graph generated by cron. # - cgi html has some bugs, mostly you still have to launch munin-html by hand # html_strategy cgi # munin-update runs in parallel. # # The default max number of processes is 16, and is probably ok for you. # # If set too high, it might hit some process/ram/filedesc limits. # If set too low, munin-update might take more than 5 min. # # If you want munin-update to not be parallel set it to 0. # #max_processes 16 # RRD updates are per default, performed directly on the rrd files. # To reduce IO and enable the use of the rrdcached, uncomment it and set it to # the location of the socket that rrdcached uses. # -rrdcached_socket /var/run/rrdcached.sock +rrdcached_socket /run/rrdcached.sock # Drop somejuser@fnord.comm and anotheruser@blibb.comm an email everytime # something changes (OK -> WARNING, CRITICAL -> OK, etc) contact.admin.command mail -s "Munin notification" admin@fripost.org # # For those with Nagios, the following might come in handy. In addition, # the services must be defined in the Nagios server as well. #contact.nagios.command /usr/bin/send_nsca nagios.host.comm -c /etc/nsca.conf {% for node in groups.all | sort %} [all;{{ hostvars[node].inventory_hostname_short }}] address {{ ipsec[ hostvars[node].inventory_hostname_short ] }} port 4994 {% for g in hostvars[node].group_names | sort %} [{{ g }};{{ hostvars[node].inventory_hostname_short }}] update no {% endfor %} |