Ubuntu Error to many open files, when run a node

Solution

For those of you with gaiad crashing on the too many open files error, here’s a short guide to fix it

check your user’s per-process open file limit

ulimit -Sn

check how many files gaiad has open

ls /proc/(pidof gaiad)/fd/ | wc -l

increase username’s per process limit

sudo vi /etc/security/limits.conf
username soft nofile 2048

From @peng and @zmanian in riot

3 Likes

Also a solution in the Docs
https://cosmos.network/docs/validators/validator-setup.html#problem-2-my-gaiad-crashes-because-of-too-many-open-files