nginxinc/nginx-amplify-agent

Metrics unavailable for connection/requests

loki-screena opened this issue · 0 comments

I had successfully installed and launched the amplify agent on my test server, then I did the same procedure to my production server.
All other metrics are fine, however, the four metrics; connections/s, current connections, requests/s and current requests are unavailable on the production server.

One thing I found suspicious on the production server is "curl http://127.0.0.1/nginx_status" randomly returns 404 errors.

The following is the result of a series of "curl http://127.0.0.1/nginx_status".

ubuntu@ec2:/etc/nginx$ curl http://127.0.0.1/nginx_status
Active connections: 8 
server accepts handled requests
 84625 80297 339196 
Reading: 0 Writing: 8 Waiting: 0 
ubuntu@ec2:/etc/nginx$ curl http://127.0.0.1/nginx_status
Active connections: 8 
server accepts handled requests
 84626 80298 339197 
Reading: 0 Writing: 8 Waiting: 0 
ubuntu@ec2:/etc/nginx$ curl http://127.0.0.1/nginx_status
<html>
<head><title>404 Not Found</title></head>
<body>
<center><h1>404 Not Found</h1></center>
<hr><center>nginx/1.18.0 (Ubuntu)</center>
</body>
</html>
ubuntu@ec2:/etc/nginx$ curl http://127.0.0.1/nginx_status
<html>
<head><title>404 Not Found</title></head>
<body>
<center><h1>404 Not Found</h1></center>
<hr><center>nginx/1.18.0 (Ubuntu)</center>
</body>
</html>
ubuntu@ec2:/etc/nginx$ curl http://127.0.0.1/nginx_status
Active connections: 8 
server accepts handled requests
 84629 80301 339200 
Reading: 0 Writing: 8 Waiting: 0 

The environment is AWS EC2 t3, Ubuntu 20.08, nginx 1.18.0 and amplify agent from https://packages.amplify.nginx.com/py3/ubuntu/

Any help would be greatly appreciated.