Bug 344741 - Dolphin freezes while displayed files' content are modified
Summary: Dolphin freezes while displayed files' content are modified
Status: RESOLVED FIXED
Alias: None
Product: kio
Classification: Unmaintained
Component: general (other bugs)
Version First Reported In: 4.14.1
Platform: Arch Linux Linux
: NOR major
Target Milestone: ---
Assignee: David Faure
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-03-02 12:24 UTC by tesfabpel
Modified: 2018-05-08 17:39 UTC (History)
3 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tesfabpel 2015-03-02 12:24:20 UTC
If any of the files displayed by Dolphin is modified, Dolphin freezes for some seconds.
The situation appears clearly when you download a large file (like a Live DVD iso).

Reproducible: Always

Steps to Reproduce:
1. Open the Download folder in Dolphin
2. Start downloading a large file

Actual Results:  
Dolphin begins to freeze and unlocks after some seconds

Expected Results:  
Dolphin should not freeze
Comment 1 Frank Reininghaus 2015-03-02 20:28:44 UTC
Thanks for the bug report! Do you use previews and/or the Information Panel? Does the problem persist if you change that?

It would be great if you could try to get a backtrace at the time of the crash, see https://community.kde.org/Dolphin/FAQ/Freeze

Thanks for your help.
Comment 2 tesfabpel 2015-03-05 19:40:36 UTC
I use previews but no information panel.
(Note: maybe this bug is more obvious if the download speed is high)
Here's the backtrace: (I don't have Qt symbols though...)


Program received signal SIGTSTP, Stopped (user).
0x00007ffff786b1b3 in select () from /usr/lib/libc.so.6
(gdb) thread apply all backtrace

Thread 4 (Thread 0x7fffd81d1700 (LWP 9434)):
#0  0x00007ffff78694ed in poll () from /usr/lib/libc.so.6
#1  0x00007fffee4df9a4 in ?? () from /usr/lib/libglib-2.0.so.0
#2  0x00007fffee4dfabc in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#3  0x00007ffff46c8397 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#4  0x00007ffff4697de1 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#5  0x00007ffff4698145 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#6  0x00007ffff458c7f9 in QThread::exec() () from /usr/lib/libQtCore.so.4
#7  0x00007ffff46786c3 in ?? () from /usr/lib/libQtCore.so.4
#8  0x00007ffff458f05f in ?? () from /usr/lib/libQtCore.so.4
#9  0x00007fffefa59374 in start_thread () from /usr/lib/libpthread.so.0
#10 0x00007ffff787227d in clone () from /usr/lib/libc.so.6

Thread 3 (Thread 0x7fffd7979700 (LWP 9435)):
#0  0x00007ffff78694ed in poll () from /usr/lib/libc.so.6
#1  0x00007fffee4df9a4 in ?? () from /usr/lib/libglib-2.0.so.0
#2  0x00007fffee4dfabc in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#3  0x00007ffff46c8397 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#4  0x00007ffff4697de1 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#5  0x00007ffff4698145 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#6  0x00007ffff458c7f9 in QThread::exec() () from /usr/lib/libQtCore.so.4
#7  0x00007ffff458f05f in ?? () from /usr/lib/libQtCore.so.4
#8  0x00007fffefa59374 in start_thread () from /usr/lib/libpthread.so.0
#9  0x00007ffff787227d in clone () from /usr/lib/libc.so.6

---Type <return> to continue, or q <return> to quit---
Thread 2 (Thread 0x7fffd65a6700 (LWP 9442)):                                                                                                                                                                       
#0  0x00007ffff786b1b3 in select () from /usr/lib/libc.so.6                                                                                                                                                        
#1  0x00007ffff4674e31 in ?? () from /usr/lib/libQtCore.so.4                                                                                                                                                       
#2  0x00007ffff458f05f in ?? () from /usr/lib/libQtCore.so.4                                                                                                                                                       
#3  0x00007fffefa59374 in start_thread () from /usr/lib/libpthread.so.0                                                                                                                                            
#4  0x00007ffff787227d in clone () from /usr/lib/libc.so.6                                                                                                                                                         
                                                                                                                                                                                                                   
Thread 1 (Thread 0x7ffff7f8b800 (LWP 9430)):                                                                                                                                                                       
#0  0x00007ffff786b1b3 in select () from /usr/lib/libc.so.6                                                                                                                                                        
#1  0x00007ffff46c5429 in qt_safe_select(int, fd_set*, fd_set*, fd_set*, timeval const*) ()                                                                                                                        
   from /usr/lib/libQtCore.so.4                                                                                                                                                                                    
#2  0x00007ffff467153c in ?? () from /usr/lib/libQtCore.so.4                                                                                                                                                       
#3  0x00007ffff4672f85 in ?? () from /usr/lib/libQtCore.so.4                                                                                                                                                       
#4  0x00007ffff4627282 in QProcess::waitForFinished(int) () from /usr/lib/libQtCore.so.4                                                                                                                           
#5  0x00007ffff5c9a2a7 in ?? () from /usr/lib/libkio.so.5                                                                                                                                                          
#6  0x00007ffff5c9af29 in ?? () from /usr/lib/libkio.so.5                                                                                                                                                          
#7  0x00007ffff5c9b1c6 in ?? () from /usr/lib/libkio.so.5                                                                                                                                                          
#8  0x00007ffff5c9bf23 in ?? () from /usr/lib/libkio.so.5                                                                                                                                                          
#9  0x00007ffff46add9c in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) ()                                                                                                                      
   from /usr/lib/libQtCore.so.4                                                                                                                                                                                    
#10 0x00007ffff4b17122 in KDirWatch::dirty(QString const&) () from /usr/lib/libkdecore.so.5                                                                                                                        
#11 0x00007ffff46b2491 in QObject::event(QEvent*) () from /usr/lib/libQtCore.so.4                                                                                                                                  
#12 0x00007ffff376e9ac in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4                                                                                                     
#13 0x00007ffff3775408 in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4                                                                                                                   
#14 0x00007ffff513925a in KApplication::notify(QObject*, QEvent*) () from /usr/lib/libkdeui.so.5                                                                                                                   
#15 0x00007ffff469928d in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4                                                                                                      
#16 0x00007ffff469c651 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) ()                                                                                                                
   from /usr/lib/libQtCore.so.4                                                                                                                                                                                    
#17 0x00007ffff46c8233 in ?? () from /usr/lib/libQtCore.so.4                                                                                                                                                       
#18 0x00007fffee4df71d in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
---Type <return> to continue, or q <return> to quit---
#19 0x00007fffee4dfa08 in ?? () from /usr/lib/libglib-2.0.so.0
#20 0x00007fffee4dfabc in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#21 0x00007ffff46c837d in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#22 0x00007ffff38123a6 in ?? () from /usr/lib/libQtGui.so.4
#23 0x00007ffff4697de1 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#24 0x00007ffff4698145 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#25 0x00007ffff469d6e9 in QCoreApplication::exec() () from /usr/lib/libQtCore.so.4
#26 0x00007ffff7b806be in kdemain () from /usr/lib/libkdeinit4_dolphin.so
#27 0x00007ffff77aa800 in __libc_start_main () from /usr/lib/libc.so.6
#28 0x000000000040070e in _start ()
Comment 3 Frank Reininghaus 2015-03-05 21:51:40 UTC
Thanks for the backtrace. It freezes in KIO. Your backtrace is missing some details in the KIO frames though. Maybe you could get a better backtrace by installing debugging symbols for KIO or all of kdelibs (depending on what your distro provides).
Comment 4 tesfabpel 2015-03-06 09:28:02 UTC
Ok, I've rerun gdb with kdelibs with debug symbols installed (I'm on Archlinux so I had to recompile the package from ABS with debug and strip options)...
Now the backtrace says something about KSambaShare, but that seems weird since I'm downloading the file using wget into a local directory on a NTFS volume and not in a network folder... (Maybe the backtrace is not useful?)

Here it is, anyway:

Program received signal SIGTSTP, Stopped (user).
0x00007ffff786b1b3 in select () from /usr/lib/libc.so.6
(gdb) thread apply all backtrace

