How to enable Nginx log using log parsing in New Relic

Hi Team,

We have an AKS environment in which we deployed the React.Js & Node.js applications. We are using the Nginx as a loadbalancer. We already monitoring our environment using the Newrelic.
The logs are forwarded to the Newrelic. We planned to format the logs and parsing it which helps to address the issue in quickly manner.
So today we enabled the log parsing in our environment. The pods were created perfectly and listing the data from AKS environment without any issue.
But have no idea where to see the parsing logs. Can you please guide us where to check the parsing logs in Newrelic.

Hi @cloudsupport2, it sounds like this may be caused by how you have your parsing logs set up. I would suggest double checking this documentation for custom parsing logs to make sure you have not missed anything.

Let me know how that goes.

I have a proble. I set type nginx. But newrelic logs does not parse “message” like this
{
“remote_addr”:“93.180.71.3”,
“time”:“1586514731”,
“method”:“GET”,
“path”:"/downloads/product_1",
“version”:“HTTP/1.1”,
“response”:“304”,
“bytesSent”: 0,
“user_agent”: “Debian APT-HTTP/1.3 (0.8.16~exp12ubuntu10.21)”
}

only see
{
“agent”: “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3579.0 Safari/537.36”,
“auth”: “-”,
“bytes”: “4”,
“clientip”: “52.58.190.36”,
“entity.guids”: “…”,
“fb.input”: “tail”,
“filePath”: “/home/deploy/www/httpd-logs/host.access.log”,
“hostname”: “host”,
“httpversion”: “1.1”,
“ident”: “-”,
“logtype”: “nginx”,
“message”: “52.58.190.36 - - [01/Apr/2021:15:34:02 +0000] “GET /ping HTTP/1.1” 200 4 “-” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3579.0 Safari/537.36” “52.58.190.36” “host” sn=“host” rt=0.002 ua=“127.0.0.1:9070” us=“200” ut=“0.000” ul=“4” cs=-”,
“plugin.source”: “BARE-METAL”,
“plugin.type”: “nri-agent”,
“plugin.version”: “1.4.3”,
“referrer”: “-”,
“request”: “/ping”,
“response”: “200”,
“timestamp”: 1617291242961,
“verb”: “GET”
}
may be need addition params for config?

logs:

  • name: ‘nginx-simple-test’
    file: ‘/home/deploy/www/httpd-logs/host.access.log’
    attributes:
    logtype: nginx

fixed. i found. need manual set up grok parsing info to parsing settings in NRL LOGS

2 Likes

@goodpromo could show us how the solution you found was made. I want to send data to the new access_log relic, it was not possible.

Answered in other topic: