Okular crashes with gs files

Bug #183266 reported by Federico
Affects Status Importance Assigned to Milestone
KDE Graphics
kdegraphics-kde4 (Ubuntu)
Fix Released
Rich Johnson

Bug Description

Binary package hint: okular-kde4

Okular always crashes when opening, or after some seconds when visualizing different ps files.
I found out in the kde bugs site that the problem should be related with the version of the libgs ubuntu package: http://bugs.kde.org/show_bug.cgi?id=155674
In my kubuntu gutsy I have version 8.61.dfsg.1~svn8187-0ubuntu3.2 installed, while in comment #6 they state that okular can work properly with versions higher than 8.61.dfsg.1~svn8187-3.
Any plan to update the libgs8 version in the repositories? Right know, okular is unusable...at least with gs files

Tags: kde4
Changed in kdegraphics:
status: Unknown → Invalid
Revision history for this message
Rich Johnson (nixternal) wrote :

Do you have a GS file that I can use to try and recreate this issue? The only GS files I have are the ones I created from Kile and LaTeX, and all work just fine in Okular. In hardy, libgs8 is now version 8.61.dfsg.1-1ubuntu1. Are you still experiencing this issue? Thank you.

Changed in kdegraphics-kde4:
assignee: nobody → nixternal
status: New → Incomplete
Revision history for this message
Federico (81joe81) wrote :

Hi Richard,
you can try with this file: http://eprint.iacr.org/2008/005.ps
After scrolling the file a little bit, okular crashes.
You are right about the fact that the ps files generated with LaTeX work fine, I've experienced that too.

Revision history for this message
Rich Johnson (nixternal) wrote :

OK, Okular still didn't crash, however this is what I noticed.

I noticed 2 instances of Okular in htop/top. When reading a page and not scrolling in Okular, everything was fine, however when I scrolled, CPU utilization went up to 100% and Load Average went from 0.88 to 2.15.

I do believe you though that it can and will cause crashes with that type of load. Let me check upstream and see if I can find anything.

Revision history for this message
Rich Johnson (nixternal) wrote :

Hey, when it crashes, do you get any crash dialog at all where you can perform a backtrace? If not, run Okular from the command line and copy and paste what you get when it crashes.

Revision history for this message
Fabio Puddu (fabius) wrote :

Hi everybody!
The same happens to me when loading postscript files with okular
The file that causes the crash is attached and it was generated by the R graphical package
I include also the crash log from terminal, if it can be of help

fabio@werowance:~$ /usr/lib/kde4/bin/okular
GPL Ghostscript SVN PRE-RELEASE 8.61 (2007-08-02)
Copyright (C) 2007 Artifex Software, Inc. All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Loading NimbusSanL-Regu font from /var/lib/defoma/gs.d/dirs/fonts/n019003l.pfb... 2919668 1339785 2535180 948182 1 done.
Loading NimbusSanL-Bold font from /var/lib/defoma/gs.d/dirs/fonts/n019004l.pfb... 3036812 1469859 2535180 951808 1 done.
Loading NimbusSanL-ReguItal font from /var/lib/defoma/gs.d/dirs/fonts/n019023l.pfb... 3174052 1611537 2535180 955 007 1 done.
Loading NimbusSanL-BoldItal font from /var/lib/defoma/gs.d/dirs/fonts/n019024l.pfb... 3291196 1745368 2535180 958 210 1 done.
Loading StandardSymL font from /var/lib/defoma/gs.d/dirs/fonts/s050000l.pfb... 3331388 1798614 2535180 961586 1 d one.
KCrash: crashing... crashRecursionCounter = 2
KCrash: Application Name = okular path = <unknown> pid = 15035
okular: Fatal IO error: client killed

Revision history for this message
Rich Johnson (nixternal) wrote :

I am going to confirm because Fabio had an issue that is similar.

Fabio, I used your .ps file and had no problems. One thing I noticed though between your .ps file and Federico's .gs file, is that the .ps file didn't hammer my system the way that the .gs file did.

So, are you all using Gutsy or Hardy, x86 or amd64, graphics card? My setup currently is Hardy, x86, Intel. I will get my amd64 box up and running so I can test this further with it.

Changed in kdegraphics-kde4:
status: Incomplete → Confirmed
Revision history for this message
Fabio Puddu (fabius) wrote :

I'm using Gutsy, x86 and Ati graphic card
Okular version is 0.6.1 and KDE 4.0.1
it could be something related to Gutsy or the graphic card?!?

Revision history for this message
Rich Johnson (nixternal) wrote :

I have to check the Gutsy version, but I don't believe there are any differences that could cause an issue, but I am not 100% certain on that. I will speak with our Gutsy KDE 4 maintainer and see if he can find anything on it.

Revision history for this message
Federico (81joe81) wrote :
Download full text (5.0 KiB)

I'm using Gutsy, x86 and nVidia graphic card
Sometimes the crash is right after opening a file, sometimes scrolling it, sometimes modifying the zoom.
Sometimes a crash dialog is opened with a invalid backtrace, sometimes with a valid one, sometimes it's not opened at all.
Here's the backtrace generated after scrolling a bit the file for which I posted the link before.

(no debugging symbols found)
Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread -1236043376 (LWP 8835)]
[New Thread -1296061552 (LWP 8845)]
[KCrash handler]
#6 0xb6d38583 in strlen () from /lib/tls/i686/cmov/libc.so.6
#7 0xb2f76665 in ?? () from /usr/lib/libgs.so.8
#8 0x00000000 in ?? ()

Thread 1 (Thread -1236043376 (LWP 8835)):
#0 0xffffe411 in __kernel_vsyscall ()
#1 0xb6d915e7 in poll () from /lib/tls/i686/cmov/libc.so.6
#2 0xb6905839 in ?? () from /usr/lib/libX11.so.6
#3 0x08068b90 in ?? ()
#4 0x00000001 in ?? ()
#5 0xffffffff in ?? ()
#6 0xb690e67f in _X11TransWrite () from /usr/lib/libX11.so.6
#7 0xb6905c2f in _XRead () from /usr/lib/libX11.so.6
#8 0xb6906604 in _XReply () from /usr/lib/libX11.so.6
#9 0xb6901d04 in XTranslateCoordinates () from /usr/lib/libX11.so.6
#10 0xb70c3561 in QWidget::mapToGlobal (this=0x8158df8, pos=@0xbfad9c44)
    at kernel/qwidget_x11.cpp:1030
#11 0xb4f75db1 in ?? () from /usr/lib/kde4/lib/kde4/okularpart.so
#12 0xbfad9860 in ?? ()
#13 0x08158df8 in ?? ()
#14 0xbfad9c44 in ?? ()
#15 0xbfad9858 in ?? ()
#16 0xbfad98a0 in ?? ()
#17 0x00000748 in ?? ()
#18 0xbfad9988 in ?? ()
#19 0xb7089ea7 in QWidget::event (this=0x8158df8, event=0xbfad9c34)
    at kernel/qwidget.cpp:6138
#20 0xb7089ea7 in QWidget::event (this=0x8158df8, event=0xbfad9c34)
    at kernel/qwidget.cpp:6138
#21 0xb73d46f2 in QFrame::event (this=0x8158df8, e=0xbfad9c34)
    at widgets/qframe.cpp:657
#22 0xb746695f in QAbstractScrollArea::viewportEvent (this=0x8158df8,
    e=0xbfad9c34) at widgets/qabstractscrollarea.cpp:926
#23 0xb74694ee in QAbstractScrollAreaPrivate::viewportEvent (this=0x8336bd8,
    event=0xbfad9c34) at widgets/qabstractscrollarea_p.h:95
#24 0xb7469520 in QAbstractScrollAreaFilter::eventFilter (this=0x8329230,
    o=0x83291a8, e=0xbfad9c34) at widgets/qabstractscrollarea_p.h:106
#25 0xb70383c8 in QApplicationPrivate::notify_helper (this=0x80653c0,
    receiver=0x83291a8, e=0xbfad9c34) at kernel/qapplication.cpp:3550
#26 0xb7039566 in QApplication::notify (this=0xbfada7c8, receiver=0x8332720,
    e=0xbfad9ea8) at kernel/qapplication.cpp:3319
#27 0xb7a8d550 in KApplication::notify (this=0xbfada7c8, receiver=0x8332720,
    at /build/buildd/kde4libs-4.0.1/kdeui/kernel/kapplication.cpp:314