Thread 4 (Thread 0x7fffd7741700 (LWP 13483)):
#0  0x00007ffff78694ed in poll () from /usr/lib/libc.so.6
#1  0x00007fffedfbd9a4 in ?? () from /usr/lib/libglib-2.0.so.0
#2  0x00007fffedfbdabc in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#3  0x00007ffff46bb397 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#4  0x00007ffff468ade1 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#5  0x00007ffff468b145 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#6  0x00007ffff457f7f9 in QThread::exec() () from /usr/lib/libQtCore.so.4
#7  0x00007ffff466b6c3 in ?? () from /usr/lib/libQtCore.so.4
#8  0x00007ffff458205f in ?? () from /usr/lib/libQtCore.so.4
#9  0x00007fffef537374 in start_thread () from /usr/lib/libpthread.so.0
#10 0x00007ffff787227d in clone () from /usr/lib/libc.so.6

Thread 3 (Thread 0x7fffd6ee9700 (LWP 13484)):
#0  0x00007ffff78694ed in poll () from /usr/lib/libc.so.6
#1  0x00007fffedfbd9a4 in ?? () from /usr/lib/libglib-2.0.so.0
#2  0x00007fffedfbdabc in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#3  0x00007ffff46bb397 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#4  0x00007ffff468ade1 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#5  0x00007ffff468b145 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#6  0x00007ffff457f7f9 in QThread::exec() () from /usr/lib/libQtCore.so.4
#7  0x00007ffff458205f in ?? () from /usr/lib/libQtCore.so.4
#8  0x00007fffef537374 in start_thread () from /usr/lib/libpthread.so.0
#9  0x00007ffff787227d in clone () from /usr/lib/libc.so.6

---Type <return> to continue, or q <return> to quit---
Thread 2 (Thread 0x7fffd5ad7700 (LWP 13490)):
#0  0x00007ffff786b1b3 in select () from /usr/lib/libc.so.6
#1  0x00007ffff4667e31 in ?? () from /usr/lib/libQtCore.so.4
#2  0x00007ffff458205f in ?? () from /usr/lib/libQtCore.so.4
#3  0x00007fffef537374 in start_thread () from /usr/lib/libpthread.so.0
#4  0x00007ffff787227d in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0x7ffff7f89800 (LWP 13478)):
#0  0x00007ffff786b1b3 in select () from /usr/lib/libc.so.6
#1  0x00007ffff46b8429 in qt_safe_select(int, fd_set*, fd_set*, fd_set*, timeval const*) ()
   from /usr/lib/libQtCore.so.4
#2  0x00007ffff466453c in ?? () from /usr/lib/libQtCore.so.4
#3  0x00007ffff4665f85 in ?? () from /usr/lib/libQtCore.so.4
#4  0x00007ffff461a282 in QProcess::waitForFinished(int) () from /usr/lib/libQtCore.so.4
#5  0x00007ffff5c919a7 in KSambaSharePrivate::runProcess (progName=..., args=..., stdOut=..., stdErr=...)
    at /tmp/debugkde/kdelibs/src/kdelibs-4.14.5/kio/kio/ksambashare.cpp:117
#6  0x00007ffff5c92629 in KSambaSharePrivate::getNetUserShareInfo (this=this@entry=0x10d3990)
    at /tmp/debugkde/kdelibs/src/kdelibs-4.14.5/kio/kio/ksambashare.cpp:173
#7  0x00007ffff5c928c6 in KSambaSharePrivate::sync (this=this@entry=0x10d3990)
    at /tmp/debugkde/kdelibs/src/kdelibs-4.14.5/kio/kio/ksambashare.cpp:376
#8  0x00007ffff5c93623 in KSambaSharePrivate::_k_slotFileChange (this=0x10d3990, path=...)
    at /tmp/debugkde/kdelibs/src/kdelibs-4.14.5/kio/kio/ksambashare.cpp:429
#9  0x00007ffff46a0d9c in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) ()
   from /usr/lib/libQtCore.so.4
#10 0x00007ffff4b0a3e2 in KDirWatch::dirty (this=<optimized out>, _t1=...)
    at /tmp/debugkde/kdelibs/src/build/kdecore/kdirwatch.moc:112
#11 0x00007ffff46a5491 in QObject::event(QEvent*) () from /usr/lib/libQtCore.so.4
#12 0x00007ffff37619ac in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#13 0x00007ffff3768408 in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#14 0x00007ffff512d6fa in KApplication::notify (this=0x7fffffffddc0, receiver=0x8957a0, event=0x121e850)
---Type <return> to continue, or q <return> to quit---
    at /tmp/debugkde/kdelibs/src/kdelibs-4.14.5/kdeui/kernel/kapplication.cpp:311
