Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicate metrics #200

Open
dolgovas opened this issue May 19, 2021 · 2 comments
Open

Duplicate metrics #200

dolgovas opened this issue May 19, 2021 · 2 comments
Labels

Comments

@dolgovas
Copy link

Hello! We have some trouble with calculate global traffic...

nginx -V
nginx version: nginx/1.19.10
built by gcc 4.8.5 20150623 (Red Hat 4.8.5-44) (GCC)
built with OpenSSL 1.1.1k  25 Mar 2021
TLS SNI support enabled
configure arguments: --prefix=/etc/nginx --sbin-path=/usr/sbin/nginx --modules-path=/usr/lib64/nginx/modules --conf-path=/etc/nginx/nginx.conf --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --pid-path=/var/run/nginx.pid --lock-path=/var/run/nginx.lock --http-client-body-temp-path=/var/cache/nginx/client_temp --http-proxy-temp-path=/var/cache/nginx/proxy_temp --http-fastcgi-temp-path=/var/cache/nginx/fastcgi_temp --http-uwsgi-temp-path=/var/cache/nginx/uwsgi_temp --http-scgi-temp-path=/var/cache/nginx/scgi_temp --user=nginx --group=nginx --with-compat --with-file-aio --with-threads --with-http_addition_module --with-http_auth_request_module --with-http_dav_module --with-http_flv_module --with-http_gunzip_module --with-http_gzip_static_module --with-http_mp4_module --with-http_random_index_module --with-http_realip_module --with-http_secure_link_module --with-http_slice_module --with-http_ssl_module --with-http_stub_status_module --with-http_sub_module --with-http_v2_module --with-mail --with-mail_ssl_module --with-stream --with-stream_realip_module --with-stream_ssl_module --with-stream_ssl_preread_module --with-cc-opt='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -fPIC' --add-module=/home/builder/rpm/SOURCES/ngx_brotli --with-openssl=/home/builder/rpm/SOURCES/openssl-1.1.1k --with-openssl-opt=enable-tls1_3 --add-module=/home/builder/rpm/SOURCES/ngx_devel_kit --add-module=/home/builder/rpm/SOURCES/ngx_http_geoip2_module --add-module=/home/builder/rpm/SOURCES/nginx-module-vts --add-module=/home/builder/rpm/SOURCES/nginx_upstream_check_module --add-module=/home/builder/rpm/SOURCES/testcookie-nginx-module --with-ld-opt='-Wl,-z,relro -Wl,-z,now -pie'
curl -s http://127.0.0.1:9913/metrics|grep 'nginx_vts_server_bytes_total{host="\*",direction="out"}'
nginx_vts_server_bytes_total{host="*",direction="out"} 0
nginx_vts_server_bytes_total{host="*",direction="out"} 68301879715485

I thought that we have multi master nginx...but not. Only one

# ps aux|grep nginx|grep master
root     13918  0.0  0.3 3627564 451656 ?      Ss   Apr17   3:59 nginx: master process /usr/sbin/nginx -c /etc/nginx/nginx.conf

after restart nginx everything is ok...but it's return after few days

@vozlt vozlt added the bug label Sep 4, 2022
@u5surf
Copy link
Collaborator

u5surf commented Sep 21, 2022

Hi, @dolgovas
We're sorry for the late response. I'm a new collaborator on this module.
So I'd like to work on this issue which active for a long time.

Can you answer a several questions for obtaining some cues about this issue?

  1. Can you check your module version?
    It can be found on your metrics response(json/prometheus) if you use the recent module like this.
# HELP nginx_vts_info Nginx info
# TYPE nginx_vts_info gauge
nginx_vts_info{hostname="foobar",module_version="v0.2.1",version="1.23.1"} 1
  1. Is there any nginx.conf which it can be reproduced?
    We prefer to minimize it excluding your own business logics or nonrelated feature as possible.
  2. Does it still reproduce the latest module?
    If you can check the latest version, please confirm to reproduce.

@dolgovas
Copy link
Author

Hello! Thank you for your answer.
Here is module version that we are using now

module_version="0.1.19.dev.91bdb14", version="1.23.1

We meet that bug no so often...

When it comes again, I'll sent you some detailed info

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants