Bug 334088 - Upgraded to Kubuntu 14.04, Okular crashes with "Fatal IO error"
Summary: Upgraded to Kubuntu 14.04, Okular crashes with "Fatal IO error"
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: PDF backend (show other bugs)
Version: unspecified
Platform: Kubuntu Linux
: NOR crash
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
: 334415 335698 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-04-29 16:34 UTC by ptomblin
Modified: 2014-07-30 19:42 UTC (History)
9 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
New crash information added by DrKonqi (10.37 KB, text/plain)
2014-05-16 21:24 UTC, Rob
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ptomblin 2014-04-29 16:34:26 UTC
I upgraded my Kubuntu box to 14.04 on Saturday, and since then every time I try to invoke Okular, either from the command line or by clicking on a file in Dolphin, it opens an empty window, waits about 3 seconds, and then dies. On the command line, it looks like:
$ okular as.pdf 
Xlib:  extension "RANDR" missing on display ":0".
Xlib:  extension "RANDR" missing on display ":0".
Xlib:  extension "RANDR" missing on display ":0".
Can't get XRandR version 
okular: Fatal IO error: client killed

I've tried many different PDF files with the same results. This includes PDFs that I had open on my desktop before the upgrade.

Reproducible: Always

Steps to Reproduce:
1. Type "okular filename" where filename is the name of a valid PDF file.
2.
3.
Actual Results:  
okular: Fatal IO error: client killed


Expected Results:  
It should have opened the PDF file.
Comment 1 ptomblin 2014-04-29 17:07:56 UTC
Ran "strace okular as.pdf". Towards the end got:
lstat("/usr", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat("/usr/lib", {st_mode=S_IFDIR|0755, st_size=61440, ...}) = 0
lstat("/usr/lib/kde4", {st_mode=S_IFDIR|0755, st_size=61440, ...}) = 0
lstat("/usr/lib/kde4/plugins", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat("/usr/lib/kde4/plugins/kscreen", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat("/usr/lib/kde4/plugins/kscreen/KSC_XRandR.so", {st_mode=S_IFREG|0644, st_size=101792, ...}) = 0
stat("/usr/lib/kde4/plugins/kscreen/KSC_XRandR.so", {st_mode=S_IFREG|0644, st_size=101792, ...}) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=3519, ...}) = 0
open("/usr/lib/kde4/plugins/kscreen/KSC_XRandR.so", O_RDONLY|O_CLOEXEC) = 11
read(11, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\300i\0\0\0\0\0\0"..., 832) = 832
fstat(11, {st_mode=S_IFREG|0644, st_size=101792, ...}) = 0
mmap(NULL, 2196960, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 11, 0) = 0x7f35a2870000
mprotect(0x7f35a2887000, 2097152, PROT_NONE) = 0
mmap(0x7f35a2a87000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 11, 0x17000) = 0x7f35a2a87000
close(11)                               = 0
open("/usr/local/lib/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/x86_64/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("x86_64/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 11
fstat(11, {st_mode=S_IFREG|0644, st_size=132102, ...}) = 0
mmap(NULL, 132102, PROT_READ, MAP_PRIVATE, 11, 0) = 0x7f35a3392000
close(11)                               = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/usr/lib/x86_64-linux-gnu/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = 11
read(11, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\320\32\0\0\0\0\0\0"..., 832) = 832
fstat(11, {st_mode=S_IFREG|0644, st_size=39128, ...}) = 0
mmap(NULL, 2134408, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 11, 0) = 0x7f35a2666000
mprotect(0x7f35a266f000, 2093056, PROT_NONE) = 0
mmap(0x7f35a286e000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 11, 0x8000) = 0x7f35a286e000
close(11)                               = 0
mprotect(0x7f35a286e000, 4096, PROT_READ) = 0
mprotect(0x7f35a2a87000, 4096, PROT_READ) = 0
munmap(0x7f35a3392000, 132102)          = 0
poll([{fd=6, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=6, revents=POLLOUT}])
writev(6, [{"b\0\4\0\5\0\0\3", 8}, {"RANDR", 5}, {"\0\0\0", 3}], 3) = 16
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\1\0B\4\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 4096}], msg_controllen=0, msg_flags=0}, 0) = 32
recvmsg(6, 0x7fff52754700, 0)           = -1 EAGAIN (Resource temporarily unavailable)
write(2, "Xlib:  extension \"RANDR\" missing"..., 50Xlib:  extension "RANDR" missing on display ":0".
) = 50
munmap(0x7f35a2870000, 2196960)         = 0
munmap(0x7f35a2666000, 2134408)         = 0
lstat("/usr", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat("/usr/lib", {st_mode=S_IFDIR|0755, st_size=61440, ...}) = 0
lstat("/usr/lib/kde4", {st_mode=S_IFDIR|0755, st_size=61440, ...}) = 0
lstat("/usr/lib/kde4/plugins", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat("/usr/lib/kde4/plugins/kscreen", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat("/usr/lib/kde4/plugins/kscreen/KSC_XRandR11.so", {st_mode=S_IFREG|0644, st_size=44016, ...}) = 0
stat("/usr/lib/kde4/plugins/kscreen/KSC_XRandR11.so", {st_mode=S_IFREG|0644, st_size=44016, ...}) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=3519, ...}) = 0
open("/usr/lib/kde4/plugins/kscreen/KSC_XRandR11.so", O_RDONLY|O_CLOEXEC) = 11
read(11, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0000N\0\0\0\0\0\0"..., 832) = 832
fstat(11, {st_mode=S_IFREG|0644, st_size=44016, ...}) = 0
mmap(NULL, 2139136, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 11, 0) = 0x7f35a287e000
mprotect(0x7f35a2888000, 2093056, PROT_NONE) = 0
mmap(0x7f35a2a87000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 11, 0x9000) = 0x7f35a2a87000
close(11)                               = 0
open("/usr/local/lib/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/x86_64/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("x86_64/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("libXrandr.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 11
fstat(11, {st_mode=S_IFREG|0644, st_size=132102, ...}) = 0
mmap(NULL, 132102, PROT_READ, MAP_PRIVATE, 11, 0) = 0x7f35a3392000
close(11)                               = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/usr/lib/x86_64-linux-gnu/libXrandr.so.2", O_RDONLY|O_CLOEXEC) = 11
read(11, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\320\32\0\0\0\0\0\0"..., 832) = 832
fstat(11, {st_mode=S_IFREG|0644, st_size=39128, ...}) = 0
mmap(NULL, 2134408, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 11, 0) = 0x7f35a2674000
mprotect(0x7f35a267d000, 2093056, PROT_NONE) = 0
mmap(0x7f35a287c000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 11, 0x8000) = 0x7f35a287c000
close(11)                               = 0
open("/usr/local/lib/libX11-xcb.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/x86_64/libX11-xcb.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/libX11-xcb.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("x86_64/libX11-xcb.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("libX11-xcb.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/usr/lib/x86_64-linux-gnu/libX11-xcb.so.1", O_RDONLY|O_CLOEXEC) = 11
read(11, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\340\5\0\0\0\0\0\0"..., 832) = 832
fstat(11, {st_mode=S_IFREG|0644, st_size=5992, ...}) = 0
mmap(NULL, 2101304, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 11, 0) = 0x7f35a2472000
mprotect(0x7f35a2473000, 2093056, PROT_NONE) = 0
mmap(0x7f35a2672000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 11, 0) = 0x7f35a2672000
close(11)                               = 0
open("/usr/local/lib/libxcb-randr.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/x86_64/libxcb-randr.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("tls/libxcb-randr.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("x86_64/libxcb-randr.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("libxcb-randr.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/usr/lib/x86_64-linux-gnu/libxcb-randr.so.0", O_RDONLY|O_CLOEXEC) = 11
read(11, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\220W\0\0\0\0\0\0"..., 832) = 832
fstat(11, {st_mode=S_IFREG|0644, st_size=51280, ...}) = 0
mmap(NULL, 2146408, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 11, 0) = 0x7f35a2265000
mprotect(0x7f35a2270000, 2097152, PROT_NONE) = 0
mmap(0x7f35a2470000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 11, 0xb000) = 0x7f35a2470000
close(11)                               = 0
mprotect(0x7f35a2470000, 4096, PROT_READ) = 0
mprotect(0x7f35a2672000, 4096, PROT_READ) = 0
mprotect(0x7f35a287c000, 4096, PROT_READ) = 0
mprotect(0x7f35a2a87000, 4096, PROT_READ) = 0
munmap(0x7f35a3392000, 132102)          = 0
write(3, "\1\0\0\0\0\0\0\0", 8)         = 8
poll([{fd=6, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN|POLLOUT}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\25\0B\4\26\0\0\3\26\0\0\3\342\260\217\1\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 4096}], msg_controllen=0, msg_flags=0}, 0) = 32
writev(6, [{"b\0\4\0\5\0\0\3", 8}, {"RANDR", 5}, {"\0\0\0", 3}], 3) = 16
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\34\0B\4\26\0\0\3\357\1\0\0\256\371\364\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 64
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\34\0B\4\26\0\0\3\322\1\0\0\256\371\364\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 4096}], msg_controllen=0, msg_flags=0}, 0) = 32
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\34\0B\4\26\0\0\3\332\1\0\0\302\371\364\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 96
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\34\0B\4\26\0\0\3w\1\0\0\302\371\364\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 4096}], msg_controllen=0, msg_flags=0}, 0) = 32
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\23\0B\4\26\0\0\3\26\0\0\3\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 64
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\t\3B\4\26\0\0\3\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 96
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\226\0B\4\26\0\0\3\26\0\0\3\0\0\0\0\22\v\32\0j\6\345\3\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 64
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\34\0B\4f\5\0\0\327\1\0\0\302\371\364\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 4096}], msg_controllen=0, msg_flags=0}, 0) = 32
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\34\0B\4\26\0\0\3w\1\0\0\303\371\364\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 64
recvmsg(6, 0x7fff52754670, 0)           = -1 EAGAIN (Resource temporarily unavailable)
recvmsg(6, 0x7fff52754670, 0)           = -1 EAGAIN (Resource temporarily unavailable)
write(2, "Xlib:  extension \"RANDR\" missing"..., 50Xlib:  extension "RANDR" missing on display ":0".
) = 50
write(2, "Xlib:  extension \"RANDR\" missing"..., 50Xlib:  extension "RANDR" missing on display ":0".
) = 50
poll([{fd=6, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=6, revents=POLLOUT}])
writev(6, [{"\1\0\n\0\266\0\0\3f\5\0\0\0\0\0\0\1\0\1\0\0\0\0\0\0\0\0\0\n\0\0\0"..., 40}, {NULL, 0}, {"", 0}], 3) = 40
poll([{fd=6, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=6, revents=POLLOUT}])
writev(6, [{"b\0\4\0\5\0\0\0RANDR\0\0\0", 16}], 1) = 16
poll([{fd=6, events=POLLIN}], 1, 4294967295) = 1 ([{fd=6, revents=POLLIN}])
recvmsg(6, {msg_name(0)=NULL, msg_iov(1)=[{"\1\0E\4\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 4096}], msg_controllen=0, msg_flags=0}, 0) = 32
write(2, "Can't get XRandR version \n", 26Can't get XRandR version 
) = 26
write(2, "okular: Fatal IO error: client k"..., 38okular: Fatal IO error: client killed
) = 38
sendmsg(7, {msg_name(0)=NULL, msg_iov(2)=[{"l\1\1\1u\0\0\0\f\0\0\0\177\0\0\0\1\1o\0\25\0\0\0/org/fre"..., 144}, {"p\0\0\0type='signal',path='/KBookma"..., 117}], msg_controllen=0, msg_flags=0}, MSG_NOSIGNAL) = 261
sendmsg(7, {msg_name(0)=NULL, msg_iov(2)=[{"l\1\1\1z\0\0\0\r\0\0\0\177\0\0\0\1\1o\0\25\0\0\0/org/fre"..., 144}, {"u\0\0\0type='signal',path='/KBookma"..., 122}], msg_controllen=0, msg_flags=0}, MSG_NOSIGNAL) = 266
msync(0x7f35abc88000, 10547304, MS_ASYNC|MS_INVALIDATE) = 0
munmap(0x7f35abc88000, 10547304)        = 0
sendmsg(7, {msg_name(0)=NULL, msg_iov(2)=[{"l\1\1\1d\0\0\0\16\0\0\0\177\0\0\0\1\1o\0\25\0\0\0/org/fre"..., 144}, {"_\0\0\0type='signal',path='/KGlobal"..., 100}], msg_controllen=0, msg_flags=0}, MSG_NOSIGNAL) = 244
write(5, "@", 1)                        = 1
close(5)                                = 0
close(4)                                = 0
rt_sigaction(SIGCHLD, NULL, {0x7f35b745ccc0, [], SA_RESTORER|SA_SIGINFO|SA_NOCLDSTOP, 0x7f35b69f7ff0}, 8) = 0
rt_sigaction(SIGCHLD, {SIG_DFL, [], SA_RESTORER, 0x7f35b69f7ff0}, NULL, 8) = 0
exit_group(1)                           = ?
+++ exited with 1 +++

Is it perhaps not handling the fact that the nVidia drivers don't support XRANDR badly?
Comment 2 Albert Astals Cid 2014-04-29 18:13:12 UTC
Can you please gdb it or valgrind it? strace is not the debugging tool for this job. Also install the okular-dbg package first.
Comment 3 ptomblin 2014-04-29 18:31:24 UTC
You've going to have to give me a hint on where to put a breakpoint to get some useful information, because if I just go into gdb and say "run as.pdf", it gives me:
(gdb) run as.pdf
Starting program: /usr/bin/okular as.pdf
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Xlib:  extension "RANDR" missing on display ":0".
Xlib:  extension "RANDR" missing on display ":0".
Xlib:  extension "RANDR" missing on display ":0".
Can't get XRandR version 
okular: Fatal IO error: client killed
[Inferior 1 (process 31614) exited with code 01]
(gdb) where
No stack.
(gdb) 

So I don't see how that's going to be helpful.
Comment 4 Albert Astals Cid 2014-04-29 20:15:03 UTC
Can you run kdebugdialog, enable all output for okular and then attach the output?
Comment 5 ptomblin 2014-04-29 20:57:45 UTC
$ okular
okular(25909)/kdeui (KGlobalAccel) KActionCollection::addAction: Registering action  "go_first"  under new name  "first_page"
okular(25909)/kdeui (KGlobalAccel) KActionCollection::addAction: Registering action  "go_last"  under new name  "last_page"
okular(25909)/kdecore (KSycoca) KSycocaPrivate::openDatabase: Trying to open ksycoca from "/var/tmp/kdecache-ptomblin/ksycoca4"
okular(25909)/kdeui (KGlobalAccel) KActionCollection::addAction: Registering action  "file_save_as"  under new name  "file_save_copy"
okular(25909)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25909)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25909)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25909)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25909)/kio (KDirWatch) KDirWatchPrivate::KDirWatchPrivate: INotify available:  true
okular(25909)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25909)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25909)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25909)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25909)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25909)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
Bus::open: Can not get ibus-daemon's address. 
IBusInputContext::createInputContext: no connection to ibus-daemon 
okular(25909)/kparts KParts::ReadWritePart::setModified: setModified( false )
okular(25909)/kparts KParts::Part::~Part: deleting widget Sidebar(0x148e4c0) ""
okular(25909)/kio (KDirWatch) KDirWatchPrivate::KDirWatchPrivate: INotify available:  true
ptomblin@allhats2:~$ okular as.pdf 
okular(25923)/kdeui (KGlobalAccel) KActionCollection::addAction: Registering action  "go_first"  under new name  "first_page"
okular(25923)/kdeui (KGlobalAccel) KActionCollection::addAction: Registering action  "go_last"  under new name  "last_page"
okular(25923)/kdecore (KSycoca) KSycocaPrivate::openDatabase: Trying to open ksycoca from "/var/tmp/kdecache-ptomblin/ksycoca4"
okular(25923)/kdeui (KGlobalAccel) KActionCollection::addAction: Registering action  "file_save_as"  under new name  "file_save_copy"
okular(25923)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25923)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25923)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25923)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25923)/kio (KDirWatch) KDirWatchPrivate::KDirWatchPrivate: INotify available:  true
okular(25923)/kdecore (KConfigSkeleton) KCoreConfigSkeleton::writeConfig:
okular(25923)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25923)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25923)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25923)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25923)/kdeui (KMainWindow) KMainWindow::applyMainWindowSettings: KMainWindow::applyMainWindowSettings  "MainWindow"
okular(25923)/kparts KParts::ReadWritePart::setModified: setModified( false )
okular(25923)/kparts KParts::ReadWritePart::setModified: setModified( false )
okular(25923)/kdecore (trader) KMimeTypeTrader::query: query for mimeType  "application/pdf" ,  "okular/Generator"  : returning  1  offers
okular(25923): BEGIN: Loading backend
Xlib:  extension "RANDR" missing on display ":0".
okular(25923)   XRandR::XRandR: XRandR extension not available or unsupported version
okular(25923)   BackendLoader::init: Skipping "XRandR" backend
Xlib:  extension "RANDR" missing on display ":0".
okular(25923)/KSRandr11   XRandRX11Helper::XRandRX11Helper: Detected XRandR 0.0
okular(25923)/KSRandr11   XRandRX11Helper::XRandRX11Helper: Event Base:  0
okular(25923)/KSRandr11   XRandRX11Helper::XRandRX11Helper: Event Error:  0
Xlib:  extension "RANDR" missing on display ":0".
Can't get XRandR version 
okular(25923)   BackendLoader::init: Skipping "XRandR 1.1" backend
okular: Fatal IO error: client killed
Comment 6 Albert Astals Cid 2014-04-29 21:09:22 UTC
Which libkscreen version are you running?
Comment 7 ptomblin 2014-04-29 21:25:33 UTC
# dpkg -l libkscreen\*
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                Version        Architecture   Description
+++-===================-==============-==============-===========================================
rc  libkscreen0         0.0.92-0ubuntu amd64          library for screen management - shared libr
ii  libkscreen1         1.0.2-0ubuntu2 amd64          library for screen management - shared libr
ii  libkscreensaver5    4:4.11.8-0ubun amd64          library of the KDE Screensaver system
Comment 8 Albert Astals Cid 2014-04-29 22:47:50 UTC
Alex, Dan, another libkscreen crash :-/ Any help?
Comment 9 Albert Astals Cid 2014-04-29 22:55:34 UTC
Eugene, more kscreen bugs :'(
Comment 10 Albert Astals Cid 2014-04-29 22:59:55 UTC
ptomblin do you know how to recompile packages? Would you be able to try a patch for libkscreen?
Comment 11 ptomblin 2014-04-29 23:05:06 UTC
I don't have a lot of -devel packages installed, but I can give it a try if you give me some guidance. It's been a long long long time since I used to do C programming.
Comment 12 Albert Astals Cid 2014-04-29 23:13:52 UTC
Actually since i'm running Ubuntu 14.04 myself i'll just send you a .deb package you can install with dpkg -i and see if it helps
Comment 13 ptomblin 2014-04-30 00:33:13 UTC
I installed the .deb, and now I get a SEGV. I enabled core dumps, and the backtrace looks like:
Reading symbols from okular...Reading symbols from /usr/lib/debug//usr/bin/okular...done.
done.
[New LWP 30986]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `okular as.pdf'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007f86c33d9f79 in __GI_raise (sig=11) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
56      ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) where
#0  0x00007f86c33d9f79 in __GI_raise (sig=11) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
#1  0x00007f86c55bf012 in KCrash::defaultCrashHandler(int) () from /usr/lib/libkdeui.so.5
#2  <signal handler called>
#3  0x00007f86b362f4b8 in KScreen::Config::outputs() const () from /usr/lib/libkscreen.so.1
#4  0x00007f86b437b40f in Okular::Utils::realDpi (widgetOnScreen=0x2704b70) at ../core/utils.cpp:103
#5  0x00007f86b43560db in Okular::DocumentPrivate::openDocumentInternal (this=0x26e7160, offer=..., 
    isstdin=isstdin@entry=false, docFile=..., filedata=...) at ../core/document.cpp:939
#6  0x00007f86b4356745 in Okular::Document::openDocument (this=0x26bea20, docFile=..., url=..., 
    _mime=...) at ../core/document.cpp:2225
#7  0x00007f86b4618c0c in Okular::Part::openFile (this=0x262e0e0) at ../part.cpp:1244
#8  0x00007f86c6070c47 in ?? () from /usr/lib/libkparts.so.4
#9  0x00007f86c607222e in KParts::ReadOnlyPart::openUrl(KUrl const&) () from /usr/lib/libkparts.so.4
#10 0x00007f86b460df5b in Okular::Part::openUrl (this=0x262e0e0, _url=...) at ../part.cpp:1394
#11 0x000000000040f117 in Shell::openUrl (this=this@entry=0x25ff810, url=...)
    at ../../shell/shell.cpp:246
#12 0x000000000040f5ae in Shell::openDocument (this=this@entry=0x25ff810, doc=...)
    at ../../shell/shell.cpp:186
#13 0x0000000000409dca in main (argc=<optimized out>, argv=<optimized out>)
    at ../../shell/main.cpp:163
Comment 14 Eugene Shalygin 2014-04-30 08:53:04 UTC
The evidence of the problem is in the message "Xlib:  extension "RANDR" missing on display ":0".". Therefore, could you, please, do the following and show us the results:
$ cat /var/log/Xorg.0.log | grep -i randr
and
$ xrandr -q

Do you, by chance, use Xinerama? Do you see the same message regarding RANDR when you launch another GUI programs?
Comment 15 ptomblin 2014-04-30 12:52:54 UTC
# grep -i randr /var/log/Xorg.0.log
[    20.102] Initializing built-in extension RANDR
[    21.470] (WW) NVIDIA: Xinerama is enabled, so RandR has likely been disabled by the
[    23.238] (WW) NVIDIA(0): Not registering RandR
[    23.238] (==) RandR enabled
[    23.362] (WW) NVIDIA(1): Not registering RandR
[    23.362] (==) RandR enabled
[    23.458] (WW) NVIDIA(2): Not registering RandR
[    23.458] (==) RandR enabled
# xrandr -q
RandR extension missing
#

I've been seeing messages about "RANDR missing" for years - since I had to enable Xinerama to get my third monitor working, probably. It's never caused a program to crash before. For instance:
$ sublime_text 
Xlib:  extension "RANDR" missing on display ":0".
$
$ gvim ~/Downloads/comment-9.txt
Xlib:  extension "RANDR" missing on display ":0".

(gvim:30325): GLib-GObject-WARNING **: Attempt to add property GnomeProgram::sm-connect after class was initialised

(gvim:30325): GLib-GObject-WARNING **: Attempt to add property GnomeProgram::show-crash-dialog after class was initialised

(gvim:30325): GLib-GObject-WARNING **: Attempt to add property GnomeProgram::display after class was initialised

(gvim:30325): GLib-GObject-WARNING **: Attempt to add property GnomeProgram::default-icon after class was initialised
Comment 16 ptomblin 2014-04-30 13:00:11 UTC
Is this a duplicate of https://bugs.kde.org/show_bug.cgi?id=333639 ? It looks similar - Okular crashing, XRANDR disabled, xinerama.
Comment 17 Eugene Shalygin 2014-04-30 13:15:34 UTC
Thanks,  this is certainly a bug either in libkscreen, which shall detect disabled RandR. Can you, please. (temporaly) remove libkscreen RandR plugins from /usr/lib64/kde4/plugins/kscreen/ and check whether it helps?
Comment 18 Albert Astals Cid 2014-04-30 13:17:35 UTC
Eugene, no need to carry on, i know what's wrong, need a patch to okular and another to libkscreen, will post them this evening or tomorrow.
Comment 19 Michael Chalvatzis 2014-04-30 13:22:32 UTC
I'm affected by the symptoms described by ptomblin, too.
I do not have the mentioned directory on my system at all but I still do have the problem:

okular linux_ct2-4400_ct2-4500ci_ct2-4650ci.pdf 
Xlib:  extension "RANDR" missing on display ":0".
Xlib:  extension "RANDR" missing on display ":0".
Xlib:  extension "RANDR" missing on display ":0".
Can't get XRandR version 
okular: Fatal IO error: client killed

Thanks, Michael

(In reply to comment #17)
> Thanks,  this is certainly a bug either in libkscreen, which shall detect
> disabled RandR. Can you, please. (temporaly) remove libkscreen RandR plugins
> from /usr/lib64/kde4/plugins/kscreen/ and check whether it helps?
Comment 20 Albert Astals Cid 2014-05-01 11:32:50 UTC
Wokring on the patches
Comment 21 Albert Astals Cid 2014-05-03 11:50:43 UTC
So i've commited patches to both libkscreen and okular to fix this. The okular fix will be there in 4.13.1, the libkscreen one, not sure, unfortunately you need both for this to work, i'll try to harass the libkscreen guys to do a release soon.
Comment 22 ptomblin 2014-05-03 12:44:59 UTC
Do you know if your libkscreen patch fixes https://bugs.kde.org/show_bug.cgi?id=331784? That might help get them to hurry up.
Comment 23 Albert Astals Cid 2014-05-03 15:30:41 UTC
I have no idea.
Comment 24 Albert Astals Cid 2014-05-06 17:40:28 UTC
*** Bug 334415 has been marked as a duplicate of this bug. ***
Comment 25 ptomblin 2014-05-13 11:36:11 UTC
Thanks to a comment in another bug report, I've discovered that `KSCREEN_BACKEND=Fake okular foo.pdf` works as a workaround while waiting for this bug fix to actually get into libkscreen.
Comment 26 Rob 2014-05-16 21:24:06 UTC
Created attachment 86672 [details]
New crash information added by DrKonqi

okular (0.19.0) on KDE Platform 4.13.0 using Qt 4.8.6

- What I was doing when the application crashed:

Simply trying to open a PDF file.  I have tried with multiple PDFs, and they all respond the same way.

-- Backtrace (Reduced):
#5  QObject::thread (this=0x0) at kernel/qobject.cpp:1370
#6  0x00007fe082aee45e in KDBusConnectionPool::threadConnection() () from /usr/lib/libkdecore.so.5
[...]
#8  0x00007fe08429066a in OrgKdeKDirNotifyInterface::emitLeftDirectory(QString const&) () from /usr/lib/libkio.so.5
[...]
#11 0x00007fe081bc5509 in __run_exit_handlers (status=1, listp=0x7fe081f486c8 <__exit_funcs>, run_list_atexit=run_list_atexit@entry=true) at exit.c:82
#12 0x00007fe081bc5555 in __GI_exit (status=<optimized out>) at exit.c:104
Comment 27 Christoph Feck 2014-06-02 12:52:39 UTC
*** Bug 335698 has been marked as a duplicate of this bug. ***
Comment 28 ptomblin 2014-07-30 14:24:36 UTC
Why is this marked as fixed when it's still happening? As far as I can tell, the problems with libkscreen aren't fixed in 1.0.4, which is the latest released version.
Comment 29 Albert Astals Cid 2014-07-30 18:05:54 UTC
Well, they seem to be fixed to me, what problem are you having exactly?
Comment 30 ptomblin 2014-07-30 18:23:33 UTC
Well, I'm still getting the exact same errors (unless I set KSCREEN_BACKEND=Fake), but maybe your fix hasn't been pushed to Kubuntu's repos yet? The comments on https://bugs.kde.org/show_bug.cgi?id=331784 indicate that libkscreen 1.0.4 doesn't fix it and there isn't a 1.0.5 yet.
Comment 31 Albert Astals Cid 2014-07-30 19:33:33 UTC
Yeah you're right, libkscreen still crashes, it's still a libscreen bug, nothing "to fix" in okular
Comment 32 ptomblin 2014-07-30 19:42:01 UTC
I guess that's the age-old question - is a bug fixed when you've fixed your part, or is it fixed when the reported behaviour stops happening.