deluged dies when adding torrent

General support for problems installing or using Deluge
Post Reply
clarknova
Member
Member
Posts: 37
Joined: Tue Sep 16, 2008 5:24 am

deluged dies when adding torrent

Post by clarknova »

I recently upgraded deluge from 0.5.8.x to 1.0.x for the headless functionality :ugeek:

Unfortunately when I try to add a torrent from the web ui, it often crashes deluged. This by itself would be a minor annoyance, but it also appears that after a crash my download loses progress. I had a file downloading and was at 23% when deluged died. When I restarted and reconnected my ui it was at 9%. A few crashes later and it is now at 8%.

I can reproduce a crash 100% of the time:
1. Create ssh tunnel to home gateway with dynamic port forwarding, aka, socks proxy
2. Start deluged on home gateway via ssh
3. "deluge --ui web &" via ssh
4. Configure browser to use ssh/socks proxy
5. Point browser to home gateway via private IP address
6. Click "add torrent"
7. Use browse button to select torrent file on client machine (data exists on server, I'm attempting to seed).
8. Click "submit"

I have 8 or ten torrent files on the client machine with data ready to seed from the deluged server. One of these torrent files crashed deluged 4 or 5 times in a row using the above procedure. I did manage to add 4 other torrents for seeding and crashed deluged 2 or 3 times in the process, so 2 or 3 out of the four torrents crashed deluged on first per-torrent attempt but not the second.

Here's a second similar method to crash deluged 100% of the time:
a. Add torrent files to apache2 web server root on localhost (same machine and IP that deluged is running on)
b. Follow steps 1-6 from above method
c. Paste URL of torrent file into URL box. You can use http://localhost:8080/path/to/file.torrent or http://192.168.1.1:8080/*.torrent or http://FQDN:8080/*.torrent The result is the same. apache is running on non-standard port.
d. Click Submit

This will crash deluged for me every time After 6 or so attempts I quit trying to add torrents via the URL method.

Let me know if I should submit a logfile or something to help track this down. I'm pretty new to version 1 so still trying to figure out where all the files are kept.

db
db
andar
Top Bloke
Top Bloke
Posts: 1050
Joined: Fri Jun 08, 2007 8:38 pm
Location: Victoria, BC
Contact:

Re: deluged dies when adding torrent

Post by andar »

clarknova wrote:I recently upgraded deluge from 0.5.8.x to 1.0.x for the headless functionality :ugeek:

Unfortunately when I try to add a torrent from the web ui, it often crashes deluged. This by itself would be a minor annoyance, but it also appears that after a crash my download loses progress. I had a file downloading and was at 23% when deluged died. When I restarted and reconnected my ui it was at 9%. A few crashes later and it is now at 8%.

I can reproduce a crash 100% of the time:
1. Create ssh tunnel to home gateway with dynamic port forwarding, aka, socks proxy
2. Start deluged on home gateway via ssh
3. "deluge --ui web &" via ssh
4. Configure browser to use ssh/socks proxy
5. Point browser to home gateway via private IP address
6. Click "add torrent"
7. Use browse button to select torrent file on client machine (data exists on server, I'm attempting to seed).
8. Click "submit"

I have 8 or ten torrent files on the client machine with data ready to seed from the deluged server. One of these torrent files crashed deluged 4 or 5 times in a row using the above procedure. I did manage to add 4 other torrents for seeding and crashed deluged 2 or 3 times in the process, so 2 or 3 out of the four torrents crashed deluged on first per-torrent attempt but not the second.

Here's a second similar method to crash deluged 100% of the time:
a. Add torrent files to apache2 web server root on localhost (same machine and IP that deluged is running on)
b. Follow steps 1-6 from above method
c. Paste URL of torrent file into URL box. You can use http://localhost:8080/path/to/file.torrent or http://192.168.1.1:8080/*.torrent or http://FQDN:8080/*.torrent The result is the same. apache is running on non-standard port.
d. Click Submit

This will crash deluged for me every time After 6 or so attempts I quit trying to add torrents via the URL method.

Let me know if I should submit a logfile or something to help track this down. I'm pretty new to version 1 so still trying to figure out where all the files are kept.

db
I have just fixed an issue with the add_torrent_url() method in svn.. I've changed the method to run in a thread to prevent blocking of the main daemon thread and thus hopefully prevent 'freezing'.

I suspect the other issues you are experiencing could have to do with the data checking that the torrent goes through when first added.. There still seems to be some bugs there and we're working to track them down.. What would help is if you can get a full stacktrace when the daemon crashes/hangs so that we can see why the disk io thread is locking.

How to get full backtrace:

Code: Select all

$ gdb --args python /usr/bin/deluged -d
(gdb) run
<crash/hang, may need to crtl+c>
(gdb) bt full
Thanks!
clarknova
Member
Member
Posts: 37
Joined: Tue Sep 16, 2008 5:24 am

Re: deluged dies when adding torrent

Post by clarknova »

I removed my .config/deluge folder right before running deluged and deluge just to be sure I was starting with a clean config. Then I added my favourite crash-torrent via 'Browse' and she didn't disappoint. Bon apetit.

db

Code: Select all

(gdb) bt full
#0  0x00007f2912816e2c in boost::filesystem::basic_path<std::string, boost::filesystem::path_traits>::operator/= ()
   from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#1  0x00007f2912a22e42 in boost::python::objects::make_holder<1>::apply<boost::python::objects::pointer_holder<boost::intrusive_ptr<libtorrent::torrent_info>, libtorrent::torrent_info>, boost::mpl::vector1<char const*> >::execute ()
   from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#2  0x00007f2912a1c2d0 in boost::python::objects::caller_py_function_impl<boost::python::detail::caller<void (*)(_object*, char const*), boost::python::default_call_policies, boost::mpl::vector3<void, _object*, char const*> > >::operator() () from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#3  0x00007f2911d90abe in boost::python::objects::function::call ()
   from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
No symbol table info available.
#4  0x00007f2911d90de8 in ?? () from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
No symbol table info available.
#5  0x00007f29129b368e in boost::function0<void, std::allocator<boost::function_base> >::operator() ()
   from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#6  0x00007f2911d989f8 in boost::python::handle_exception_impl ()
   from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
No symbol table info available.
#7  0x00007f2911d8e127 in ?? () from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
---Type <return> to continue, or q <return> to quit---
No symbol table info available.
#8  0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#9  0x000000000041e66f in ?? ()
No symbol table info available.
#10 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#11 0x000000000045ac98 in ?? ()
No symbol table info available.
#12 0x000000000045ca81 in ?? ()
No symbol table info available.
#13 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#14 0x000000000048617a in PyEval_EvalFrameEx ()
No symbol table info available.
#15 0x000000000048a406 in PyEval_EvalCodeEx ()
No symbol table info available.
#16 0x00000000004d528a in ?? ()
No symbol table info available.
#17 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#18 0x000000000041e66f in ?? ()
No symbol table info available.
---Type <return> to continue, or q <return> to quit---
#19 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#20 0x0000000000482052 in PyEval_CallObjectWithKeywords ()
No symbol table info available.
#21 0x00007f291566bf9f in ?? () from /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so
No symbol table info available.
#22 0x00007f2914d813d4 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#23 0x00007f2914d846e5 in ?? () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#24 0x00007f2914d84a05 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#25 0x00007f2915677705 in ?? () from /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so
No symbol table info available.
#26 0x0000000000488b18 in PyEval_EvalFrameEx ()
No symbol table info available.
#27 0x0000000000488c07 in PyEval_EvalFrameEx ()
No symbol table info available.
#28 0x000000000048a406 in PyEval_EvalCodeEx ()
No symbol table info available.
#29 0x00000000004d528a in ?? ()
No symbol table info available.
#30 0x0000000000417e33 in PyObject_Call ()
---Type <return> to continue, or q <return> to quit---
No symbol table info available.
#31 0x000000000041e66f in ?? ()
No symbol table info available.
#32 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#33 0x0000000000482052 in PyEval_CallObjectWithKeywords ()
No symbol table info available.
#34 0x0000000000422273 in PyInstance_New ()
No symbol table info available.
#35 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#36 0x000000000048617a in PyEval_EvalFrameEx ()
No symbol table info available.
#37 0x0000000000488c07 in PyEval_EvalFrameEx ()
No symbol table info available.
#38 0x000000000048a406 in PyEval_EvalCodeEx ()
No symbol table info available.
#39 0x000000000048a522 in PyEval_EvalCode ()
No symbol table info available.
#40 0x00000000004abe2e in PyRun_FileExFlags ()
No symbol table info available.
#41 0x00000000004ac0c9 in PyRun_SimpleFileExFlags ()
No symbol table info available.
---Type <return> to continue, or q <return> to quit---
#42 0x00000000004145ad in Py_Main ()
No symbol table info available.
#43 0x00007f2916b201c4 in __libc_start_main () from /lib/libc.so.6
No symbol table info available.
#44 0x0000000000413b29 in _start ()
No symbol table info available.
db
andar
Top Bloke
Top Bloke
Posts: 1050
Joined: Fri Jun 08, 2007 8:38 pm
Location: Victoria, BC
Contact:

Re: deluged dies when adding torrent

Post by andar »

clarknova wrote:I removed my .config/deluge folder right before running deluged and deluge just to be sure I was starting with a clean config. Then I added my favourite crash-torrent via 'Browse' and she didn't disappoint. Bon apetit.

db

Code: Select all

(gdb) bt full
#0  0x00007f2912816e2c in boost::filesystem::basic_path<std::string, boost::filesystem::path_traits>::operator/= ()
   from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#1  0x00007f2912a22e42 in boost::python::objects::make_holder<1>::apply<boost::python::objects::pointer_holder<boost::intrusive_ptr<libtorrent::torrent_info>, libtorrent::torrent_info>, boost::mpl::vector1<char const*> >::execute ()
   from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#2  0x00007f2912a1c2d0 in boost::python::objects::caller_py_function_impl<boost::python::detail::caller<void (*)(_object*, char const*), boost::python::default_call_policies, boost::mpl::vector3<void, _object*, char const*> > >::operator() () from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#3  0x00007f2911d90abe in boost::python::objects::function::call ()
   from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
No symbol table info available.
#4  0x00007f2911d90de8 in ?? () from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
No symbol table info available.
#5  0x00007f29129b368e in boost::function0<void, std::allocator<boost::function_base> >::operator() ()
   from /var/lib/python-support/python2.5/deluge/libtorrent.so
No symbol table info available.
#6  0x00007f2911d989f8 in boost::python::handle_exception_impl ()
   from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
No symbol table info available.
#7  0x00007f2911d8e127 in ?? () from /usr/lib/libboost_python-gcc42-1_34_1.so.1.34.1
---Type <return> to continue, or q <return> to quit---
No symbol table info available.
#8  0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#9  0x000000000041e66f in ?? ()
No symbol table info available.
#10 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#11 0x000000000045ac98 in ?? ()
No symbol table info available.
#12 0x000000000045ca81 in ?? ()
No symbol table info available.
#13 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#14 0x000000000048617a in PyEval_EvalFrameEx ()
No symbol table info available.
#15 0x000000000048a406 in PyEval_EvalCodeEx ()
No symbol table info available.
#16 0x00000000004d528a in ?? ()
No symbol table info available.
#17 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#18 0x000000000041e66f in ?? ()
No symbol table info available.
---Type <return> to continue, or q <return> to quit---
#19 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#20 0x0000000000482052 in PyEval_CallObjectWithKeywords ()
No symbol table info available.
#21 0x00007f291566bf9f in ?? () from /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so
No symbol table info available.
#22 0x00007f2914d813d4 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#23 0x00007f2914d846e5 in ?? () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#24 0x00007f2914d84a05 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#25 0x00007f2915677705 in ?? () from /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so
No symbol table info available.
#26 0x0000000000488b18 in PyEval_EvalFrameEx ()
No symbol table info available.
#27 0x0000000000488c07 in PyEval_EvalFrameEx ()
No symbol table info available.
#28 0x000000000048a406 in PyEval_EvalCodeEx ()
No symbol table info available.
#29 0x00000000004d528a in ?? ()
No symbol table info available.
#30 0x0000000000417e33 in PyObject_Call ()
---Type <return> to continue, or q <return> to quit---
No symbol table info available.
#31 0x000000000041e66f in ?? ()
No symbol table info available.
#32 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#33 0x0000000000482052 in PyEval_CallObjectWithKeywords ()
No symbol table info available.
#34 0x0000000000422273 in PyInstance_New ()
No symbol table info available.
#35 0x0000000000417e33 in PyObject_Call ()
No symbol table info available.
#36 0x000000000048617a in PyEval_EvalFrameEx ()
No symbol table info available.
#37 0x0000000000488c07 in PyEval_EvalFrameEx ()
No symbol table info available.
#38 0x000000000048a406 in PyEval_EvalCodeEx ()
No symbol table info available.
#39 0x000000000048a522 in PyEval_EvalCode ()
No symbol table info available.
#40 0x00000000004abe2e in PyRun_FileExFlags ()
No symbol table info available.
#41 0x00000000004ac0c9 in PyRun_SimpleFileExFlags ()
No symbol table info available.
---Type <return> to continue, or q <return> to quit---
#42 0x00000000004145ad in Py_Main ()
No symbol table info available.
#43 0x00007f2916b201c4 in __libc_start_main () from /lib/libc.so.6
No symbol table info available.
#44 0x0000000000413b29 in _start ()
No symbol table info available.
Thanks for the backtrace.. But could you possibly send me the torrent file too?
clarknova
Member
Member
Posts: 37
Joined: Tue Sep 16, 2008 5:24 am

Re: deluged dies when adding torrent

Post by clarknova »

The torrent is on my laptop which I don't have handy. I re-downloaded the torrent and it added via the web ui just fine. Go figure. The torrent file on the laptop must be corrupted I'm guessing. Do you want it anyway? Seems like a torrent, even a bad one, shouldn't crash the program. I'll pm it to you Monday.

db
db
clarknova
Member
Member
Posts: 37
Joined: Tue Sep 16, 2008 5:24 am

Re: deluged dies when adding torrent

Post by clarknova »

For the record:
There was a bug in the libtorrent python bindings that this torrent
exposed. I have fixed it.
db
db
Post Reply