]> git.ipfire.org Git - thirdparty/suricata-update.git/commitdiff
Doc: Improve documentation of Suricata reload.
authorAndreas Dolp <dev@andreas-dolp.de>
Mon, 26 Jul 2021 19:44:09 +0000 (21:44 +0200)
committerJason Ish <jason.ish@oisf.net>
Thu, 7 Oct 2021 19:20:51 +0000 (13:20 -0600)
Redmine issue: https://redmine.openinfosecfoundation.org/issues/4564

doc/quickstart.rst
doc/update.rst
suricata/update/configs/update.yaml

index dabc18768cdba6f2743f131b7f5177a00e3d0249..0f17a7b1be19e407bf816069fbbee4526d786a31 100644 (file)
@@ -122,7 +122,8 @@ This command will:
 
 .. note:: Suricata-Update is also capable of triggering a rule reload,
           but doing so requires some extra configuration that will be
-          covered later.
+          covered later. See the documentation of
+          :command:`--reload-command=<command>` for more details.
 
 Configure Suricata to Load Suricata-Update Managed Rules
 ========================================================
index ec692253513f1d263141bd0e054ab3852282e028..19ab525756c0b91a6ac8717aeb673b25f3e72056 100644 (file)
@@ -153,12 +153,26 @@ Options
 .. option:: --reload-command=<command>
 
    A command to run after the rules have been updated; will not run if
-   no change to the output files was made.  For example::
+   no change to the output files was made. For example::
 
-     --reload-command='sudo kill -USR2 $(cat /var/run/suricata.pid)'
+     --reload-command='sudo kill -USR2 $(pidof suricata)'
 
    will tell Suricata to reload its rules.
 
+   Furthermore the reload can be triggered using the Unix socket of Suricata.
+
+   Blocking reload (with Suricata waiting for the reload to finish)::
+
+     --reload-command='sudo suricatasc -c reload-rules'
+
+   Non blocking reload (without restarting Suricata)::
+
+     --reload-command='sudo suricatasc -c ruleset-reload-nonblocking'
+
+   See the Suricata documentation on `Rule Reloads
+   <https://suricata.readthedocs.io/en/latest/rule-management/rule-reload.html>`_
+   for more information.
+
 .. option:: --no-reload
 
    Disable Suricata rule reload.
index e113f539cdf821e5a690c9ff762ee0c9a4db7e70..358e869ddefc5dfc23549bdb638bb777f6b5fb5c 100644 (file)
@@ -36,6 +36,8 @@ ignore:
 
 # Provide a command to reload the Suricata rules.
 # May be overrided by the --reload-command command line option.
+# See the documentation of --reload-command for the different options
+# to reload Suricata rules.
 #reload-command: sudo systemctl reload suricata
 
 # Remote rule sources. Simply a list of URLs.