Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
icinga-checks
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IML Open Source
icinga-checks
Commits
8d86c0b7
Commit
8d86c0b7
authored
3 years ago
by
Hahn Axel (hahn)
Browse files
Options
Downloads
Patches
Plain Diff
mysql: check if query cache is enabled as a shared function
parent
2e9e6dd6
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
check_mysqlserver
+6
-7
6 additions, 7 deletions
check_mysqlserver
with
6 additions
and
7 deletions
check_mysqlserver
+
6
−
7
View file @
8d86c0b7
...
...
@@ -189,15 +189,14 @@ function _mysqlrenderdelta() {
# helper function for caching checks
# The function aborts the check ending with OK.
function
_verify_cache
(){
local
bCacheEnabled
=
_mysqlgetvar
"have_query_cache"
|
grep
"YES"
>
/dev/null
if
[
$?
-ne
0
]
;
then
_mysqlgetvar
"q
uery
_
cache
_type"
|
grep
"OFF"
>
/dev/null
if
[
$?
-eq
0
]
;
then
echo
"INFO: Query cache (have_query_cache) is active but query_cache_type is OFF."
else
echo
"INFO: Query cache (have_query_cache) is not active."
fi
echo
"INFO: Q
uery
cache
(have_query_cache) is not active."
ph.exit
fi
_mysqlgetvar
"query_cache_type"
|
grep
"OFF"
>
/dev/null
if
[
$?
-eq
0
]
;
then
echo
"INFO: Query cache (have_query_cache) is active but query_cache_type is OFF."
ph.exit
fi
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment