* collectd openvpn errors if openvpn not used
@ 2025-03-15 13:49 Adolf Belka
2025-03-15 14:13 ` Michael Tremer
0 siblings, 1 reply; 2+ messages in thread
From: Adolf Belka @ 2025-03-15 13:49 UTC (permalink / raw)
To: IPFire: Development-List
[-- Attachment #1: Type: text/plain, Size: 2833 bytes --]
Hi Michael and all,
Error messages from collectd have been reported in the forum with Core
Update 192 (so the 15.12.0 update).
The messages were:-
|07:19:24 collectd[17386]: read-function of plugin
`openvpn/ovpnserver.log' failed. Will suspend it for 30720.000 seconds.
07:19:24 collectd[17386]: openvpn plugin: failed to get data from:
/var/run/ovpnserver.log 03:03:24 collectd[17386]: read-function of
plugin `openvpn/ovpnserver.log' failed. Will suspend it for 15360.000
seconds. 03:03:24 collectd[17386]: openvpn plugin: failed to get data
from: /var/run/ovpnserver.log 00:55:24 collectd[17386]: read-function of
plugin `openvpn/ovpnserver.log' failed. Will suspend it for 7680.000
seconds. 00:55:24 collectd[17386]: openvpn plugin: failed to get data
from: /var/run/ovpnserver.log |
||It appears that the users that are not using openvpn are the ones
seeing these messages. They apparently do have the
/var/run/ovpnserver.log file but it is empty.
Looking back through the IPFIre git repo I saw that some of the 22 odd
patches that had been applied to collectd-4.10.9 were related to openvpn
and some of them to silencing openvpn errors.
I identified 7 patches related to openvpn, all patching the
/src/openvpn.c file in the collectd source tarball.
I compared all these patches with the collectd-5.12.0 source tarball.
One of the files had its contents now included in the source tarball.
This was the one related to changing the openvpn plugin from a COUNTER
to a DERIVE approach.
The other 6 patches I could not find virtually any match as the
openvpn.c code is significantly different enough that finding the
section of code where the changes should be applied was impossible. In
many cases the variables being changes are no longer present, or if
present are used in very different commands now.
Any thoughts on how to fix this. Do we need to basically completely
re-write the old patches to be able to work in the new code or is there
some way to be able to detect that openvpn is not running and therefore
comment out the include openvpn plugin command in the collectd.conf file
in the same way as we do with the thermal plugin.
The issue I see with this is that the thermal line is commented out via
the collectd initscript, presumably because if this is not capable at
boot it won't change while the system is running.
However with openvpn the user could enable openvpn to start and then we
would need to make the collectd daemon restart so that the initscript
could uncomment the include openvpn plugin line.
Editing the openvpn.c code is beyond my capabilities but the second
option to uncomment the openvpn plugin line if openvpn is started might
be in my capabilities.
Any thoughts or other suggestions on this issue.
Regards,
Adolf.
||
||
||
--
Sent from my laptop
[-- Attachment #2: Type: text/html, Size: 4104 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: collectd openvpn errors if openvpn not used
2025-03-15 13:49 collectd openvpn errors if openvpn not used Adolf Belka
@ 2025-03-15 14:13 ` Michael Tremer
0 siblings, 0 replies; 2+ messages in thread
From: Michael Tremer @ 2025-03-15 14:13 UTC (permalink / raw)
To: Adolf Belka; +Cc: IPFire: Development-List
Hello Adolf,
I think we should comment out the OpenVPN module in collectd.conf. We are doing this for some other modules already:
https://git.ipfire.org/?p=ipfire-2.x.git;a=blob;f=src/initscripts/system/collectd;h=263511fc7c1fd5bf5450f11558ac6bce0e167828;hb=HEAD
This just means that we also want to restart collectd after OpenVPN was enabled/disabled so that it is always in sync.
-Michael
> On 15 Mar 2025, at 13:49, Adolf Belka <adolf.belka@ipfire.org> wrote:
>
> Hi Michael and all,
>
> Error messages from collectd have been reported in the forum with Core Update 192 (so the 15.12.0 update).
>
> The messages were:-
>
> 07:19:24 collectd[17386]: read-function of plugin `openvpn/ovpnserver.log' failed. Will suspend it for 30720.000 seconds.
> 07:19:24 collectd[17386]: openvpn plugin: failed to get data from: /var/run/ovpnserver.log
> 03:03:24 collectd[17386]: read-function of plugin `openvpn/ovpnserver.log' failed. Will suspend it for 15360.000 seconds.
> 03:03:24 collectd[17386]: openvpn plugin: failed to get data from: /var/run/ovpnserver.log
> 00:55:24 collectd[17386]: read-function of plugin `openvpn/ovpnserver.log' failed. Will suspend it for 7680.000 seconds.
> 00:55:24 collectd[17386]: openvpn plugin: failed to get data from: /var/run/ovpnserver.log
>
> It appears that the users that are not using openvpn are the ones seeing these messages. They apparently do have the /var/run/ovpnserver.log file but it is empty.
>
> Looking back through the IPFIre git repo I saw that some of the 22 odd patches that had been applied to collectd-4.10.9 were related to openvpn and some of them to silencing openvpn errors.
>
> I identified 7 patches related to openvpn, all patching the /src/openvpn.c file in the collectd source tarball.
>
> I compared all these patches with the collectd-5.12.0 source tarball.
>
> One of the files had its contents now included in the source tarball. This was the one related to changing the openvpn plugin from a COUNTER to a DERIVE approach.
>
> The other 6 patches I could not find virtually any match as the openvpn.c code is significantly different enough that finding the section of code where the changes should be applied was impossible. In many cases the variables being changes are no longer present, or if present are used in very different commands now.
>
> Any thoughts on how to fix this. Do we need to basically completely re-write the old patches to be able to work in the new code or is there some way to be able to detect that openvpn is not running and therefore comment out the include openvpn plugin command in the collectd.conf file in the same way as we do with the thermal plugin.
>
> The issue I see with this is that the thermal line is commented out via the collectd initscript, presumably because if this is not capable at boot it won't change while the system is running.
>
> However with openvpn the user could enable openvpn to start and then we would need to make the collectd daemon restart so that the initscript could uncomment the include openvpn plugin line.
>
> Editing the openvpn.c code is beyond my capabilities but the second option to uncomment the openvpn plugin line if openvpn is started might be in my capabilities.
>
> Any thoughts or other suggestions on this issue.
>
> Regards,
> Adolf.
>
>
>
> --
> Sent from my laptop
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-03-15 14:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-15 13:49 collectd openvpn errors if openvpn not used Adolf Belka
2025-03-15 14:13 ` Michael Tremer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox