-
Notifications
You must be signed in to change notification settings - Fork 381
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
electrs crashes while indexing mainnet with "Too many open files" #133
Comments
@prashb94 size of db is normal, IIRC it can go up to 700+GB before it compacts back down (to 495GB, excluding bitocoind, if we include that total disk requirements, once compacted is around 765GB, but you will need more for the initial run). How much ram do you have on the machine you run this? What OS/distro? |
Thanks! Edit: OS - Ubuntu 16.04.5 LTS (GNU/Linux 4.4.0-1088-aws x86_64) |
@prashb94 I am not too sure but I think this depends on the OS configuration. You may solve the issue by changing /etc/security/limits.conf see romanz/electrs#28 as a similar issue but from romanz/electrs#11 it appears it could also be related to a corrupted bitcoind block file. Are you using any ad-hoc configuration for bitcoindd? Is the storage ssd? Thanks |
Running into same issue, does not seem to be OS config (or maybe I'm missing something?) Trace (with Only non-comment line in Only non-comment lines in
|
Seeing the same problem here. I got an interesting result when I deleted the Upstream electrs is setting the open files limit manually. |
Relevant lines in my logs. I guess the error happened when trying to connect to Bitcoind (port 8332)
|
The issue on my system turned out to be caused by systemd overriding system wide limits with a "sane" default. Was resolved by setting |
Here's how I got around this on the command line: sudo prlimit --nofile=65536 sudo -u "$(id -u)" -g "$(id -g)" cargo blah blah wtv The first sudo makes us root and gives us access to modify file limits, the second sudo brings us back to our original user to execute |
@setpill Excellent, thanks! Running via systemd here. Might be nice to make a note of this in the docs 😉 |
Electrs new-index works fine for testnet but while syncing mainnet, errors out with -
(Truncated log)
Also, the size of
./db
is ~325GB. Is this normal?The text was updated successfully, but these errors were encountered: