Bug 300850 - Amarok freeze when collection is scanned
Summary: Amarok freeze when collection is scanned
Status: RESOLVED DUPLICATE of bug 281312
Alias: None
Product: amarok
Classification: Applications
Component: Collections/Local (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: 2.6
Assignee: Amarok Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-30 07:45 UTC by Andy Kelk
Modified: 2012-06-04 07:33 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andy Kelk 2012-05-30 07:45:19 UTC
Just installed Fedora 17 KDE Spin (previously I was using Kubuntu 12.04).

I have around 75Gb of music on an external USB drive (mounted under /media). I have set this to be my collection location in Amarok. When Amarok tries to scan the collection, the user interface freezes. The currently playing track finishes and no new tracks start.

Reproducible: Always

Steps to Reproduce:
1. Start Amarok
2. Wait for collection scan to activate

Actual Results:  
UI freezes

Expected Results:  
Scan happens in background, UI remains responsive.

Here's a gdb bt on the amarok process:

#0  __lll_lock_wait () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:136
#1  0x0000003ee1a09c71 in _L_lock_889 () from /lib64/libpthread.so.0
#2  0x0000003ee1a09b8a in __pthread_mutex_lock (mutex=0x282ab20) at pthread_mutex_lock.c:86
#3  0x0000003eede03526 in FAMPending () from /lib64/libfam.so.0
#4  0x0000003eed9174c0 in KDirWatchPrivate::famEventReceived (this=0x29c0470) at /usr/src/debug/kdelibs-4.8.3/kdecore/io/kdirwatch.cpp:1509
#5  0x0000003ee9f8c07f in QMetaObject::activate (sender=0x2964950, m=<optimized out>, local_signal_index=<optimized out>, argv=0x7fff9cd7c5c0)
    at kernel/qobject.cpp:3547
#6  0x0000003ee9fd547e in QSocketNotifier::activated (this=<optimized out>, _t1=61) at .moc/release-shared/moc_qsocketnotifier.cpp:102
#7  0x0000003ee9f9258b in QSocketNotifier::event (this=0x2964950, e=0x7fff9cd7cbe0) at kernel/qsocketnotifier.cpp:317
#8  0x0000003eeebca47c in QApplicationPrivate::notify_helper (this=this@entry=0x1d7de30, receiver=receiver@entry=0x2964950, e=e@entry=0x7fff9cd7cbe0)
    at kernel/qapplication.cpp:4554
#9  0x0000003eeebce9aa in QApplication::notify (this=0x7fff9cd7f100, receiver=0x2964950, e=0x7fff9cd7cbe0) at kernel/qapplication.cpp:4415
#10 0x0000003ef0a45a56 in KApplication::notify (this=0x7fff9cd7f100, receiver=0x2964950, event=0x7fff9cd7cbe0)
    at /usr/src/debug/kdelibs-4.8.3/kdeui/kernel/kapplication.cpp:311
#11 0x0000003ee9f7593e in QCoreApplication::notifyInternal (this=0x7fff9cd7f100, receiver=0x2964950, event=0x7fff9cd7cbe0) at kernel/qcoreapplication.cpp:876
#12 0x0000003ee9fa31d8 in sendEvent (event=0x7fff9cd7cbe0, receiver=<optimized out>) at kernel/qcoreapplication.h:231
#13 socketNotifierSourceDispatch (source=source@entry=0x1c27380) at kernel/qeventdispatcher_glib.cpp:110
#14 0x0000003ee36475cc in g_main_dispatch (context=0x1d74500) at gmain.c:2515
#15 g_main_context_dispatch (context=context@entry=0x1d74500) at gmain.c:3052
#16 0x0000003ee36479e8 in g_main_context_iterate (context=context@entry=0x1d74500, block=block@entry=1, dispatch=dispatch@entry=1, 
    self=<error reading variable: Unhandled dwarf expression opcode 0xfa>) at gmain.c:3123
#17 0x0000003ee3647aa4 in g_main_context_iteration (context=0x1d74500, may_block=1) at gmain.c:3184
#18 0x0000003ee9fa39c6 in QEventDispatcherGlib::processEvents (this=0x1beac50, flags=...) at kernel/qeventdispatcher_glib.cpp:424
#19 0x0000003eeec6a3ee in QGuiEventDispatcherGlib::processEvents (this=<optimized out>, flags=...) at kernel/qguieventdispatcher_glib.cpp:207
#20 0x0000003ee9f7493f in QEventLoop::processEvents (this=this@entry=0x7fff9cd7ce20, flags=...) at kernel/qeventloop.cpp:149
#21 0x0000003ee9f74bc8 in QEventLoop::exec (this=0x7fff9cd7ce20, flags=...) at kernel/qeventloop.cpp:204
#22 0x0000003ee9f796f8 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1148
#23 0x0000000000408cba in main (argc=1, argv=0x7fff9cd7f268) at /usr/src/debug/amarok-2.5.0/src/main.cpp:303
Comment 1 Andy Kelk 2012-05-30 09:09:17 UTC
It's possible this could be related to bug 281312, however the workarounds suggested there have not helped in this case.
Comment 2 Myriam Schweingruber 2012-05-31 18:29:27 UTC
And which exact Amarok version is this about?
Comment 3 Myriam Schweingruber 2012-05-31 18:32:53 UTC
(In reply to comment #1)
> It's possible this could be related to bug 281312, however the workarounds
> suggested there have not helped in this case.

You did try the workaround in https://bugs.kde.org/show_bug.cgi?id=281312#c14 more specifically?
Comment 4 Andy Kelk 2012-06-04 03:34:48 UTC
Have set the max_user_watches to a high number. Yet it seems that KDirWatch is still using FAM.

~$ sudo sysctl -p
[...]
fs.inotify.max_user_watches = 524288


When running amarok, here's some relevant (I think) lines:

amarok(9908)/kio (KDirWatch) KDirWatchPrivate::KDirWatchPrivate: INotify available:  true
[...]
amarok(9908)/kio (KDirWatch) KDirWatchPrivate::addEntry: Added Dir "/media/My Passport/mp3/Classical/ABC Classic FM - Life Is Beautiful Disc 1" for "" ["KDirWatch-2"]
amarok(9908)/kio (KDirWatch) KDirWatchPrivate::useFAM:  Setup FAM (Req 1) for "/media/My Passport/mp3/Classical/ABC Classic FM - Life Is Beautiful Disc 1"

Version info:
Amarok Version 2.5.0
Using KDE 4.8.3 (4.8.3)

amarok.x86_64                  2.5.0-9.fc17
kdelibs.x86_64                 6:4.8.3-1.fc17
Comment 5 Myriam Schweingruber 2012-06-04 07:33:27 UTC
It is the same bug nonetheless

*** This bug has been marked as a duplicate of bug 281312 ***