AUGENRULES(8)
β¨ AUGENRULES β a script that merges component audit rule files β¨
okay bestie, gather round, because augenrules is literally the little admin script that does the β¨mergingβ¨ for you. This is section 8 of the manual (system administration utilities, iykyk), and she is lowkey a lifesaver. π
πΈ SYNOPSIS πΈ
augenrules [--check] [--load]
π¦ DESCRIPTION π¦
So here's the vibe. augenrules is a script that merges all the component audit rules files it can find in the audit rules directory, which is /etc/audit/rules.d, and then drops the merged result into /etc/audit/audit.rules. π
But listen, there's a dress code: component audit rule files must end in .rules to even get processed. Every other file chillin' in /etc/audit/rules.d gets ignored. Sorry not sorry. π
The files get concatenated in order based on their natural sort (peep the -v option of ls(1) if you wanna know what that means), and then they get stripped of empty lines and comment lines (the ones starting with #). Clean. Fresh. Iconic. π§
Now for the main-character directives, because these ones get special treatment: π
- The last processed
-Ddirective without an option, if it's there, is always emitted as the first line in the resultant file. Those-Ddirectives with an option get replicated in place instead. - The last processed
-bdirective, if present, is always emitted as the second line in the resultant file. - The last processed
-fdirective, if present, is always emitted as the third line in the resultant file. - The last processed
-edirective, if present, is always emitted as the last line in the resultant file.
And the plot twist: the generated file is only actually copied to /etc/audit/audit.rules if it differs. No unnecessary writes, no drama. That's the boundary setting we love to see. π«Ά
π OPTIONS π
--checkβ test if the rules have changed and need updating, without overwritingaudit.rules. It's giving "just checking, no commitment". π--loadβ load the old rules or the newly built rules into the kernel. Loaded. Shipped. Deployed. β¨
π FILES π
/etc/audit/rules.d//etc/audit/audit.rules
π₯ SEE ALSO π₯
β heads up bestie: the .rules suffix is not optional, the comment/empty-line stripping is real, and that "only copy if it differs" thing is the whole reason this script is polite. respect the rules directory. π
that's the whole page, periodt π brought to you by Red Hat, dated Apr 2013, and filed under AUGENRULES(8). slay, go merge ur rules. πβ¨
π¦ where this page comes from
- alpine 3.22: audit-doc 4.0.3-r0 Β· LGPL-2.1-or-later
- alpine 3.23: audit-doc 4.1.2-r2 Β· LGPL-2.1-or-later
- alpine 3.24: audit-doc 4.1.2-r6 Β· LGPL-2.1-or-later
- arch rolling: audit 4.2.1-1 Β· GPL-2.0-or-later AND LGPL-2.0-or-later
- centos-stream 10: audit-rules 4.2.1-3.el10 Β· GPL-2.0-or-later
- centos-stream 9: audit 3.1.5-9.el9 Β· GPLv2+
- debian bookworm: auditd 1:3.0.9-1 Β· GPL-2.0-only
- debian trixie: auditd 1:4.0.2-2+deb13u1 Β· GPL-2.0-only
- fedora 43: audit-rules 4.1.1-2.fc43 Β· GPL-2.0-or-later
- fedora 43: audit-rules 4.2.1-1.fc43 Β· GPL-2.0-or-later
- fedora 44: audit-rules 4.1.4-1.fc44 Β· GPL-2.0-or-later
- fedora 44: audit-rules 4.2.1-1.fc44 Β· GPL-2.0-or-later
- nixpkgs unstable: audit 4.2.1
- opensuse-leap 16.0: audit-rules 4.0-160000.2.2 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: audit-rules 4.0-160000.2.2 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: audit-rules 4.0-160000.2.2 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: audit-rules 4.0-160000.2.2 Β· LGPL-2.1-or-later
- ubuntu jammy: auditd 1:3.0.7-1build1 Β· GPL-2.0-only
- ubuntu jammy: auditd 1:3.0.7-1ubuntu0.1 Β· GPL-2.0-only
- ubuntu noble: auditd 1:3.1.2-2.1build1 Β· GPL-2.0-only
- ubuntu noble: auditd 1:3.1.2-2.1ubuntu0.1 Β· GPL-2.0-only
- ubuntu questing: auditd 1:4.0.5-1build1
- ubuntu resolute: auditd 1:4.1.2-1build1 Β· GPL-2.0-only
- ubuntu resolute: auditd 1:4.1.2-1ubuntu0.1 Β· GPL-2.0-only
- ubuntu stonking: auditd 1:4.1.2-1ubuntu1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms