How to get request count or percentage which Target Response Time under specific seconds ?

How to get request count or percentage which Target Response Time under specific seconds ?

Clock Icon2023.05.22 09:10

この記事は公開されてから1年以上経過しています。情報が古い可能性がありますので、ご注意ください。

Introduction

How to get request count or percentage which Target Response Time under specific seconds ? In this blog, I will try to provide a solution of how i was trying to aggregate the data.

How to Achieve it

To get the request count or percentage in this target group which Target Response Time under specific seconds, It may be possible to achieve this by aggregating the Target Response Time in the ALB access log. Please try to acquire the access log and try to aggregate it by using the awk command of Linux. you can use the following Linux command:

sudo cat /var/log/nginx/access.log | awk '($9 < sec) {count++} END {print count}'

※Replace "sec" with the desired response time in seconds.

Conclusion:

By following Linux awk command, you can ensure that is possible to aggregate the data.

この記事をシェアする

facebook logohatena logotwitter logo

© Classmethod, Inc. All rights reserved.