public inbox for pmg-devel@lists.proxmox.com
 help / color / mirror / Atom feed
* [pmg-devel] [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info
@ 2021-08-24  9:33 Mira Limbeck
  2021-08-24  9:33 ` [pmg-devel] [PATCH v2 pmg-docs 2/2] add documentation for the pmg-log-tracker Mira Limbeck
  2021-09-03 10:54 ` [pmg-devel] applied: [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info Stoiko Ivanov
  0 siblings, 2 replies; 4+ messages in thread
From: Mira Limbeck @ 2021-08-24  9:33 UTC (permalink / raw)
  To: pmg-devel

The case of customizing the service and timer files comes up from time
to time. As we haven't documented it yet, add it to the documentation
together with a clarification of the `yesterday` timespan parameter.

Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
---
v2:
 - reworded based on Dylan's suggestions

 pmgqm.adoc | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/pmgqm.adoc b/pmgqm.adoc
index 08ad172..046c91e 100644
--- a/pmgqm.adoc
+++ b/pmgqm.adoc
@@ -27,6 +27,23 @@ endif::manvolnum[]
 
 Toolkit to manage spam and virus quarantine, and send spam report mails.
 
+The possible timespans are `week`, `yesterday`, and `today`. The default
+pmgspamreport.service is run at 00:05 every day and calls the `pmgqm` command
+with the `--timespan yesterday` parameter.
+This will send a spam report if at least one new spam mail was moved to the
+quarantine since the beginning of the previous day.
+
+The service can be edited, for example, to change the timespan to `today` or
+`week`, with the following command:
+----
+systemctl edit pmgspamreport.service
+----
+
+The timer can be edited with the command below:
+----
+systemctl edit pmgspamreport.timer
+----
+
 ifdef::manvolnum[]
 include::pmg-copyright.adoc[]
 endif::manvolnum[]
-- 
2.30.2





^ permalink raw reply	[flat|nested] 4+ messages in thread

* [pmg-devel] [PATCH v2 pmg-docs 2/2] add documentation for the pmg-log-tracker
  2021-08-24  9:33 [pmg-devel] [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info Mira Limbeck
@ 2021-08-24  9:33 ` Mira Limbeck
  2021-09-03 10:55   ` [pmg-devel] applied: " Stoiko Ivanov
  2021-09-03 10:54 ` [pmg-devel] applied: [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info Stoiko Ivanov
  1 sibling, 1 reply; 4+ messages in thread
From: Mira Limbeck @ 2021-08-24  9:33 UTC (permalink / raw)
  To: pmg-devel

The Tracking Center makes assumptions which are working fine for most of
the users, but not for some.
It might be useful for some users to know that this exists and is the
backend for the Tracking Center.

Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
---
v2:
 - reworded based on Dylan's suggestions
 - removed reference to pmg-log-tracker manpage which doesn't yet exist

 pmg-admin-guide.adoc |  2 ++
 pmg-log-tracker.adoc | 36 ++++++++++++++++++++++++++++++++++++
 2 files changed, 38 insertions(+)
 create mode 100644 pmg-log-tracker.adoc

diff --git a/pmg-admin-guide.adoc b/pmg-admin-guide.adoc
index 043b94a..5ca2b0c 100644
--- a/pmg-admin-guide.adoc
+++ b/pmg-admin-guide.adoc
@@ -79,6 +79,8 @@ include::pmgreport.adoc[]
 
 include::pmgupgrade.adoc[]
 
+include::pmg-log-tracker.adoc[]
+
 :leveloffset: 1
 
 include::nmap.adoc[]
diff --git a/pmg-log-tracker.adoc b/pmg-log-tracker.adoc
new file mode 100644
index 0000000..3be58a8
--- /dev/null
+++ b/pmg-log-tracker.adoc
@@ -0,0 +1,36 @@
+[[chapter_pmg-log-tracker]]
+ifndef::manvolnum[]
+pmg-log-tracker - Backend for the Tracking Center
+=================================================
+:pmg-toplevel:
+endif::manvolnum[]
+
+`pmg-log-tracker` is the backend for the Tracking Center. It parses the syslog
+files in `/var/log/` for mail information. You can specify a different file to
+parse, for example the mail log `/var/log/mail.log`, using the `-i` option.
+
+As an example, parsing the mail.log file for everything between the 1st and 15th
+of July would be possible with the following command:
+----
+pmg-log-tracker -i /var/log/mail.log -s "2021-07-01 00:00:00" -e "2021-07-15 23:59:59"
+----
+
+Start time `-s` and end time `-e` are optional. By default the end time will be
+the current time and the start time will be 0:00 of the current day.
+
+With the `--verbose` option, additional info will be printed, such as the
+complete log for every mail.
+
+It is also possible to filter the log entries based on hostname, from address,
+to address, and other parameters. For a complete overview of all available
+options, see `pmg-log-tracker --help`.
+
+As a side effect of parsing the syslog, which doesn't contain information about
+the year of the entries, the year passed to the `-s` and `-e` options has to
+be the current one, rather than the one in which the logs were actually created.
+
+
+ifdef::manvolnum[]
+include::pmg-copyright.adoc[]
+endif::manvolnum[]
+
-- 
2.30.2





^ permalink raw reply	[flat|nested] 4+ messages in thread

* [pmg-devel] applied: [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info
  2021-08-24  9:33 [pmg-devel] [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info Mira Limbeck
  2021-08-24  9:33 ` [pmg-devel] [PATCH v2 pmg-docs 2/2] add documentation for the pmg-log-tracker Mira Limbeck
@ 2021-09-03 10:54 ` Stoiko Ivanov
  1 sibling, 0 replies; 4+ messages in thread
From: Stoiko Ivanov @ 2021-09-03 10:54 UTC (permalink / raw)
  To: Mira Limbeck; +Cc: pmg-devel

huge thanks for the work and the review

applied

On Tue, 24 Aug 2021 11:33:12 +0200
Mira Limbeck <m.limbeck@proxmox.com> wrote:

> The case of customizing the service and timer files comes up from time
> to time. As we haven't documented it yet, add it to the documentation
> together with a clarification of the `yesterday` timespan parameter.
> 
> Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
> ---
> v2:
>  - reworded based on Dylan's suggestions
> 
>  pmgqm.adoc | 17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
> 
> diff --git a/pmgqm.adoc b/pmgqm.adoc
> index 08ad172..046c91e 100644
> --- a/pmgqm.adoc
> +++ b/pmgqm.adoc
> @@ -27,6 +27,23 @@ endif::manvolnum[]
>  
>  Toolkit to manage spam and virus quarantine, and send spam report mails.
>  
> +The possible timespans are `week`, `yesterday`, and `today`. The default
> +pmgspamreport.service is run at 00:05 every day and calls the `pmgqm` command
> +with the `--timespan yesterday` parameter.
> +This will send a spam report if at least one new spam mail was moved to the
> +quarantine since the beginning of the previous day.
> +
> +The service can be edited, for example, to change the timespan to `today` or
> +`week`, with the following command:
> +----
> +systemctl edit pmgspamreport.service
> +----
> +
> +The timer can be edited with the command below:
> +----
> +systemctl edit pmgspamreport.timer
> +----
> +
>  ifdef::manvolnum[]
>  include::pmg-copyright.adoc[]
>  endif::manvolnum[]





^ permalink raw reply	[flat|nested] 4+ messages in thread

* [pmg-devel] applied: [PATCH v2 pmg-docs 2/2] add documentation for the pmg-log-tracker
  2021-08-24  9:33 ` [pmg-devel] [PATCH v2 pmg-docs 2/2] add documentation for the pmg-log-tracker Mira Limbeck
@ 2021-09-03 10:55   ` Stoiko Ivanov
  0 siblings, 0 replies; 4+ messages in thread
From: Stoiko Ivanov @ 2021-09-03 10:55 UTC (permalink / raw)
  To: Mira Limbeck; +Cc: pmg-devel

huge thanks for the work and the review

applied

On Tue, 24 Aug 2021 11:33:13 +0200
Mira Limbeck <m.limbeck@proxmox.com> wrote:

> The Tracking Center makes assumptions which are working fine for most of
> the users, but not for some.
> It might be useful for some users to know that this exists and is the
> backend for the Tracking Center.
> 
> Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
> ---
> v2:
>  - reworded based on Dylan's suggestions
>  - removed reference to pmg-log-tracker manpage which doesn't yet exist
> 
>  pmg-admin-guide.adoc |  2 ++
>  pmg-log-tracker.adoc | 36 ++++++++++++++++++++++++++++++++++++
>  2 files changed, 38 insertions(+)
>  create mode 100644 pmg-log-tracker.adoc
> 
> diff --git a/pmg-admin-guide.adoc b/pmg-admin-guide.adoc
> index 043b94a..5ca2b0c 100644
> --- a/pmg-admin-guide.adoc
> +++ b/pmg-admin-guide.adoc
> @@ -79,6 +79,8 @@ include::pmgreport.adoc[]
>  
>  include::pmgupgrade.adoc[]
>  
> +include::pmg-log-tracker.adoc[]
> +
>  :leveloffset: 1
>  
>  include::nmap.adoc[]
> diff --git a/pmg-log-tracker.adoc b/pmg-log-tracker.adoc
> new file mode 100644
> index 0000000..3be58a8
> --- /dev/null
> +++ b/pmg-log-tracker.adoc
> @@ -0,0 +1,36 @@
> +[[chapter_pmg-log-tracker]]
> +ifndef::manvolnum[]
> +pmg-log-tracker - Backend for the Tracking Center
> +=================================================
> +:pmg-toplevel:
> +endif::manvolnum[]
> +
> +`pmg-log-tracker` is the backend for the Tracking Center. It parses the syslog
> +files in `/var/log/` for mail information. You can specify a different file to
> +parse, for example the mail log `/var/log/mail.log`, using the `-i` option.
> +
> +As an example, parsing the mail.log file for everything between the 1st and 15th
> +of July would be possible with the following command:
> +----
> +pmg-log-tracker -i /var/log/mail.log -s "2021-07-01 00:00:00" -e "2021-07-15 23:59:59"
> +----
> +
> +Start time `-s` and end time `-e` are optional. By default the end time will be
> +the current time and the start time will be 0:00 of the current day.
> +
> +With the `--verbose` option, additional info will be printed, such as the
> +complete log for every mail.
> +
> +It is also possible to filter the log entries based on hostname, from address,
> +to address, and other parameters. For a complete overview of all available
> +options, see `pmg-log-tracker --help`.
> +
> +As a side effect of parsing the syslog, which doesn't contain information about
> +the year of the entries, the year passed to the `-s` and `-e` options has to
> +be the current one, rather than the one in which the logs were actually created.
> +
> +
> +ifdef::manvolnum[]
> +include::pmg-copyright.adoc[]
> +endif::manvolnum[]
> +





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-09-03 10:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-24  9:33 [pmg-devel] [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info Mira Limbeck
2021-08-24  9:33 ` [pmg-devel] [PATCH v2 pmg-docs 2/2] add documentation for the pmg-log-tracker Mira Limbeck
2021-09-03 10:55   ` [pmg-devel] applied: " Stoiko Ivanov
2021-09-03 10:54 ` [pmg-devel] applied: [PATCH v2 pmg-docs 1/2] add pmgqm timespan and timer/service edit info Stoiko Ivanov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal