Xymon Mailing List Archive search

4.4alpha1: MACHINE setting

1 message in this thread

list Roland Rosenfeld · Mon, 20 May 2024 17:04:30 +0200 ·
Hi!

I'm just working on packaging 4.4 Alpha1 for Debian (see experimental
branch of https://salsa.debian.org/debian/xymon for more information).

Doing so I had some trouble (change of behavior) with the setting of
MACHINE when using a FQDN as hostname in xymon.

If the system hostname (from /proc/sys/kernel/hostname used via uname
call) contains any dots, these are not converted to commas, since
commafy() returns a string with dots replaced by commas (while
uncommafy() does return void and does the replacement directly in the
given parameter).
The attached 102_commafy_MACHINE.patch fixes this issue.

If I try to set MACHINEDOTS somewhere in xymonserver.cfg, MACHINE
needs to manually be set in relation to this replacing dots by
commas.  This isn't very handy but error prone, so I created
103_MACHINEDOTS2MACHINE.patch, which automatically sets MACHINE when
MACHINEDOTS is set with dots replaced by commas.  I'm not very good in
coding C, so there may be better ways to implement this, but from my
point of view such an automatism should be a good idea...

Greetings
Roland
Attachments (2)