Shared Memory Problem

Hi,

I have a problem with insufficent shared memory. I’m running GNU Radio
from SVN, and keep getting these messages:

gr_vmcircbuf_sysv_shm: shmget (1): No space left on device
gr_buffer::allocate_buffer: failed to allocate buffer of size 32 KB
terminate called after throwing an instance of ‘std::bad_alloc’
what(): St9bad_alloc
Avbrutt (SIGABRT)

I’ve tried increasing the maximum size of shared mem blocks with this
command:
sysctl -w kernel.shmmax=2147483648

I’ve attached the block that causes these problems (it will not work
if you try it, because some additional modules are missing). Any hints
on how to solve this?

2007/4/12, Greg T. [email protected]:

http://gnuradio.org/trac/wiki/NetBSDInstall
Ah, forgot to mention that :). I’ve tested on both Fedora Rawhide
(development) on my i386 laptop with 512 MB ram, and on Fedora Core 6
x86_64 that runs on an AMD 64 with 1 GB ram.


Trond D.

I have a problem with insufficent shared memory. I’m running GNU Radio
from SVN, and keep getting these messages:

You didn’t mention what operating system you are running, but it could
well be that you are hitting a limit on the number of segments rather
than the total size.

See the end of this page for setting shm limits to get the tests to
pass:

http://gnuradio.org/trac/wiki/NetBSDInstall

On Thu, Apr 12, 2007 at 02:50:17PM +0200, Trond D. wrote:

I’ve tried increasing the maximum size of shared mem blocks with this
command:
sysctl -w kernel.shmmax=2147483648

I’ve attached the block that causes these problems (it will not work
if you try it, because some additional modules are missing). Any hints
on how to solve this?

As Greg mentioned, this error is from shmget, and indicates
that there are not enough shared memory segments available.

Looks like kernel.shmmni may be the parameter that needs tweaking.
It’s 4096 on my machines.

BTW, I like your use of lambda expressions below:

    d( "s2v_input",
        gr.stream_to_vector(gr.sizeof_gr_complex, self.fft_size))
    d( "fft_input",
        gr.fft_vcc(self.fft_size, True, self.window))

Eric

2007/4/12, Eric B. [email protected]:

Avbrutt (SIGABRT)
that there are not enough shared memory segments available.

Looks like kernel.shmmni may be the parameter that needs tweaking.
It’s 4096 on my machines.

Thanks for the answers! kernel.shmmni is the same as on my machines,
so I doubt that it is the problem . But I have already solved the
problem; Johnathan pointed me to the single pole IIR filter that
solved my problem in a much better way than the solution that I came
up with. Apparently GNU Radio does not like 2000 simultaneous branches
in a single block…

BTW, I like your use of lambda expressions below:

Saves a lot of typing :slight_smile:

    # Input signal; get Fourier transform of signal.
    d( "s2v_input",
        gr.stream_to_vector(gr.sizeof_gr_complex, self.fft_size))
    d( "fft_input",
        gr.fft_vcc(self.fft_size, True, self.window))

Eric


Trond D.

Trond D. wrote:

BTW, I like your use of lambda expressions below:

Saves a lot of typing :slight_smile:

Too bad they won’t be necessary soon :slight_smile:

The hier_block2 stuff is undergoing major surgery and won’t be using the
‘define_component, connect’ techniques anymore, it will instead look
very much like how the gr.flow_graph() stuff works today. I’ll send a
note out to the list when this done, but before I merge into the trunk.
Since this is all unannounced and undocumented, I expect only a few
developers to be impacted.


Johnathan C.
Corgan Enterprises LLC
http://corganenterprises.com