Missing logs in web proxy (SOLVED)

Started by senseuser, January 29, 2022, 09:32:31 AM

Previous topic - Next topic
January 29, 2022, 09:32:31 AM Last Edit: February 16, 2022, 05:06:37 PM by senseuser
In version 22.1, for some reason, all the logs disappeared. This sign with the inscription "loading" constantly hangs. In version 21.7.7 everything was fine. Something broke? :)

The system log keeps spamming the same error:

2022-01-29T13:15:11 Error   configd.py [46978012-1faf-48bd-bd39-12d8bf5b80ad] Script action failed with Command '/usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity 'Notice'' returned non-zero exit status 1. at Traceback (most recent call last): File "/usr/local/opnsense/service/modules/processhandler.py", line 478, in execute subprocess.check_call(script_command, env=self.config_environment, shell=True, File "/usr/local/lib/python3.8/subprocess.py", line 364, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '/usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity 'Notice'' returned non-zero exit status 1.

The logs are still not showing up. What to do then?  :)

All logs are written to the file normally  /var/log/squid/access.log  But nothing is showing up in the web interface.

can you "clear log" and try again?
in Severity filter try to switch multiselect toggle to 'on' and deselect all options


Yes, I have tried clearing the log. Also tried the "opnsense-patch f530e4f patch". This endless "loading" keeps hanging in the web interface :(


If you upgraded to 22.1.1 and applied the patch you have effectively removed the patch...


Cheers,
Franco

and please, what
/usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity 'Notice'
returns in shell?

the actions were:
1. installed 22.1 - "loading" hangs
2. updated to 22.1.1 - "loading" hangs
3. went to the forum, saw this patch in the answers, applied it - "loading" continues to hang.

SYSTEM: LOG FILES: BACKEND

2022-02-16T19:40:08   Error   configd.py   [bcc01257-1469-43aa-bebd-c5f7f864aafb] Script action failed with Command '/usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity ''' returned non-zero exit status 1. at Traceback (most recent call last): File "/usr/local/opnsense/service/modules/processhandler.py", line 478, in execute subprocess.check_call(script_command, env=self.config_environment, shell=True, File "/usr/local/lib/python3.8/subprocess.py", line 364, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '/usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity ''' returned non-zero exit status 1.

is it possible to execute a command in a shell? what it returns?

/usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity 'Notice'

root@DELL:~ # /usr/local/opnsense/scripts/systemhealth/queryLog.py --limit '20' --offset '0' --filter '' --module 'squid' --filename 'access' --severity 'Notice'
Traceback (most recent call last):
  File "/usr/local/opnsense/scripts/systemhealth/queryLog.py", line 123, in <module>
    record['line'] = frmt.line
  File "/usr/local/opnsense/scripts/systemhealth/logformats/squid.py", line 78, in line
    return line.replace(grp, '')
NameError: name 'line' is not defined
root@DELL:~ #

ah. using extended format?
looks like a little typo in code. try to use standar "file" access log format or please try with
opnsense-patch -a kulikov-a 5a87eaf
will make a pr.

if you decide to switch log format - dont forget to clear logs  ;)