Compare commits
2 commits
ae797122ad
...
4008fb3128
Author | SHA1 | Date | |
---|---|---|---|
Jérémy Dubois | 4008fb3128 | ||
Jérémy Dubois | 0dae32a135 |
|
@ -12,6 +12,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
* Log output and runtime config to /var/log/evocheck.log.
|
* Log output and runtime config to /var/log/evocheck.log.
|
||||||
* check_mountfstab and check_mount: make sure all mounted partitions are in fstab and all partitions in fstab are mounted
|
* check_mountfstab and check_mount: make sure all mounted partitions are in fstab and all partitions in fstab are mounted
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
* check_carpadvbase and check_carppreempt: fixed indentation
|
||||||
|
* check_mount: removed useless echo
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
* check_evobackup: zzz_evobackup is now executed with bash
|
* check_evobackup: zzz_evobackup is now executed with bash
|
||||||
|
|
|
@ -168,9 +168,9 @@ check_carpadvbase(){
|
||||||
if ls /etc/hostname.carp* 1> /dev/null 2>&1; then
|
if ls /etc/hostname.carp* 1> /dev/null 2>&1; then
|
||||||
bad_advbase=0
|
bad_advbase=0
|
||||||
for advbase in $(ifconfig carp | grep advbase | awk -F 'advbase' '{print $2}' | awk '{print $1}' | xargs); do
|
for advbase in $(ifconfig carp | grep advbase | awk -F 'advbase' '{print $2}' | awk '{print $1}' | xargs); do
|
||||||
if [ "$advbase" -gt 5 ]; then
|
if [ "$advbase" -gt 5 ]; then
|
||||||
bad_advbase=1
|
bad_advbase=1
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
if [ "$bad_advbase" -eq 1 ]; then
|
if [ "$bad_advbase" -eq 1 ]; then
|
||||||
failed "IS_CARPADVBASE" "At least one CARP interface has advbase greater than 5 seconds!"
|
failed "IS_CARPADVBASE" "At least one CARP interface has advbase greater than 5 seconds!"
|
||||||
|
@ -186,7 +186,7 @@ check_carppreempt(){
|
||||||
if [ -f /etc/sysctl.conf ]; then
|
if [ -f /etc/sysctl.conf ]; then
|
||||||
grep -qE "^net.inet.carp.preempt=1" /etc/sysctl.conf || failed "IS_CARPPREEMPT" "The preempt parameter is not permanently activated! Please add 'net.inet.carp.preempt=1' in /etc/sysctl.conf"
|
grep -qE "^net.inet.carp.preempt=1" /etc/sysctl.conf || failed "IS_CARPPREEMPT" "The preempt parameter is not permanently activated! Please add 'net.inet.carp.preempt=1' in /etc/sysctl.conf"
|
||||||
else
|
else
|
||||||
failed "IS_CARPPREEMPT" "Make sure /etc/sysctl.conf exists and contains the line 'net.inet.carp.preempt=1'"
|
failed "IS_CARPPREEMPT" "Make sure /etc/sysctl.conf exists and contains the line 'net.inet.carp.preempt=1'"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
@ -528,7 +528,7 @@ check_root_user() {
|
||||||
}
|
}
|
||||||
check_mount(){
|
check_mount(){
|
||||||
for fstab_entry in $(grep ffs /etc/fstab | grep -v "^#" | awk '{print $2}'); do
|
for fstab_entry in $(grep ffs /etc/fstab | grep -v "^#" | awk '{print $2}'); do
|
||||||
echo "$(mount | awk '{print $3}')" | grep -q "^$fstab_entry$" || failed "IS_MOUNT" "Local OpenBSD partition(s) detected in /etc/fstab but not mounted"
|
mount | awk '{print $3}' | grep -q "^$fstab_entry$" || failed "IS_MOUNT" "Local OpenBSD partition(s) detected in /etc/fstab but not mounted"
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
check_mountfstab() {
|
check_mountfstab() {
|
||||||
|
|
Loading…
Reference in a new issue