Bug 562276

Summary: octave segfaults on a startup from qtoctave
Product: [Fedora] Fedora Reporter: Michal Jaegermann <michal>
Component: octave-forgeAssignee: Alex Lancaster <alexl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 13CC: alexl, b.durai, bizizale, dasergatskov, dbpatankar, flama.es, JimShip, kevin, kruvalig, mmahut, msava, mschmidt, mvanross, neeeene, orion, QFanatic, rpandit, scottagold, susi.lehtola, zeekec
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: octave-forge-20090607-17.fc13 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-07-13 07:44:15 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
gdb backtrace from an octave segfault
none
octave-core file produced in this bomb none

Description Michal Jaegermann 2010-02-05 19:43:50 UTC
Created attachment 389175 [details]
gdb backtrace from an octave segfault

Description of problem:

After starting qtoctave various windows open an the followin output shows up:

warning: mark_as_command is obsolete and will be removed from a future version 
of Octave
>>>panic: Segmentation fault -- stopping myself...
attempting to save variables to `octave-core'...
save to `octave-core' complete

After the above octave is restarted and this time it pretends that nothing really happened.

A backtrace with octave-debug loaded from a core generated by the above is attached.  

Version-Release number of selected component (if applicable):
octave-3.2.3-1.fc11.x86_64
qtoctave-0.8.2-2.fc11.x86_64

How reproducible:
every time when qtoctave starts

Expected results:
Not a segfault - regardless of any weird things qtoctave is possibly doing.

Additional info:
I did not try qtoctave before so I cannot tell if this is something new or not.

Comment 1 Michal Jaegermann 2010-02-05 19:47:25 UTC
Created attachment 389177 [details]
octave-core file produced in this bomb

Comment 2 Alex Lancaster 2010-02-08 23:55:13 UTC
With the following packages on F-12:

# rpm -q octave qtoctave
octave-3.2.3-4.fc12.x86_64
qtoctave-0.8.2-2.fc12.x86_64

I get "warning: mark_as_command is obsolete and will be removed from a future version of Octave" in the window but no segfault.

I will try to reproduce on F-11.   It's possible that this is an issue with the older version of octave on F-11, there were some changes in the package that fixed certain issues on F-12.  Can you reproduce this with the command-line version of octave only (i.e. without using qtoctave)?

