Registered Member
|
I've been running libktorrent rev. 1131216 and ktorrent rev. 1131908 for the last few days. When uTP was turned on, it crashed every few hours. After having three crashes I turned uTP off. It has been running without any crashes since then.
I'm not sure how to find out more about the issue, but if there's anything more I can do, I'd be happy to help. It's a bit weird, because it says "Signal: Aborted" instead of "Signal: Segfault" so I'm not exactly sure where to start digging. Greets, seth |
Moderator
|
Excellent, uncaught exceptions.
Send me your log files, they are named: log, log-1.gz, log-2.gz ... and you can find them in in ~/.kde/share/apps/ktorrent/ There should be lines in there starting with: Error thrown: <some error message> What interests me is those error messages. |
Registered Member
|
damn. the logs stored in ~/.kde4/share/apps/ktorrent only go back to May 30th, whereas the crash logs are from the 29th. I took a look at the logs and they mostly only show "Illegal token" errors, but since I haven't had any crashes in that time, it's probably worthless.
I'll compile the latest svn revision now and turn uTP back on. This time I'll be sure to save the logs before they get overwritten. |
Registered Member
|
Ok, so the crashes seem less frequent since the revision update. I'm now running libktorrent rev. 1133401 and ktorrent rev. 1133203. But I've still had three more crashes spaced out over three days. This time I made sure I had the log files you mentioned saved. Unfortunately there is no "Error thrown" message anywhere near the crash, so I've cut the last 20 seconds before the crash out of the logfile and attached those.
|
Registered Member
|
I've been experience such a crash too, as well as two other people on this bug: https://bugs.kde.org/show_bug.cgi?id=240393 .
Edit: The only errors in my logs are tracker timeouts, and seem unrelated to any crashes. |
Moderator
|
|
Registered Member
|
So, I've got some more crash reports and logs, in case they help. They're still from the same revisions as my last ones. (I've been collecting the last days ) Now I'm going to update my builds to the latest svn code. Hopefully it'll fix some bugs in the utp code.
|
Moderator
|
Upgrade to the latest, several of these things should no longer happen.
|
Registered Member
|
I've upgraded to libktorrent-svn rev. 1137933 and ktorrent-svn rev. 1137395 now and I had three crashes already. The difference is that now the logfile is showing uncaught std::bad_alloc exceptions right after initiating an UTP connection.
|
Moderator
|
std::bad_alloc's are thrown when you are running out of memory.
How much memory is KT using before it crashes ? |
Registered Member
|
Well... as far as I can tell, I'm not running out of memory. I only managed to look up the memory usage of ktorrent after it crashed though.
When the crash dialog appeared, top showed the following memory usage: (using 2GB RAM and ~2.3GB swap) 34% for crash #7 / 20100618_2 19% for crash #8 / 20100621_1 14% for crash #9 / 20100621_2 which is not even enough to fill up my RAM. Also, contrary to an out-of-memory situation, I haven't noticed any performance issues (usually caused by massive swapping of memory blocks) while using ktorrent. |
Moderator
|
Then it is probably one memory allocation which is trying to allocate a huge number of bytes, which cannot be satisfied.
Question is where. Could you run ktorrent in a debugger ? gdb --args /usr/bin/ktorrent --nofork break std::bad_alloc::bad_alloc run gdb should then break when the bad_alloc is thrown. At that point in time type: bt And a backtrace will be printed, post that here. |
Registered Member
|
Here are my results. This crash only occurs when uTP is on. It may be a different cause, but I thought this might help.
I have loaded debug symbols for the next time. $ gdb --args /usr/bin/ktorrent --nofork GNU gdb (GDB) 7.1-debian Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "i486-linux-gnu". For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>... Reading symbols from /usr/bin/ktorrent...(no debugging symbols found)...done. (gdb) break std::bad_alloc::bad_alloc Can't find member of namespace, class, struct, or union named "std::bad_alloc::bad_alloc" Hint: try 'std::bad_alloc::bad_alloc<TAB> or 'std::bad_alloc::bad_alloc<ESC-?> (Note leading single quote.) Make breakpoint pending on future shared library load? (y or [n]) y Breakpoint 1 (std::bad_alloc::bad_alloc) pending. (gdb) run Starting program: /usr/bin/ktorrent --nofork [Thread debugging using libthread_db enabled] [New Thread 0xb3d1bb70 (LWP 24168)] Warning: Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString) [Thread 0xb3d1bb70 (LWP 24168) exited] [New Thread 0xb3d1bb70 (LWP 24169)] Warning: QSocketNotifier: Invalid socket 18 and type 'Read', disabling... [New Thread 0xb33ffb70 (LWP 24170)] [New Thread 0xb0effb70 (LWP 24171)] [New Thread 0xb06feb70 (LWP 24172)] [New Thread 0xafefdb70 (LWP 24173)] [New Thread 0xaf6fcb70 (LWP 24174)] [New Thread 0xaeefbb70 (LWP 24175)] ..... Many Thread Messages deleted ..... Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0xb3d1bb70 (LWP 24169)] 0xb715a50e in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4 (gdb) bt #0 0xb715a50e in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4 #1 0xb71897b6 in ?? () from /usr/lib/libQtCore.so.4 #2 0xb71863d7 in ?? () from /usr/lib/libQtCore.so.4 #3 0xb5a9f2f5 in g_main_context_dispatch () from /lib/libglib-2.0.so.0 #4 0xb5aa2fd8 in ?? () from /lib/libglib-2.0.so.0 #5 0xb5aa31b8 in g_main_context_iteration () from /lib/libglib-2.0.so.0 #6 0xb7186095 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4 #7 0xb7158b49 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4 #8 0xb7158f9a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4 #9 0xb705b619 in QThread::exec() () from /usr/lib/libQtCore.so.4 #10 0xb7f54e7d in utp::UTPServerThread::run() () from /usr/lib/libktorrent.so.1 #11 0xb705dfae in ?? () from /usr/lib/libQtCore.so.4 #12 0xb5b78955 in start_thread (arg=0xb3d1bb70) at pthread_create.c:300 #13 0xb639610e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:130 (gdb) |
Registered Member
|
Here is the debug backtrace. This is version 4.0.1. libktorrent 1.0.1. Debian SID.
gdb --args /usr/bin/ktorrent --nofork GNU gdb (GDB) 7.1-debian Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "i486-linux-gnu". For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>... Reading symbols from /usr/bin/ktorrent...Reading symbols from /usr/lib/debug/usr/bin/ktorrent...done. done. (gdb) break std::bad_alloc::bad_alloc Can't find member of namespace, class, struct, or union named "std::bad_alloc::bad_alloc" Hint: try 'std::bad_alloc::bad_alloc<TAB> or 'std::bad_alloc::bad_alloc<ESC-?> (Note leading single quote.) Make breakpoint pending on future shared library load? (y or [n]) y Breakpoint 1 (std::bad_alloc::bad_alloc) pending. (gdb) run Starting program: /usr/bin/ktorrent --nofork [Thread debugging using libthread_db enabled] [New Thread 0xb3d1bb70 (LWP 26041)] Warning: Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString) [New Thread 0xb33ffb70 (LWP 26042)] [New Thread 0xb2bfeb70 (LWP 26043)] [Thread 0xb3d1bb70 (LWP 26041) exited] [New Thread 0xb3d1bb70 (LWP 26044)] [New Thread 0xb1a70b70 (LWP 26045)] [New Thread 0xb126fb70 (LWP 26046)] [New Thread 0xb0a6eb70 (LWP 26047)] [New Thread 0xb026db70 (LWP 26048)] [Thread 0xb026db70 (LWP 26048) exited] [Thread 0xb3d1bb70 (LWP 26044) exited] [Thread 0xb0a6eb70 (LWP 26047) exited] [New Thread 0xb0a6eb70 (LWP 26049)] [Thread 0xb126fb70 (LWP 26046) exited] [New Thread 0xb126fb70 (LWP 26050)] [New Thread 0xb3d1bb70 (LWP 26051)] [New Thread 0xb026db70 (LWP 26052)] [Thread 0xb1a70b70 (LWP 26045) exited] [Thread 0xb0a6eb70 (LWP 26049) exited] [Thread 0xb026db70 (LWP 26052) exited] [Thread 0xb126fb70 (LWP 26050) exited] [Thread 0xb3d1bb70 (LWP 26051) exited] Warning: load glyph failed err=6 face=0x8266ad8, glyph=320 Warning: QFontEngine: Glyph neither outline nor bitmap format=0 Warning: load glyph failed err=6 face=0x8266ad8, glyph=320 Warning: QFontEngine: Glyph neither outline nor bitmap format=0 Warning: load glyph failed err=6 face=0x8266ad8, glyph=320 Warning: QFontEngine: Glyph neither outline nor bitmap format=0 Warning: Calling appendChild() on a null node does nothing. Warning: Calling appendChild() on a null node does nothing. [New Thread 0xb3d1bb70 (LWP 26053)] [New Thread 0xb126fb70 (LWP 26054)] [New Thread 0xb026db70 (LWP 26055)] [New Thread 0xb0a6eb70 (LWP 26056)] [New Thread 0xac7bdb70 (LWP 26057)] [New Thread 0xabfa8b70 (LWP 26058)] [New Thread 0xab7a7b70 (LWP 26059)] [New Thread 0xaafa6b70 (LWP 26060)] [Thread 0xb126fb70 (LWP 26054) exited] [Thread 0xb0a6eb70 (LWP 26056) exited] [Thread 0xb3d1bb70 (LWP 26053) exited] [Thread 0xb026db70 (LWP 26055) exited] [Thread 0xac7bdb70 (LWP 26057) exited] [New Thread 0xac7bdb70 (LWP 26074)] [New Thread 0xb026db70 (LWP 26075)] [New Thread 0xb3d1bb70 (LWP 26076)] [New Thread 0xb0a6eb70 (LWP 26077)] Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0xb33ffb70 (LWP 26042)] 0x00000000 in ?? () (gdb) bt #0 0x00000000 in ?? () #1 0xb66a35cc in QApplicationPrivate::notify_helper (this=0x813c0c0, receiver=0x9a5d8d0, e=0xb33ff060) at kernel/qapplication.cpp:4302 #2 0xb66aa15e in QApplication::notify (this=0xbffff0c0, receiver=0x9a5d8d0, e=0xb33ff060) at kernel/qapplication.cpp:3706 #3 0x08079d1c in kt::App::notify (this=0x9a54790, receiver=0xac9b9da8, event=0x9d1e8c8) at ../../ktorrent/app.cpp:97 #4 0xb715a52b in QCoreApplication::notifyInternal (this=0xbffff0c0, receiver=0x9a5d8d0, event=0xb33ff060) at kernel/qcoreapplication.cpp:726 #5 0xb71897b6 in QCoreApplication::sendEvent (this=0x814968c) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215 #6 QTimerInfoList::activateTimers (this=0x814968c) at kernel/qeventdispatcher_unix.cpp:603 #7 0xb71863d7 in timerSourceDispatch (source=0x81422b8) at kernel/qeventdispatcher_glib.cpp:184 #8 idleTimerSourceDispatch (source=0x81422b8) at kernel/qeventdispatcher_glib.cpp:231 #9 0xb5a9f2f5 in g_main_context_dispatch () from /lib/libglib-2.0.so.0 #10 0xb5aa2fd8 in ?? () from /lib/libglib-2.0.so.0 #11 0xb5aa31b8 in g_main_context_iteration () from /lib/libglib-2.0.so.0 #12 0xb7186095 in QEventDispatcherGlib::processEvents (this=0x81f7fe8, flags=...) at kernel/qeventdispatcher_glib.cpp:412 #13 0xb7158b49 in QEventLoop::processEvents (this=0xb33ff2d0, flags=DWARF-2 expression error: DW_OP_reg operations must be used either alone or in conjuction with DW_OP_piece. ) at kernel/qeventloop.cpp:149 #14 0xb7158f9a in QEventLoop::exec (this=0xb33ff2d0, flags=...) at kernel/qeventloop.cpp:201 #15 0xb705b619 in QThread::exec (this=0x81f2718) at thread/qthread.cpp:487 #16 0xb7f54e7d in utp::UTPServerThread::run (this=0x81f2718) at ../../src/utp/utpserverthread.cpp:40 #17 0xb705dfae in QThreadPrivate::start (arg=0x81f2718) at thread/qthread_unix.cpp:248 #18 0xb5b78955 in start_thread (arg=0xb33ffb70) at pthread_create.c:300 #19 0xb639610e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:130 (gdb) |
Registered Member
|
Ok, so I did what you wrote, but I'm not sure it went as planned.
I think I need some different break condition. Also the memory usage this time was at 70% and I had two more crashes before I read your last message, with 70% and 41% memory usage. I wonder, why the usage varies that much... |
Registered users: abc72656, Bing [Bot], daret, Google [Bot], lockheed, Sogou [Bot], Yahoo [Bot]