Re: fail2ban Squawk

2021-03-27 Thread Sven Hartge
Martin McCormick  wrote:

> I was attempting to setup a systemd timer and checking the syntax of
> that when I ran across a complaint from the fail2ban program which is
> a bit confusing.  It reads:

> /lib/systemd/system/fail2ban.service:12: PIDFile= references path below 
> legacy directory /var/run/, updating /var/run/fail2ban/fail2ban.pid → 
> /run/fail2ban/fail2ban.pid; please update the unit file accordingly.

> So I looked in to that file and the actual line they were
> referring 2 is numbered 15 and points fail2ban.pid to
> /var/run/fail2ban/fail2ban.pid where it certainly lives with a
> recent date.  What is the problem exactly?

As already has been said, there is no problem here. It is just systemd
being a bit too overly chatty and warning about things the package
maintainer would need to address.

You (and I) as mere users should do nothing here.

Of course, you could create an override config file to system and point
the PID file to the path directly under /run to silence the message but
that may create a problem after an upgrade to a newer package version,
for example when a PID file is no longer used but you addition still
points to one.

This is best left alone.

Side note here: In systemd (247.3-2) the Debian maintainers patched
systemd to no longer issue those warnings for unit files provided in
/lib and /usr/lib (i.e. provided by a package) to stop annoying
end-users about issues they can do nothing about.

Grüße,
Sven.

-- 
Sigmentation fault. Core dumped.



Re: fail2ban Squawk

2021-03-26 Thread Linux-Fan

Martin McCormick writes:

/lib/systemd/system/fail2ban.service:12: PIDFile= references path below  
legacy directory /var/run/, updating /var/run/fail2ban/fail2ban.pid →  
/run/fail2ban/fail2ban.pid; please update the unit file accordingly.


So I looked in to that file and the actual line they were
referring 2 is numbered 15 and points fail2ban.pid to
/var/run/fail2ban/fail2ban.pid where it certainly lives with a
recent date.  What is the problem exactly?


I am not sure about the "why" behind all this, but the preference of /run  
over /var/run is documented in the Filesystem Hierarchy Standard:


https://refspecs.linuxfoundation.org/FHS_3.0/fhs/ch03s15.html

On my Debian 10 system, /var/run is a symlink to /run, allowing for  
compatibility with programs using that path.


HTH
Linux-Fan

öö


pgp4nvTHgIVeb.pgp
Description: PGP signature


fail2ban Squawk

2021-03-26 Thread Martin McCormick
I was attempting to setup a systemd timer and checking the syntax
of that when I ran across a complaint from the fail2ban program
which is a bit confusing.  It reads:

/lib/systemd/system/fail2ban.service:12: PIDFile= references path below legacy 
directory /var/run/, updating /var/run/fail2ban/fail2ban.pid → 
/run/fail2ban/fail2ban.pid; please update the unit file accordingly.

So I looked in to that file and the actual line they were
referring 2 is numbered 15 and points fail2ban.pid to
/var/run/fail2ban/fail2ban.pid where it certainly lives with a
recent date.  What is the problem exactly?

Enquiring minds want to know.

Thanks for any and all constructive ideas.

Martin McCormick