turbot/tailpipe-mod-nginx-access-log-detections

Query: Top 10 URLs (Errors)

Description

List the top 10 requested URLs by error count.

Usage

powerpipe query nginx_access_log_detections.query.activity_dashboard_requests_by_errors

Tailpipe Tables

SQL

select
request_uri as "Path",
count(*) as "Error Count",
string_agg(distinct status::text, ', ' order by status::text) as "Status Codes"
from
nginx_access_log
where
status between 400 and 599
and request_uri is not null
group by
request_uri
order by
count(*) desc,
request_uri
limit 10;

Dashboards

The query is used in the dashboards: