OpenBSD too many open files

Hey guys, thought I’d ask this here before opening up an issue in GitHub in case there’s just an OpenBSD default I’m missing. I spun up a copy of Syncthing with the latest release and got these issues when syncing:

 2019-02-24 08:12:52: Listen (BEP/tcp): Accepting connection: accept tcp 0.0.0.0:22000: accept4: too many open files 
  2019-02-24 08:13:28: Error on folder "Server Sync" (): loading ignores: open /home/stratacast/Documents/Syncthing/.stignore: too many open files

2019-02-24 08:13:28: Error on folder "Server Sync" (): loading ignores: open /home/stratacast/Documents/Syncthing/.stignore: too many open files

2019-02-24 08:13:28: Error on folder "Server Sync" (): loading ignores: open /home/stratacast/Documents/Syncthing/.stignore: too many open files

2019-02-24 08:13:28: Error on folder "Server Sync" (): loading ignores: open /home/stratacast/Documents/Syncthing/.stignore: too many open files 

I noticed there are other issues opened but they’re all very old and related to Linux. This is on a fresh install of OpenBSD 6.4 with just a GUI. At some points this completely blocks syncs from happening and a stop and start of the syncthing process resumes the sync but still with these too many connection notices. I saw it could be a low number set for ulimit, so I checked and I got unlimited as my output. I’m still pretty green to the OpenBSD realm so hoping there is maybe a setting in sysctl that I need to set or something or if this really is a syncthing bug on OpenBSD?

Thanks :slight_smile:

There are two types of limits, soft and hard. I suspect you’ve set the wrong one.

I am sure internet will be more helpful on how to answer this, as we don’t have many BSD users to answer your question.

Making some headway. I had to set openfiles-max to 16384 and openfiles-cur to 8192 in the logins.conf file and that SEEMS to have solved that issue. Except now it is saying it’s unable to traverse a directory because it doesn’t exist, yet I look and it’s there. I can also remove the files on the computer it’s syncing with, the files get deleted on OpenBSD, I put them back in, and they sync again. Could not enough file descriptors still cause this issue? Sadly a lot of this hell is caused by dreaded node_modules

Probably not

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.