#28 0xb7ebf456 in QCoreApplication::notifyInternal (this=0xbfada7c8,
    receiver=0x8332720, event=0xbfad9ea8) at kernel/qcoreapplication.cpp:532
#29 0xb704381d in QCoreApplication::sendSpontaneousEvent (receiver=0x8332720,
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:205
#30 0xb7098144 in QETWidget::translateWheelEvent (this=0x8332720,
    global_x=676, global_y=440, delta=-120, buttons=@0xbfada08c,


Revision history for this message
Rich Johnson (nixternal) wrote :

(no debugging symbols found)
Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
(no debugging symbols found)
[Thread debugging using libthread_db enabled]
[New Thread 0xb6613720 (LWP 7509)]
[New Thread 0xb1895b90 (LWP 9283)]
[New Thread 0xb2d3db90 (LWP 7532)]
[KCrash handler]
#6 0xb7fc7410 in __kernel_vsyscall ()
#7 0xb6e29f35 in raise () from /lib/tls/i686/cmov/libc.so.6
#8 0xb6e2b8b1 in abort () from /lib/tls/i686/cmov/libc.so.6
#9 0xb7e63a75 in qt_message_output () from /usr/lib/libQtCore.so.4
#10 0xb7e63b38 in qFatal () from /usr/lib/libQtCore.so.4
#11 0xb7e63b9c in qt_assert_x () from /usr/lib/libQtCore.so.4
#12 0xb22cd495 in ?? () from /usr/lib/kde4/lib/kde4/okularGenerator_poppler.so
#13 0xb22d1d42 in ?? () from /usr/lib/kde4/lib/kde4/okularGenerator_poppler.so
#14 0xb22d1d2f in ?? () from /usr/lib/kde4/lib/kde4/okularGenerator_poppler.so
#15 0xb22d2120 in ?? () from /usr/lib/kde4/lib/kde4/okularGenerator_poppler.so
#16 0x00000135 in ?? ()
#17 0x08970740 in ?? ()
#18 0x084e19b8 in ?? ()
#19 0xb720ef6b in QPixmap::fromImage () from /usr/lib/libQtGui.so.4
#20 0xb22c763b in ?? () from /usr/lib/kde4/lib/kde4/okularGenerator_poppler.so
#21 0x08340270 in ?? ()
#22 0x089b8b50 in ?? ()
#23 0x0893ef88 in ?? ()
#24 0xb7f330c7 in QObject::qt_metacall () from /usr/lib/libQtCore.so.4
#25 0xb22c77b3 in ?? () from /usr/lib/kde4/lib/kde4/okularGenerator_poppler.so
#26 0x08340230 in ?? ()
#27 0x00000000 in ?? ()
#0 0xb7fc7410 in __kernel_vsyscall ()

Revision history for this message
Rich Johnson (nixternal) wrote :

It took me forever to get it to crash finally. I got it to crash on the 005.ps file, but the dbg was corrupted. So I opened up one of my .pdf files here that is graphically intensive and then went to reopen the 005.ps file and that is when it crashed.

The issue is obviously the resource intensiveness of Okular, no if's and's or but's. The amount of resources that Okular uses is very high.

Revision history for this message
Rich Johnson (nixternal) wrote :

Changing to another upstream bug report that is similar to the crash responses we are seeing.

Changed in kdegraphics:
status: Unknown → New
Changed in kdegraphics:
status: New → Invalid
Revision history for this message
xRaich[o]²x (raichoo) wrote :

Seems to be a problem with libgs according to http://bugs.kde.org/show_bug.cgi?id=160342.

I can confirm this on current Hardy Beta.

Revision history for this message
Aldoo (aldo-public) wrote :

Well according to the latter link, it seems that this is not an upstream bug, but a problem with a patch from Debian (which Ubuntu uses).
I don't know what that patch is supposed to do, but I think I'd rather have a non-crashing postscript support in okular ! (By the way, kghostview works just fine. Is it also using libgs ?)

Revision history for this message
xRaich[o]²x (raichoo) wrote :

Seems to work now with Hardy Final. I'm able to open ps files without crashig okular.

Changed in kdegraphics-kde4:
status: Confirmed → Fix Released
Changed in kdegraphics:
importance: Unknown → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.