-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
RH342 - RHEL8.4-en-4-20240626
-
None
-
False
-
-
False
-
2
-
-
-
en-US (English)
Please fill in the following information:
URL: | ch02s08 |
Reporter RHNID: | nhardima |
Section title: | Guided Exercise: Configuring Change Tracking |
Language: | English |
Issue description
at step 6 the script never sends the message to the student, as when there are changes in the filesystem the error code of /sbin/aide --check is 4, not 0, hence the AND never passes.
aide check with no differences returns 0 (true)
aide check with differences returns 4 (false)
Steps to reproduce:
I added an "echo" to the script to better visualize the behavior of the cronjob command:
Notice how the AND never shows the echo "Email was sent"output:
It does with an OR{}:
Workaround:
The AND in the cronjob:
/sbin/aide --check && /root/aide_mon.sh
Should be an OR:
/sbin/aide --check|| & /root/aide_mon.sh