OpenBSD out of memory

Yeah, there’s your “oom”. Maybe also stack / memory / lockedmem depending on what those mean.

1 Like

These are default settings of OpenBSD, I haven’t changed them.

Checked on older version of OpenBSD 5.9, they’re:

time(cpu-seconds)    unlimited
file(blocks)         unlimited
coredump(blocks)     unlimited
data(kbytes)         1572864
stack(kbytes)        4096
lockedmem(kbytes)    1348693
memory(kbytes)       4042912
nofiles(descriptors) 512
processes            256

so there is difference in data field, but still it’s not unlimited or the same size as total memory. I’m not programmer, but shouldn’t syncthing read thosse limitations and work within the ulimit values as they are on all *nix systems?

What do you mean by should? In my opinion it’s anyway nope - if the OS (or the user or whatever else) sets (unreasonable) limits that’s not Syncthing’s problem. And even if we wanted to, that would be super hard, probably impossible to do.

No, Syncthing shouldn’t. If you set limits and those limits are exceeded, a crash is what happens.

OK, it seems I figured out why it was hanging for me now, the ulimit on OpenBSD is:

$ standard user
data(kbytes)         786432

$ group wheel
data(kbytes)         1572864

# root 
data(kbytes)         33554432

So previously I ran it with user, belonging to group wheel, so it couldn’t fill up 1.5GB of space. Now it standard user and consumes or goes over sometimes with 768MB memory space, causing crash with OutOfMemory.

Made -reset-database again, so it rebuilds and resync with all other hosts, hope this time without any crash and completely :slight_smile:

Now I set 4GB of memory for user process: data(kbytes) 4194304

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