Code Review
/
releng
/
global-jjb.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
(from parent 1:
21fba96
)
Merge "Add a check before running the sysstat script"
author
Jessica Wagantall
<jwagantall@linuxfoundation.org>
Tue, 27 Jun 2017 18:58:20 +0000
(18:58 +0000)
committer
Gerrit Code Review
<gerrit@linuxfoundation.org>
Tue, 27 Jun 2017 18:58:20 +0000
(18:58 +0000)
shell/sysstat.sh
patch
|
blob
|
history
diff --git
a/shell/sysstat.sh
b/shell/sysstat.sh
index
03cab6d
..
d90061c
100644
(file)
--- a/
shell/sysstat.sh
+++ b/
shell/sysstat.sh
@@
-15,6
+15,11
@@
OS=$(facter operatingsystem)
case "$OS" in
Ubuntu)
SYSSTAT_PATH="/var/log/sysstat"
+
+ # Dont run the script when systat is not enabled by default
+ if ! grep --quiet 'ENABLED="true"' "/etc/default/sysstat"; then
+ exit 0
+ fi
;;
CentOS|RedHat)
SYSSTAT_PATH="/var/log/sa"