Graylog integration returns 500

Steps to reproduce:
Activate Graylog integration and search for logs. The page will show 0 results but will throw a 500 Error in the backend:
[05/Mar/2019:15:30:51 +0100] “POST /ajax/table/graylog HTTP/1.0” 500 34

For verification I made sure with curl that Graylog is returning data and it is :).

If it’s an issue with the WebUI then please consider including a screenshot and the browser version you are using.

validate.php:

Component Version
LibreNMS 1.49-5-gd13d37071
DB Schema 2019_02_10_220000_add_dates_to_fdb (132)
PHP 7.2.15-1+0~20190209065123.16+stretch~1.gbp3ad8c0
MySQL 10.1.37-MariaDB-0+deb9u1
RRDTool 1.6.0
SNMP NET-SNMP 5.7.3

====================================

[OK] Composer Version: 1.8.4
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct

Best

I’m seeing this too:

error: "Server error: `GET http://logs:9000/api/search/universal/relative?query=%2A&limit=25&offset=0` resulted in a `500 Internal Server Error` response:↵{"message":"Unable to perform search query","details":[]}↵"

But also, elasticsearch isn’t running…

Sample data of what Graylog returns:
https://paste.fedoraproject.org/paste/X6sorEMxqdb5wB0fjnrTVg

What do you see in the web console (network tab)?

I am not sure what you mean, can you post a screenshot? :slight_smile:

That request at least looks good.

Mine is a different issue.

Yours is likely something changed with version 3.0.

So the question is now where to start debugging :smiley:?

Calling the Graylog Logs with debug=yes doesn’t show anything obvious unfortunately :/.

So the request to /ajax/table/graylog fails with an error 500.

So, looks like the message does not contain level anymore? Or was it renamed/moved?

As you can see from my example data above it seems neither severity nor level are present anymore.

Does this help?

1 Like

Wohoo this works!

Hello,

I am getting same issue, error 500 when trying to integrate Graylog 3.1
From Network console, it shows as attached image below,

graylog integration network tab

I am running Librenms 1.56-21, should i apply this patch?
Thank you.

That patch was merged into the code 7 months ago. I’m sure you have some other issue and you need to trouble shoot further.

yeah, this could be.
I am still finding a way to make it works.

Your image shows undefined index messages with an S. which seems odd to me, I don’t think anything uses messages with an s…

I looked at the code and it seems like it would only throw that error if the response was malformed, or if maybe the results were empty? I kind of need to see the response from the graylog server to go further.