Comment 3 Michal Jaegermann 2010-02-09 01:54:14 UTC
(In reply to comment #2)
> Can you reproduce this with the command-line
> version of octave only (i.e. without using qtoctave)?

No, I cannot.  OTOH qtoctave is not running just "octave".  As a backtrace makes clear this comes from:

  Core was generated by `octave --eval PS1('octave:\#>');PS2('octave:\#+>');addpath('/usr/share/qtoctave'.

It looks like that an octave startup command was shortened here (to a width of a buffer or something like that) and it appears that this "eval" is what really is causing problems.

Trying on a command line just

   octave --eval "PS1('octave:\#>');PS2('octave:\#+>');"

simply prints an introductory information, "warning: mark_as_command is obsolete ..." and exits.

Like I already mentioned - after this segfault qtoctave restarts octave and continues.  No idea what startup is used on that retry.

Quite possibly the real error is burried in

  File "/usr/lib64/python2.6/encodings/utf_8.py", line 16, in decode
    return codecs.utf_8_decode(input, errors, True)
UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: invalid data
, idx=std::list = {...}, nargout=-1581871475) at ov.cc:1061

which you can find in a backtrace.  Maybe data are really invalid or maybe
'nargout' value is shot on 64 bits?  It does not look healthy but this may be an illusion.

Comment 4 Bug Zapper 2010-04-28 11:48:10 UTC
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '11'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 11's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 11 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 5 QFanatic 2010-05-07 23:32:47 UTC
I've experienced this bug a number of times under Fedora 12.  It seems related to the variables saved on closure of QtOctave.  I attempted to load the variables saved by QtOctave using vanilla console Octave and encountered the same segmentation fault.This may be why the new save of variables to octave core on fault allows QtOctave to recover.This fault does not occur every time QtOctave starts up under Fedora 12, though the size of the variables files seems to affect the likelihood of experiencing the fault.

Comment 6 Michal Jaegermann 2010-05-08 02:30:43 UTC
(In reply to comment #5)
> I've experienced this bug a number of times under Fedora 12.

In that case beside a comment you should bump a "Version" or this will be automatically closed pretty soon as bug in an unmaintained release.

Comment 7 Susi Lehtola 2010-05-08 17:43:32 UTC
*** Bug 590268 has been marked as a duplicate of this bug. ***

Comment 8 Dmitri A. Sergatskov 2010-05-20 22:12:46 UTC
This might be related to this:

If you have both octave and octave-forge installed
than doing:

octave:1> save A
octave:2> quit

...

octave:> load A

would crash octave with segfault.
Removing package ann (with extreme prejudice)
seams to solve this problem.

Comment 9 John B 2010-05-21 23:27:36 UTC
*** Bug 594916 has been marked as a duplicate of this bug. ***

Comment 10 John B 2010-05-27 18:19:55 UTC
After upgrading to Fedora Core 13, qtoctave is still crashing on startup with the mark_as_command warning and the segmentation fault restart.

From the command-line, the same segmentation fault is obtained as Dmitri commented by simply using load on a saved variable (no need to quit after saving).

octave:1> save A
octave:2> load A

gives the segfault crash.

Dmitri's workaround worked for me.

uninstalling octave-forge stopped both the qtoctave and the command-line segmentation faults, even the mark_as_command warning.

Hope this will help to figure out the bug source.

Comment 11 Rakesh Pandit 2010-05-28 08:59:47 UTC
*** Bug 593484 has been marked as a duplicate of this bug. ***

Comment 12 John B 2010-05-28 18:51:22 UTC
Me again... ;-)

I'm afraid that I missread last lines in Comment 8.

To avoid the segfault crash, there is no need to uninstall the whole octave-forge, just the ANN package.

Comment 13 Alex Lancaster 2010-06-16 18:08:54 UTC
I can duplicate the bug as described in comment #10.  I suspect the ANN package may have been mis-compiled, there were some issues with it compiling a while back, I'll have a look into it.

Comment 14 Alex Lancaster 2010-06-16 21:08:11 UTC
*** Bug 603476 has been marked as a duplicate of this bug. ***

Comment 15 Alex Lancaster 2010-06-16 23:03:58 UTC
I think the short-term fix to this is to disable the "ann" package in octave-forge.  I will also report to upstream.  I already backported a fix from upstream SVN to fix the ann build and there is nothing more recent than that fix in upstream ann.

I don't know how often this package is used in practice and how big a loss this would be.  I think the issue is something to do with old SWIG wrappers being used.  Hopefully upstream will know more.

Comment 16 Alex Lancaster 2010-06-17 03:00:40 UTC
Reported on upstream mailing list:

http://thread.gmane.org/gmane.comp.gnu.octave.devel/4215

Comment 17 Alex Lancaster 2010-06-19 22:43:10 UTC
(In reply to comment #16)
> Reported on upstream mailing list:
> 
> http://thread.gmane.org/gmane.comp.gnu.octave.devel/4215    

OK, based on discussions on upstream list, the short-term workaround is to disable the autoloading of 'ann' by default.  I have adapted some patches from Debian to do this, see:

http://article.gmane.org/gmane.comp.gnu.octave.devel/4221

and I am making new builds now that I'll be pushing to updates-testing in active branches ASAP.

Comment 18 Fedora Update System 2010-06-20 00:35:20 UTC
octave-forge-20090607-16.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc13

Comment 19 Fedora Update System 2010-06-20 01:15:58 UTC
octave-forge-20090607-16.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc12

Comment 20 Fedora Update System 2010-06-20 01:16:49 UTC
octave-forge-20090607-16.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc11

Comment 21 Fedora Update System 2010-06-21 21:28:02 UTC
octave-forge-20090607-16.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update octave-forge'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc11

Comment 22 Fedora Update System 2010-06-21 21:34:07 UTC
octave-forge-20090607-16.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update octave-forge'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc12

Comment 23 Fedora Update System 2010-06-21 21:39:32 UTC
octave-forge-20090607-16.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update octave-forge'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc13

Comment 24 John B 2010-06-23 16:58:42 UTC
(In reply to comment #23)
> octave-forge-20090607-16.fc13 has been pushed to the Fedora 13 testing
> repository.  If problems still persist, please make note of it in this bug
> report.
>  If you want to test the update, you can install it with 
>  su -c 'yum --enablerepo=updates-testing update octave-forge'.  You can provide
> feedback for this update here:
> http://admin.fedoraproject.org/updates/octave-forge-20090607-16.fc13    

After installing the update, the save/load sequence does NOT give a segfault.

However, when trying to exit from octave (both command-line and qt-octave) a new crash occurs. The final line after the crash is:

panic: attempted clean up apparently failed -- aborting...
Aborted (core dumped)


This happens to me after updating octave without uninstalling the old version, and also after a clean install.

Comment 25 Dmitri A. Sergatskov 2010-06-23 17:39:16 UTC
I can reproduce this problem.
It appears to be related to java-1.2.6 package.

Comment 26 Alex Lancaster 2010-06-23 18:23:34 UTC
(In reply to comment #25)
> I can reproduce this problem.
> It appears to be related to java-1.2.6 package.    

Yep, me too.  Yet another package we may need to disable from autoloading... :(  I wish upstream would fix their octave subpackages properly.

Comment 27 Alex Lancaster 2010-06-23 18:34:46 UTC
(In reply to comment #25)
> I can reproduce this problem.
> It appears to be related to java-1.2.6 package.    

It's odd that this bug wasn't exposed through crashes on exit in the previous version of octave-forge, any ideas why that might have been the case Dmitri?

Comment 28 Dmitri A. Sergatskov 2010-06-23 22:07:46 UTC
I have no idea what has changed.
The latest upstream package is java-1.2.7.
If I un-install octave-forge completele and 
install only java-1.2.7 from octave
with "pkg install java-1.2.7.tar.gz"
I get what appears to be the same crash.

Comment 29 Alex Lancaster 2010-06-30 05:07:41 UTC
*** Bug 609015 has been marked as a duplicate of this bug. ***

Comment 30 Mark van Rossum 2010-07-02 22:23:38 UTC
Package: octave-6:3.2.4-2.fc13
Architecture: i686
OS Release: Fedora release 13 (Goddard)


How to reproduce
-----
Start octave and quit it immediately.
All fine with 
octave-forge    20090607-15.fc13 
but with 
octave-forge     20090607-16.fc13 
from updates-testing, quiting causes a crash.

Comment
-----
See above

Comment 31 Dmitri A. Sergatskov 2010-07-02 23:35:31 UTC
java package is broken. I think it was not compiled in -15 so 
it did not do anything. In -16 it is compiled and as a result
causes this problem. 

Dmitri.

Comment 32 Susi Lehtola 2010-07-03 23:34:36 UTC
*** Bug 603535 has been marked as a duplicate of this bug. ***

Comment 33 Alex Lancaster 2010-07-04 02:47:50 UTC
*** Bug 568236 has been marked as a duplicate of this bug. ***

Comment 34 Alex Lancaster 2010-07-05 07:01:22 UTC
OK, as a workaround, I'm disabling autoloading of the 'java' octave package, similar to the 'ann' package.  Builds are underway.

Comment 35 Fedora Update System 2010-07-05 08:54:30 UTC
octave-forge-20090607-17.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13

Comment 36 Fedora Update System 2010-07-05 10:05:18 UTC
octave-forge-20090607-17.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc12

Comment 37 Fedora Update System 2010-07-06 17:15:01 UTC
octave-forge-20090607-17.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update octave-forge'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13

Comment 38 Fedora Update System 2010-07-06 17:29:24 UTC
octave-forge-20090607-17.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update octave-forge'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc12

Comment 39 Durai 2010-07-10 14:13:20 UTC
Package: octave-6:3.2.4-2.fc13
Architecture: i686
OS Release: Fedora release 13 (Goddard)


Comment
-----
invoked QtOctave

Comment 40 Durai 2010-07-10 14:28:07 UTC
Package: octave-6:3.2.4-2.fc13
Architecture: i686
OS Release: Fedora release 13 (Goddard)


How to reproduce
-----
1.Start Qt Octave form gnome menu
2.
3.

Comment 41 Alex Lancaster 2010-07-10 23:24:38 UTC
(In reply to comment #40)
> Package: octave-6:3.2.4-2.fc13
> Architecture: i686
> OS Release: Fedora release 13 (Goddard)
> 
> 
> How to reproduce
> -----
> 1.Start Qt Octave form gnome menu
> 2.
> 3.    

Durai, please follow the instructions in comment #37 and test the update in updates-testing.  If it works for you, you can provide a +1 karma point on:

http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13

Thanks.

Comment 42 Alex Lancaster 2010-07-11 03:19:39 UTC
*** Bug 613368 has been marked as a duplicate of this bug. ***

Comment 43 Durai 2010-07-12 06:50:33 UTC
(In reply to comment #41)
> (In reply to comment #40)
> > Package: octave-6:3.2.4-2.fc13
> > Architecture: i686
> > OS Release: Fedora release 13 (Goddard)
> > 
> > 
> > How to reproduce
> > -----
> > 1.Start Qt Octave form gnome menu
> > 2.
> > 3.    
> 
> Durai, please follow the instructions in comment #37 and test the update in
> updates-testing.  If it works for you, you can provide a +1 karma point on:
> 
> http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13
> 
> Thanks.    

It works. Thanks.

Comment 44 Durai 2010-07-12 07:02:24 UTC
(In reply to comment #43)
> (In reply to comment #41)
> > (In reply to comment #40)
> > > Package: octave-6:3.2.4-2.fc13
> > > Architecture: i686
> > > OS Release: Fedora release 13 (Goddard)
> > > 
> > > 
> > > How to reproduce
> > > -----
> > > 1.Start Qt Octave form gnome menu
> > > 2.
> > > 3.    
> > 
> > Durai, please follow the instructions in comment #37 and test the update in
> > updates-testing.  If it works for you, you can provide a +1 karma point on:
> > 
> > http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13
> > 
> > Thanks.    
> 
> It works. Thanks.    

Sorry. I don't know how to add karma. please guide me.

Comment 45 Alex Lancaster 2010-07-12 07:31:21 UTC
(In reply to comment #44)
> (In reply to comment #43)

> > It works. Thanks.    
> 
> Sorry. I don't know how to add karma. please guide me.    

Just visit:

 http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13

and click "add comment" and check "Works for me", you need to provide an e-mail address and there is a captcha to avoid spam.  karma is a nickname for points accrued to an update.

Comment 46 Kevin Kofler 2010-07-12 08:04:03 UTC
Note that the karma is only actually counted in the total karma value if it comes from a user registered in the Fedora Account System (FAS) and logged in with his/her FAS account. Anonymous karma is shown in the comments, but not counted towards the total.

Comment 47 Durai 2010-07-13 07:01:16 UTC
(In reply to comment #45)
> (In reply to comment #44)
> > (In reply to comment #43)
> 
> > > It works. Thanks.    
> > 
> > Sorry. I don't know how to add karma. please guide me.    
> 
> Just visit:
> 
>  http://admin.fedoraproject.org/updates/octave-forge-20090607-17.fc13
> 
> and click "add comment" and check "Works for me", you need to provide an e-mail
> address and there is a captcha to avoid spam.  karma is a nickname for points
> accrued to an update.    

Done.

Comment 48 Fedora Update System 2010-07-13 07:44:08 UTC
octave-forge-20090607-17.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 49 Fedora Update System 2010-07-13 07:44:47 UTC
octave-forge-20090607-17.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 50 Alex Lancaster 2010-07-17 19:31:08 UTC
*** Bug 615604 has been marked as a duplicate of this bug. ***