For the complete documentation index, see llms.txt. This page is also available as Markdown.

Nginx 및 ALB 액세스 로그 쿼리

모든 Nginx 및 ALB 로그에서 UserAgent 문자열 순위를 매깁니다

이 쿼리는 ALB 및 Nginx 로그에서 UserAgent별 활동을 특성화합니다. 행위자가 알려진 특징적인 UserAgent 집합을 가지고 있다면 조사에 유용할 수 있습니다.

SELECT
 useragent,
 sum(row_count) AS total_rows
FROM (

SELECT
 useragent,
 count(1) AS row_count
FROM panther_logs.public.aws_alb
WHERE p_occurs_between('2021-01-01', '2021-01-02')
GROUP BY useragent

UNION ALL

SELECT
 httpuseragent AS useragent,
 count(1) AS row_count
FROM panther_logs.public.nginx_access
WHERE p_occurs_between('2021-01-01', '2021-01-02')
GROUP BY httpuseragent
)
GROUP BY useragent
ORDER BY total_rows DESC

마지막 업데이트

도움이 되었나요?