#15 0x00007ffff468c28d in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4
#16 0x00007ffff468f651 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) ()
   from /usr/lib/libQtCore.so.4
#17 0x00007ffff46bb233 in ?? () from /usr/lib/libQtCore.so.4
#18 0x00007fffedfbd71d in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#19 0x00007fffedfbda08 in ?? () from /usr/lib/libglib-2.0.so.0
#20 0x00007fffedfbdabc in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#21 0x00007ffff46bb37d in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#22 0x00007ffff38053a6 in ?? () from /usr/lib/libQtGui.so.4
#23 0x00007ffff468ade1 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/lib/libQtCore.so.4
#24 0x00007ffff468b145 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#25 0x00007ffff46906e9 in QCoreApplication::exec() () from /usr/lib/libQtCore.so.4
#26 0x00007ffff7b806be in kdemain () from /usr/lib/libkdeinit4_dolphin.so
#27 0x00007ffff77aa800 in __libc_start_main () from /usr/lib/libc.so.6
#28 0x000000000040070e in _start ()
(gdb)
Comment 5 Frank Reininghaus 2015-03-07 12:08:43 UTC
Thanks for the quick reply and the detailed backtrace!

(In reply to tesfabpel from comment #4)
> Now the backtrace says something about KSambaShare, but that seems weird
> since I'm downloading the file using wget into a local directory on a NTFS
> volume and not in a network folder... (Maybe the backtrace is not useful?)

The backtrace is useful. It clearly shows that KSambaShare blocks the main thread while it's waiting for an external process to finish. I cannot comment on why that happens though. Maybe someone with more knowledge about the KIO internals has an idea.
Comment 6 tesfabpel 2015-08-25 17:14:51 UTC
Hi, any news on this bug?
It is still marked as unconfirmed and it has had no updates since march...

Thanks.
Comment 7 David Faure 2015-09-28 21:10:36 UTC
How long does the command

testparm -d0 -s --parameter-name

take on your system? That's what KIO is waiting for.
Comment 8 chris27wjoyner 2015-10-13 00:07:42 UTC
I have a similar problem with Dolphin.

I use dolpin to archive a large folder, then copy to my pen drive. While it is copying Dolphin will lock up.  If I open konsole dolphin will unlock.

Reproduce: Archive a large folder. Copy or Cut the large archive to another media, such a a pen drive. Dolphin should have locked up and will not let you browse any folders.  If it is locked up, opening konsole will unlock dolphin.
Comment 9 tesfabpel 2015-12-01 21:49:50 UTC
Hi, 
this bug is still present in KIO 5.16.0 (maybe would it be the case to update the KIO version in this bug?)

I did `time testparm -d0 -s --parameter-name` and it gives:
Load smb config files from /etc/samba/smb.conf
Loaded services file OK.
Server role: ROLE_STANDALONE

# Global parameters
[global]
        server string = %h server (Samba, Ubuntu)
        server role = standalone server
        map to guest = Bad User
        obey pam restrictions = Yes
        pam password change = Yes
        passwd program = /usr/bin/passwd %u
        passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
        unix password sync = Yes
        syslog = 0
        log file = /var/log/samba/log.%m
        max log size = 1000
        dns proxy = No
        usershare allow guests = Yes
        usershare max shares = 100
        usershare owner only = No
        usershare path = /var/lib/samba/usershare
        panic action = /usr/share/samba/panic-action %d
        idmap config * : backend = tdb


[printers]
        comment = All Printers
        path = /var/spool/samba
        create mask = 0700
        printable = Yes
        browseable = No


[print$]
        comment = Printer Drivers
        path = /var/lib/samba/printers
testparm -d0 -s --parameter-name  0,02s user 0,00s system 90% cpu 0,026 total


To easily test this just update ABS (if you're on ArchLinux) while staying into the /var/abs/extra directory.
At the end of the sync (or during?) dolphin should hang for a long time...

Thanks!
Comment 10 David Faure 2016-05-14 09:52:56 UTC
That isn't the same bug then. The backtraces above were about testparm taking a long time, not 0,02s...
Do you still get a backtrace in QProcess::waitForFinished called by KSambaSharePrivate::runProcess?

I don't use ArchLinux.
Comment 11 Nate Graham 2018-05-08 17:39:53 UTC
Works for me in KDE Frameworks 5.45; can't reproduce the original bug as reported.