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

How to specify the size of this parameter value in lua_shared_dict prometheus-metrics? #11904

Open
shihuncl opened this issue Jan 10, 2025 · 3 comments
Labels
question label for questions asked by users

Comments

@shihuncl
Copy link

Description

Prometheus collects apisix indicator data, and the shared memory of prometheus-metrics is insufficient. The deployment method of apisix is ​​through helm. How do I modify this value?
image

Change the position on the picture to
customLuaSharedDicts:
- name: prometheus-metrics # Lua shared dictionary name
size: 100m #Set the shared dictionary size to 100M.
Is this correct?

Environment

  • APISIX version (run apisix version):3.9
@dosubot dosubot bot added the question label for questions asked by users label Jan 10, 2025
@shihuncl
Copy link
Author

values.yaml文件中添加配置
customLuaSharedDicts:
- name: prometheus-metrics
size: 50m
然后执行helm upgrade apisix-rebuild -n apisix ./apisix-using 命令
如下报错2025/01/10 20:06:58 [emerg] 1#1: the size 52428800 of shared memory zone "prometheus-metrics" conflicts with already declared size 10485760 in /usr/local/apisix/conf/nginx.conf:96
nginx: [emerg] the size 52428800 of shared memory zone "prometheus-metrics" conflicts with already declared size 10485760 in /usr/local/apisix/conf/nginx.conf:96

configMap没有指定prometheus-metrics值的大小,还有哪里指定了呢?我该怎么去修改这个配置的大小?

@wklken
Copy link

wklken commented Jan 14, 2025

the customLuaSharedDicts is for custom plugin only custom_lua_shared_dict

prometheus-metrics is under lua_shared_dict, which can't be configured in the values.yaml currently.

@shihuncl
Copy link
Author

在apisix文件下面nginx配置文件中修改lua_shared_dict的大小,如果是docker部署或者K8S部署的时候项目重启了这个修改好的值又被还原了默认值了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question label for questions asked by users
Projects
Status: 📋 Backlog
Development

No branches or pull requests

2 participants