ArangoDB Too many open files

secana

since a few days we encounter a problem with our ArangoDB installation. A few minutes/up to an hour after start up all connections to the database are refused. The arango log file says that there are "Too many open files". A "lsof | grep arango | wc -l" shows that the database has around 50,000 open file handles, which is a lot under the max. allowed by the linux system (around 3m). Has anyone an idea where this error comes from?

We are using a Ubuntu Linux with a 3.13 kernel. 30 GB RAM and three cores. The database is still very small with around 1,5m entries and a size of 50GB.

Thx, secana

EDIT: "netstat -anpt | fgrep 2480" shows:

root@syssec-graphdb-001-test:~# netstat -anpt | fgrep 2480
tcp        0      0 10.215.17.193:2480      0.0.0.0:*               LISTEN               7741/arangod
tcp        0      0 10.215.17.193:2480      10.215.50.30:53453      ESTABLISHED          7741/arangod
tcp        0      0 10.215.17.193:2480      10.215.50.31:49299      ESTABLISHED          7741/arangod
tcp        0      0 10.215.17.193:2480      10.215.50.30:53155      ESTABLISHED          7741/arangod

"ulimit -n" has a result of 1024, so I think that the ~50,000 are all arango processes together.

Last lines in log file before the database died:

2015-05-26T12:20:43Z [9672] ERROR cannot open datafile '/data/arangodb/databases/database-235999516/collection-28464454696/datafile-18806474509149.db': 'Too many open files'
2015-05-26T12:20:43Z [9672] ERROR cannot open datafile '/data/arangodb/databases/database-235999516/collection-28464454696/datafile-18806474509149.db': Too many open files
2015-05-26T12:20:43Z [9672] DEBUG [arangod/VocBase/collection.cpp:1632] cannot open '/data/arangodb/databases/database-235999516/collection-28464454696', check failed
2015-05-26T12:20:43Z [9672] ERROR cannot open document collection from path '/data/arangodb/databases/database-235999516/collection-28464454696'
stj

It looks like it will make sense to increase the max. number of open files a process is allowed to manage. Given the stated database size of around 50 GB, the (presumably default) value of 1024 seems to be too low.

arangod will require one file descriptor for each parallel client connection. That may not be many, but in the face of HTTP keep-alive connections this could already account for several file descriptors.

Additionally, each datafile of an active collection will need to be memory-mapped and cost one file descriptor as well. With the default datafile size of 32 MB, a database size of 50 GB (on disk) will already consume 1,600 file descriptors:

50 GB database size / (32 MB default size / 1 datafile) = 1600 datafiles

Increasing the ulimit -n value for the arangod user and environment therefore will make sense. You can confirm that arangod can actually use the configured number of file descriptors by starting it with option --server.descriptors-minimum <value>, e.g.

--server.descriptors-minimum 32768 

for that many file descriptors. If arangod cannot effectively use that specified amount of file descriptors, it will fail at start with a fatal error. Of course that option can also be put into the arangod.conf file.

Additionally, the default size for (new) datafiles can be increased via the journalSize parameter for collections. That won't help right now, but will lower the number of required file descriptors for data saved in the future.

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

Linux system does not allow creation of sockets because of "Too many open files" *even after a reboot*

来自分类Dev

Too many fetch faliuers

来自分类Dev

Entity Framework applying too many migrations

来自分类Dev

MYSQL Too many connections error will not go away

来自分类Dev

Traefik / Portainer-ERR_TOO_MANY_REDIRECTS

来自分类Dev

wordpress:ERR_TOO_MANY_REDIRECTS

来自分类Dev

ERR_TOO_MANY_REDIRECTS - Laravel

来自分类Dev

Argument list too long with just 5000 files

来自分类Dev

Waitbar results in many figures open - MATLAB

来自分类Dev

BluetoothLeAdvertiser AdvertiseCallback引发ADVERTISE_FAILED_TOO_MANY_ADVERTISERS

来自分类Dev

ERR_TOO_MANY_REDIRECTS错误的解决方案

来自分类Dev

Express.js ERR_TOO_MANY_REDIRECTS错误

来自分类Dev

