OPNsense Forum

Archive => 22.1 Legacy Series => Topic started by: GaardenZwerch on January 31, 2022, 02:31:05 PM

Title: [Solved] What can replace clog?
Post by: GaardenZwerch on January 31, 2022, 02:31:05 PM
Hi all,
I wonder what I have at my disposal now that clog is gone? I rely on using clog when debugging things and I use it in nrpe  monitoring scripts as well.
Thanks in advance,
Frank

Title: Re: What can replace clog?
Post by: franco on January 31, 2022, 02:49:04 PM
What sort of scripting do you use around clog?

I did add opnsense-log utility as an "alternative" but mainly for avoiding heavy typing ;)


Cheers,
Franco
Title: Re: What can replace clog?
Post by: GaardenZwerch on January 31, 2022, 03:33:34 PM
Thanks Franco,
opnsense-log is great.
I have one instance where I use an nrpe script to see if ipsec generated TS_UNACCEPT 'recently', and issue 'ipsec restart' in that case. I have a star-shape of IPsec tunnels, and when I make changes in the ipsec config at the hub, satellites generate TS_UNACCEPT errors (no idea why).
But looking around, I have found that ipsec logs can now be found in /var/log/ipsec/latest.log so I can adapt.
For anyone else stumbling across this: a lot of logfiles are now available as sequential files under
/var/log/<servicename>/latest.log

Thanks and regards
Title: Re: [Solved] What can replace clog?
Post by: franco on January 31, 2022, 03:39:48 PM
I would recommend using opnsense-log directly since latest.log link is sort of a volatile link and we might have to fix it up during runtime so that's why opnsense-log exists as a placeholder. Some more discussion on GitHub about this...


Cheers,
Franco
Title: Re: [Solved] What can replace clog?
Post by: GaardenZwerch on January 31, 2022, 04:49:44 PM
Got it,
thanks!