bugGNU Octave - Bugs: bug #57182, [octave forge] (signal) decimate...

 
 

bug #57182: [octave forge] (signal) decimate causes octave to be killed

Submitted by:  Chris Gorman <chrisgorman>
Submitted on:  Wed 06 Nov 2019 09:48:08 PM UTC  
 
Category:  Octave Forge Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Segfault, Bus Error, etc.
Status:  Invalid Assigned to:  None
Originator Name:  Chris Gorman Open/Closed:  Closed
Release:  5.1.0 Operating System:  GNU/Linux

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 07 Nov 2019 12:55:40 AM UTC, comment #5: 

You have found the problem.  Thanks.  Please close the bug as it is being killed by the kernel.

Nov  6 19:51:45 lie kernel: [41614.941934] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=octave-gui,pid=4205,uid=1000
Nov  6 19:51:45 lie kernel: [41614.941964] Out of memory: Killed process 4205 (octave-gui) total-vm:4954344kB, anon-rss:622192kB, file-rss:0kB, shmem-rss:0kB
Nov  6 19:51:45 lie kernel: [41615.387388] oom_reaper: reaped process 4205 (octave-gui), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB

Chris

Chris Gorman <chrisgorman>
Thu 07 Nov 2019 12:45:17 AM UTC, comment #4: 

Thanks. Octave does not send itself SIGKILL, so the kernel or another system process is more likely.

Assuming this is a true Linux kernel running on the chromebook, I would suspect the 'oom_kill_process' function. Look in the kernel logs for "out of memory" or "oom killer". Given that Octave is receiving SIGKILL on one particular system that may not have swap, and only when working with GB of data, the Linux oom killer looks like a very likely cause.

Mike Miller <mtmiller>
Project Administrator
Thu 07 Nov 2019 12:36:08 AM UTC, comment #3: 

I have found how to build a debug version of octave and am building it at the moment.  Will have more to say tomorrow.

Chris

Chris Gorman <chrisgorman>
Thu 07 Nov 2019 12:01:08 AM UTC, comment #2: 

Hi Mike,

The exact problem is that octave exits after running the commands.

pkg load signal
y = rand (1, 1e8);
d = decimate (y, 8, 'fir');

I have not been able to reproduce this error on another machine, I only have one other one and it works properly on it.

The following is a strace output. 

octave:1> pkg load signal
octave:2> y = rand (1, 1e8);
octave:3> d = decimate (y, 8, 'fir');
) = 0 (Timeout)
recvmsg(6, {msg_namelen=0}, 0)          = -1 EAGAIN (Resource temporarily unavailable)
recvmsg(6, {msg_namelen=0}, 0)          = -1 EAGAIN (Resource temporarily unavailable)
recvmsg(6, {msg_namelen=0}, 0)          = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=5, events=POLLIN}, {fd=6, events=POLLIN}, {fd=7, events=POLLIN}, {fd=12, events=POLLIN}], 4, -1 <unfinished ...>) = ?
+++ killed by SIGKILL +++
Killed

Under gdb I get the following.

chris@lie:~$ gdb octave
GNU gdb (Ubuntu 8.1-0ubuntu3.1) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from octave...done.
(gdb) run
Starting program: /usr/local/bin/octave
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
process 17466 is executing new program: /usr/local/libexec/octave/5.1.0/exec/x86_64-pc-linux-gnu/octave-gui

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffde861700 (LWP 17477)]
[New Thread 0x7fffd6fb8700 (LWP 17478)]
[New Thread 0x7fffccc76700 (LWP 17479)]
[New Thread 0x7fffc7fff700 (LWP 17480)]
[New Thread 0x7fffc77fe700 (LWP 17481)]
[New Thread 0x7fffc6ffd700 (LWP 17482)]
[New Thread 0x7fffc67fc700 (LWP 17483)]
GNU Octave, version 5.1.0
Copyright (C) 2019 John W. Eaton and others.
This is free software; see the source code for copying conditions.
There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  For details, type 'warranty'.

Octave was configured for "x86_64-pc-linux-gnu".

Additional information about Octave is available at https://www.octave.org.

Please contribute if you find this software useful.
For more information, visit https://www.octave.org/get-involved.html

Read https://www.octave.org/bugs.html to learn how to submit bug reports.
For information about changes from previous versions, type 'news'.

graphics_toolkit = qt
octave:1>
octave:1> y = rand (1, 1e8);
octave:2> pkg load signal
octave:3> d = decimate (y, 8, 'fir');
[New Thread 0x7fffc5ffb700 (LWP 17486)]
[Thread 0x7fffc5ffb700 (LWP 17486) exited]
[Thread 0x7fffc67fc700 (LWP 17483) exited]
[Thread 0x7fffc6ffd700 (LWP 17482) exited]
[Thread 0x7fffc7fff700 (LWP 17480) exited]
[Thread 0x7fffccc76700 (LWP 17479) exited]
[Thread 0x7fffd6fb8700 (LWP 17478) exited]
[Thread 0x7fffde861700 (LWP 17477) exited]
[Thread 0x7ffff7f8e900 (LWP 17466) exited]

Program terminated with signal SIGKILL, Killed.
The program no longer exists.
(gdb)

I have not sent a sigkill signal to the program myself.  This is being done by the os or octave itself.

Chris Gorman <chrisgorman>
Wed 06 Nov 2019 10:05:41 PM UTC, comment #1: 

This example works for me on my system

y = rand (1, 1e8);
d = decimate (y, 8, 'fir');

Is there any example that reproduces this error for you on a system that is not a chromebook?

What is the exact error? Is Octave killed by the operating system, perhaps because of a memory usage limitation? Or does Octave exit with an error or a fatal signal? Are you able to share a call stack trace at the location where Octave is killed?

Mike Miller <mtmiller>
Project Administrator
Wed 06 Nov 2019 09:48:08 PM UTC, original submission:  

On my laptop which is a galliumos linux chromebook the following occurs when trying to decimate a radio signal.  This occurs with octave 4.4.1, 5.1.0 and 6.0.0.  The chromebook is essentially ubuntu 18.04. 

octave:4> cd src/octave-gnuradio/
octave:5> y = loadFile('../sdr/dat/FMcapture1.dat');
octave:6> pkg load signal
octave:7> d = decimate(y,8,'fir');
Killed

When I try this set of commands on my desktop machine which is a mac mini with ubuntu 18.04, under octave 6.0.0, the decimate command works without a problem.  I'm not sure what the issue is exactly.  (The kernels are different 5.3.0 on the laptop vs 5.2.0 on the mac mini.)

When I try to decimate a smaller amount of data, things work properly and octave stays open.

octave:4> y = rand(1,100);
octave:5> d = decimate(y,8,'fir');

With the decimating array smaller than 12500001 the call succeeds with the array larger than 18750001 the call causes octave to be killed.  I'm not sure where the exact threshold is for success or failure, but can write a small script to determine the exact number of elements decimate can process, if that is important.

Thanks

Chris

Chris Gorman <chrisgorman>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by chrisgorman (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-11-07 mtmiller StatusNeed Info => Invalid
        Open/ClosedOpen => Closed
    2019-11-06 mtmiller StatusNone => Need Info
        Summarysignal function decimate causes octave to be killed => [octave forge] (signal) decimate causes octave to be killed

    Back to the top


    Powered by Savane 3.5