无法加载资源:net :: ERR_TOO_MANY_REDIRECTS

来自分类Dev

PDFjs ERR_TOO_MANY_REDIRECTS请求。Cookies

来自分类Dev

错误:gRPC服务调用中too_many_pings错误

来自分类Dev

春季安全性ERR_TOO_MANY_REDIRECTS

来自分类Dev

无法加载资源jquery ERR_TOO_MANY_REDIRECTS

来自分类Dev

在 HandleUnauthorizedRequest 中获取 err_too_many_redirects

来自分类Dev

添加 SSL 后的 laravel ERR_TOO_MANY_REDIRECTS

来自分类Dev

IIS 在重写规则上得到 ERR_TOO_MANY_REDIRECTS

来自分类Dev

Nginx 和 Cloudflare:err_too_many_redirects

来自分类Dev

如何修复 SoundEffect qml 中的“E libOpenSLES: Too many objects”

来自分类Dev

Unable to Re-Open Files In C, Linux

来自分类Dev

将行添加到安全配置后,ERR_TOO_MANY_REDIRECTS

来自分类Dev

Android Augmented Reality Pro AR 9: activity gets back when displays too many markers

来自分类Dev

Grails-Spring Security REST-302响应网:: ERR_TOO_MANY_REDIRECTS

来自分类Dev

如何在VS Code中启用“ too-many-locals” Pylint消息?

来自分类Dev

如何在VS Code中启用“ too-many-locals” Pylint消息?

来自分类Dev

Google Cloud Platform负载平衡器-ERR_TOO_MANY_REDIRECTS

Related 相关文章

  1. 1

    Linux system does not allow creation of sockets because of "Too many open files" *even after a reboot*

  2. 2

    Too many fetch faliuers

  3. 3

    Entity Framework applying too many migrations

  4. 4

    MYSQL Too many connections error will not go away

  5. 5

    Traefik / Portainer-ERR_TOO_MANY_REDIRECTS

  6. 6

    wordpress:ERR_TOO_MANY_REDIRECTS

  7. 7

    ERR_TOO_MANY_REDIRECTS - Laravel

  8. 8

    Argument list too long with just 5000 files

  9. 9

    Waitbar results in many figures open - MATLAB

  10. 10

    BluetoothLeAdvertiser AdvertiseCallback引发ADVERTISE_FAILED_TOO_MANY_ADVERTISERS

  11. 11

    ERR_TOO_MANY_REDIRECTS错误的解决方案

  12. 12

    Express.js ERR_TOO_MANY_REDIRECTS错误

  13. 13

    无法加载资源:net :: ERR_TOO_MANY_REDIRECTS

  14. 14

    PDFjs ERR_TOO_MANY_REDIRECTS请求。Cookies

  15. 15

    错误:gRPC服务调用中too_many_pings错误

  16. 16

    春季安全性ERR_TOO_MANY_REDIRECTS

  17. 17

    无法加载资源jquery ERR_TOO_MANY_REDIRECTS

  18. 18

    在 HandleUnauthorizedRequest 中获取 err_too_many_redirects

  19. 19

    添加 SSL 后的 laravel ERR_TOO_MANY_REDIRECTS

  20. 20

    IIS 在重写规则上得到 ERR_TOO_MANY_REDIRECTS

  21. 21

    Nginx 和 Cloudflare:err_too_many_redirects

  22. 22

    如何修复 SoundEffect qml 中的“E libOpenSLES: Too many objects”

  23. 23

    Unable to Re-Open Files In C, Linux

  24. 24

    将行添加到安全配置后,ERR_TOO_MANY_REDIRECTS

  25. 25

    Android Augmented Reality Pro AR 9: activity gets back when displays too many markers

  26. 26

    Grails-Spring Security REST-302响应网:: ERR_TOO_MANY_REDIRECTS

  27. 27

    如何在VS Code中启用“ too-many-locals” Pylint消息?

  28. 28

    如何在VS Code中启用“ too-many-locals” Pylint消息?

  29. 29

    Google Cloud Platform负载平衡器-ERR_TOO_MANY_REDIRECTS

热门标签

归档