Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marcus Klang
Host Monitor
Commits
1e106baf
Commit
1e106baf
authored
Jun 10, 2021
by
root
Browse files
Better detection of SELinux
parent
b90bd0cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
linux/host-monitor.sh
View file @
1e106baf
...
@@ -62,7 +62,7 @@ LVMDisks="$(lsblk -b | egrep -i lvm | awk '{print $4" "$NF}' | egrep -vi swap |
...
@@ -62,7 +62,7 @@ LVMDisks="$(lsblk -b | egrep -i lvm | awk '{print $4" "$NF}' | egrep -vi swap |
# Flags
# Flags
# SELinux
# SELinux
SELinux
=
"
$(
if
sestatus &>/dev/null
;
then
sestatus | egrep
"^Current mode:"
|
awk
'{print $NF}'
;
else
echo
"Not present"
;
fi
)
"
SELinux
=
"
$(
if
sestatus &>/dev/null
;
then
sestatus | egrep
"^Current mode:
|^SELinux status:
"
|
awk
'{print $NF}'
;
else
echo
"Not present"
;
fi
)
"
# CPU bugs
# CPU bugs
CPUBugs
=
"
$(
egrep
"^bugs"
/proc/cpuinfo |
cut
-d
:
-f2
|
cut
-c2-
|
uniq
)
"
CPUBugs
=
"
$(
egrep
"^bugs"
/proc/cpuinfo |
cut
-d
:
-f2
|
cut
-c2-
|
uniq
)
"
# Ex: CPUBugs='cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs itlb_multihit'
# Ex: CPUBugs='cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs itlb_multihit'
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment