Buffer allocation failed

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hey,

I know that the buffer allocation uses some memory mapping tricks to
make it efficient; is there some shared resource that this process
uses of which a computer should have a finite amount? I’m running a
process with, oh, say 500 buffers (estimate) or so and once I get past
7 parallel instances running I get std::bad_alloc errors allocating
the buffers. Each process used only about 32m of virtual memory…

Is this expected?

Thanks,

Dan
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkgkcOsACgkQy9GYuuMoUJ68fACffFAUFQCNeUCWTTXe82fwGK7p
FEMAnjRVIiEL/wZWXf5SCkgMafjirKOW
=Ygfm
-----END PGP SIGNATURE-----

On Fri, May 09, 2008 at 08:42:35AM -0700, Dan H. wrote:

Thanks,
Dan

Depending on which of the vmcircbuf tricks it’s using it runs into a
different system limit. By default on Linux it’s usually using
gr_vmcircbuf_sysv_shm_factory. You can check this by cat’ing
~/.gnuradio/.prefs/gr_vmcircbuf_default_factory.

You’re probably running into a limit on the total number of shared
memory segments in the system (SHMMNI) or the max segs per process
(SHMMSEG). You can check the current values by:

$ cat /sys/proc/kernel/shmmni

You can set the value one time using

$ cat 4096 >/sys/proc/kernel/shmni

or arrange to have it always set by editing /etc/sysctl.conf

Eric

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On May 9, 2008, at 9:21 AM, Eric B. wrote:

or arrange to have it always set by editing /etc/sysctl.conf
Yeah, that must be it. (I don’t have root on the cluster but once I
get support to change it I’ll see if that works.)

Just FYI, I found the file at /proc/sys/kernel not /sys/proc/kernel.
And presumably it’s echo 4096>shmmni not cat 4096>shmmni ?

Thanks!

Dan
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkgkfL0ACgkQy9GYuuMoUJ7PAQCfesQyL03uj7TBXGVae2IT+gXx
kH8AnAuSz/qwF9VkVgN3Pkpljr/pae2Q
=wWJQ
-----END PGP SIGNATURE-----

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs