-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
60 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# | ||
# Default settings for /etc/init.d/sysstat, /etc/cron.d/sysstat | ||
# and /etc/cron.daily/sysstat files | ||
# | ||
|
||
# Should sadc collect system activity informations? Valid values | ||
# are "true" and "false". Please do not put other values, they | ||
# will be overwritten by debconf! | ||
ENABLED="true" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# sysstat configuration file. See sysstat(5) manual page. | ||
|
||
# How long to keep log files (in days). | ||
# Used by sa2(8) script | ||
# If value is greater than 28, then log files are kept in | ||
# multiple directories, one for each month. | ||
HISTORY=28 | ||
|
||
# Compress (using xz, gzip or bzip2) sa and sar files older than (in days): | ||
COMPRESSAFTER=7 | ||
|
||
# Parameters for the system activity data collector (see sadc(8) manual page) | ||
# which are used for the generation of log files. | ||
# By default contains the `-S DISK' option responsible for generating disk | ||
# statisitcs. Use `-S XALL' to collect all available statistics. | ||
SADC_OPTIONS="-S XALL" | ||
|
||
# Directory where sa and sar files are saved. | ||
SA_DIR=/var/log/sysstat | ||
|
||
# Compression program to use. | ||
ZIP="xz" | ||
|
||
# By default sa2 script generates yesterday's summary, since the cron job | ||
# usually runs right after midnight. If you want sa2 to generate the summary | ||
# of the same day (for example when cron job runs at 23:53) set this variable. | ||
#YESTERDAY=no | ||
|
||
# By default sa2 script generates reports files (the so called sarDD files). | ||
# Set this variable to false to disable reports generation. | ||
#REPORTS=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -708,5 +708,8 @@ | |
|
||
- include: munin-node.yml | ||
|
||
- include: sysstat.yml | ||
|
||
- include: ntp.yml | ||
when: "not 'vm' in group_names" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
- name: install packages for sysstat | ||
apt: pkg={{ item }} update_cache=yes | ||
with_items: | ||
- sysstat | ||
- xz | ||
when: ansible_distribution == 'Debian' or ansible_distribution == 'Ubuntu' | ||
|
||
- name: Enable sysstat | ||
copy: | ||
src: "{{ item.src }}" | ||
dest: "{{ item.dest }}" | ||
owner: root | ||
mode: "{{ item.mode }}" | ||
loop: | ||
- { src: 'sysstat-default', dest: '/etc/default/sysstat', mode: '0644' } | ||
- { src: 'sysstat.conf', dest: '/etc/sysstat/sysstat', mode: '0644' } | ||
notify: restart sysstat |