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

too many open files crash #315

Open
zipkr13 opened this issue Mar 8, 2024 · 3 comments
Open

too many open files crash #315

zipkr13 opened this issue Mar 8, 2024 · 3 comments

Comments

@zipkr13
Copy link

zipkr13 commented Mar 8, 2024

Curious if this has been seen before?

Error: tonic::transport::Error(Transport, hyper::Error(Accept, Os { code: 24, kind: Uncategorized, message: "Too many open files" }))

seen on macOS, using cargo installed version of indradb-server using rocksdb

is this rocksdb under the hood crashing?

@ysimonson
Copy link
Member

macos has very low open file limits by default. Either open a rocksdb datastore with a lower open file limit: https://github.com/indradb/indradb/blob/master/lib/src/rdb/datastore.rs#L448

Or increase the open file limit: https://docs.riak.com/riak/kv/latest/using/performance/open-files-limit/index.html#mac-os-x-el-capitan

@zipkr13
Copy link
Author

zipkr13 commented Mar 13, 2024

Gotcha, makes sense. I was using a rocksdb datastore, but still likely seeing it locally due to the open file limit as you mentioned.

It's now running on GCE and I added a restart script, so it is fine, was just curious if indradb was intended to hard crash on such instances

@ysimonson
Copy link
Member

ysimonson commented Mar 14, 2024

It doesn’t have to hard crash, that’s contingent on how you’re doing error handling. To not crash, handle the error without relying on eg unwrap or expect.

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

No branches or pull requests

2 participants