> Date: Mon, 15 Jun 2015 19:05:37 +0300 (EEST) > From: Meelis Roos <mr...@linux.ee>
Hi Meelis, > I decided to try OpenBSD-sparc64 on my Sun T2000 (Niagara T1, 32 > threads, 16G RAM). CD install of 5.7 went fine, pkg_add installed git > vim and gcc from official mirro fine. > > Now as a test (to compare oranges to oranges) I tried to check out Linux > kernel git repository but that ran out of memory: > > $ git clone > git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git > Cloning into 'linux'... > remote: Counting objects: 4153047, done. > remote: Compressing objects: 100% (1931/1931), done. > remote: Total 4153047 (delta 1105), reused 0 (delta 0) > Receiving objects: 100% (4153047/4153047), 921.61 MiB | 1.11 MiB/s, done. > fatal: Out of memory, malloc failed (tried to allocate 40960 bytes) > fatal: index-pack failed > > The server had more than 15G RAM available. This command fails on 64M > RAM but works on different 128M-256M machines fine (with Linux). > > ALso tried hackbench from > http://people.redhat.com/mingo/cfs-scheduler/tools/hackbench.c to run > the same benchmark as in Linux and Solaris: > > /hackbench 150 process 1000 > Running with 150*40 (== 6000) tasks. > fork() (error: Resource temporarily unavailable) > > Out of memory in fork() too. > > After that, fork() fail for everything. > > dmesg of a fresh boot is included below (nothing in /var/log/messages). > > Am I missing something about OpenBSD sparc64 memory management? By default OpenBSD has its resource limits set to fairly low values. For example, the max data size (RLIMIT_DATA) is set to 512M and the max number of processes per user (RLIMIT_NPROC) is set to 128. You can raise them with the ulimit shell builtin (see ksh(1)), but there are hard limits that depend on the login class of thew user. The soft limits can be displayed with "ulimit -a", the hard limits with "ulimit -aH". See login.conf(5) for how to change the defaults. The ultimate hard limits compiled into the OpenBSD/sparc64 GENERIC.MP kernel are 8G for the maximum data size and 1054 for the maximum number of processes. Raising the number of processes to be able to run your fork bomb benchmark would require changing the "maxusers" parameter in /usr/src/sys/arch/sparc64/conf/GENERIC and rebuilding your kernel. This is not recommended. Cheers, Mark