3.2.3.5 Web Server Processing Statistics Query

Only applicable to MetaDefender Core version 4.19.0 or above.

Configure Nginx web server

1.) Create a “status.conf” file

  • On Windows, under <Installation Directory>\nginx\

  • On Linux, under /etc/ometascan/nginx.d/

server {
listen 8088 ; listen [::]:8088 ;
location = /nginx_status {
stub_status;
}
}

2.) A restart of the “OPSWAT Metadefender Core” service is required.

Query Nginx processing stats infomation

Property

Value

DESCRIPTION

Query Nginx processing stats information

URL

http://<server>:<port>/nginx_status

HTTP METHOD

GET

Response

Result code

Value

Description

200

Active connections: <n>
server accepts handled requests
<a1> <a2> <a3>
Reading: <b1> Writing: <b2> Waiting: <b3>

For example:

Active connections: 1
server accepts handled requests
144 144 358
Reading: 0 Writing: 1 Waiting: 0

Request processed successfully.

  • Active connections <n>

The current number of active client connections including Waiting <b3> connections.

  • accepts <a1>

The total number of accepted client connections.

  • handled <a2>

The total number of handled connections. Generally, the parameter value is the same as accepts <a1> unless some resource limits have been reached (for example, the worker_connections limit).

  • requests <a3>

The total number of client requests.

  • Reading <b1>

The current number of connections where nginx is reading the request header.

  • Writing <b2>

The current number of connections where nginx is writing the response back to the client.

  • Waiting <b3>

The current number of idle client connections waiting for a request.