aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Pages: [1] 2

Author Topic: aMule r10874 freeze  (Read 11693 times)

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
aMule r10874 freeze
« on: September 14, 2015, 08:23:06 PM »

Hi,
I'm using aMule svn built on debian stretch (actual testing). Follow details:
aMule svn r10874
gcc 5.2.1
wx 3.0.2
libcrypt 5.6.2

After 30 minutes of working deamon writes:
 2015-09-13 10:42:41: Logger.cpp(324): 10:42:41: Error: Failed to modify descriptor 8 in epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-13 10:42:56: Logger.cpp(324): 10:42:56: Error: Failed to add descriptor 8 to epoll descriptor 6 (error 17: File già esistente)

It continues to work for about 10 hours then upload drops to zero followed by download.

If you need additional testing I'm here.
Thanks for your work
Logged

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #1 on: September 15, 2015, 10:35:09 PM »

New details:
  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
 1952 avware    20   0  317180  75692  11660 R 101,0  7,5  93:07.35 amuled

..and the logfile:

!2015-09-15 20:23:16: amule.cpp(1903): Connected to Kad (ok)
 2015-09-15 20:43:12: Logger.cpp(324): 20:43:12: Error: Failed to modify descriptor 12 in epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 20:43:12: Logger.cpp(324): 20:43:12: Error: Failed to modify descriptor 12 in epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 20:43:12: Logger.cpp(324): 20:43:12: Error: Failed to unregister descriptor 12 from epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 20:43:47: Logger.cpp(324): 20:43:47: Error: Failed to unregister descriptor 12 from epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 20:50:40: ExternalConn.cpp(408): New external connection accepted
 2015-09-15 20:50:40: ExternalConn.cpp(442): Connecting client: amule-remote 0x0001
 2015-09-15 20:50:40: ExternalConn.cpp(527): Access granted.
 2015-09-15 20:50:59: ExternalConn.cpp(279): External connection closed.
 2015-09-15 20:55:18: Logger.cpp(324): 20:55:18: Error: Failed to modify descriptor 21 in epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 20:55:59: Logger.cpp(324): 20:55:59: Error: Failed to modify descriptor 15 in epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 21:01:46: Logger.cpp(324): 21:01:46: Error: Failed to unregister descriptor 21 from epoll descriptor 6 (error 2: File o directory non esistente)
 2015-09-15 21:01:47: Logger.cpp(324): 21:01:47: Error: Failed to add descriptor 21 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-15 21:01:47: Logger.cpp(324): 21:01:47: Error: Failed to add descriptor 21 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-15 21:13:51: Logger.cpp(324): 21:13:51: Error: Failed to add descriptor 21 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-15 21:13:51: Logger.cpp(324): 21:13:51: Error: Failed to add descriptor 21 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-15 21:13:51: Logger.cpp(324): 21:13:51: Error: Failed to add descriptor 21 to epoll descriptor 6 (error 17: File già esistente)
 2015-09-15 22:07:19: ExternalConn.cpp(408): New external connection accepted
 2015-09-15 22:07:19: ExternalConn.cpp(442): Connecting client: amule-remote 0x0001
 2015-09-15 22:07:19: ExternalConn.cpp(527): Access granted.
 2015-09-15 22:07:27: ExternalConn.cpp(279): External connection closed.
!2015-09-15 22:22:11: amule.cpp(1905): Connected to Kad (firewalled)
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: aMule r10874 freeze
« Reply #2 on: September 17, 2015, 07:35:48 PM »

Try compiling aMule with Boost.Asio (configure --with-boost). That should make the error disappear. aMule uses wxWidgets' networking library in a kind of non-standard way, and different wxWidgets versions (may) fail in different ways... However, for some people it just works :-)
Logged
concordia cum veritate

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #3 on: September 19, 2015, 10:28:53 AM »

Hi all,
following other informations about previous reported freeze:
(gdb) info stack
#0  0x00007f46175c2653 in epoll_wait () at ../sysdeps/unix/syscall-template.S:81
#1  0x00007f46182bb310 in wxEpollDispatcher::DoPoll(epoll_event*, int, int) const () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#2  0x00007f46182bb373 in wxEpollDispatcher::HasPending() const () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#3  0x00007f46182c3bf0 in wxConsoleEventLoop::Pending() const () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#4  0x00007f46181c58df in wxEventLoopManual::DoRun() () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#5  0x00007f46181c56e3 in wxEventLoopBase::Run() () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#6  0x00007f461818ab76 in wxAppConsoleBase::MainLoop() () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#7  0x0000000000426bb7 in CamuleDaemonApp::OnRun (this=0x19dc740) at amuled.cpp:640
#8  0x00007f46182172b0 in wxEntry(int&, wchar_t**) () from /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#9  0x00000000004269b7 in main (argc=2, argv=0x7fff2e97ca48) at amuled.cpp:122

I also attached out of strace run on amuled process.

@GonoszTopi: thanks for tip, I will try :)
Logged

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #4 on: September 19, 2015, 11:06:22 AM »

New issue, trying to compile with boost:

avware@nas:/usr/src/amule$ ./configure --disable-monolithic --with-toolkit=base --enable-amule-daemon --with-boost
...
...
checking for <cxxabi.h> and __cxa_demangle()... yes
checking for Boost headers version >= 1.47.0... yes
checking for Boost's header version...
configure: error: invalid value: boost_major_version=

Maybe it depends to my compiler: gcc version 5.2.1 20150911 (Debian 5.2.1-17)
I found a post on github.com, suggests to use last version of boost.m4, but it never works.
Logged

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #5 on: September 19, 2015, 04:42:31 PM »

Ok a I found a little workaround,
1) I commented this line on m4/boost.m4 file: AC_MSG_ERROR([invalid value: boost_major_version='$boost_major_version'])
2) Regenerated autoconf file with: ./autogen.sh
3) Configured with boost

Compile done with gcc5, now I'm testing amuled :)
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: aMule r10874 freeze
« Reply #6 on: September 21, 2015, 05:02:20 AM »

What Boost version are you using?
Logged
concordia cum veritate

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #7 on: September 21, 2015, 07:32:50 PM »

What Boost version are you using?
It should be 1.58 (i'm on debian testing/stretch):

root@nas:~# dpkg-query --list | grep boost
ii  libboost-system-dev:amd64            1.58.0.1                          amd64        Operating system (e.g. diagnostics support) library (default version)
ii  libboost-system1.58-dev:amd64        1.58.0+dfsg-3                     amd64        Operating system (e.g. diagnostics support) library
ii  libboost-system1.58.0:amd64          1.58.0+dfsg-3                     amd64        Operating system (e.g. diagnostics support) library
ii  libboost1.58-dev:amd64               1.58.0+dfsg-3                     amd64        Boost C++ Libraries development files
ii  libtype-tiny-xs-perl                 0.012-1                           amd64        boost for some of Type::Tiny's built-in type constraints
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: aMule r10874 freeze
« Reply #8 on: September 22, 2015, 01:15:43 PM »

Ok, I'll look into the problem (why it fails to properly detect the version number).
Logged
concordia cum veritate

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #9 on: September 22, 2015, 08:48:47 PM »

Ok, I'll look into the problem (why it fails to properly detect the version number).
thanks man,
so far no problem after 12 hours of continuous use 8)
Logged

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #10 on: September 22, 2015, 11:21:22 PM »

Maybe it can be useful, I found it in logfile:

Assertion failed: BaseClient.cpp:ProcessPublicKeyPacket:2143: Assertion 'Assert failure' failed.
Backtrace follows:
[3] wxOnAssert(char const*, int, char const*, char const*, char const*) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f569e4a]
[4] CUpDownClient::ProcessPublicKeyPacket(unsigned char const*, unsigned int) in BaseClient.cpp:2143
[5] CClientTCPSocket::ProcessExtPacket(unsigned char const*, unsigned int, unsigned char) in ClientTCPSocket.cpp:1325
[6] CClientTCPSocket::PacketReceived(CPacket*) in ClientTCPSocket.cpp:1987
[7] CEMSocket::OnReceive(int) in EMSocket.cpp:275
[8] CClientTCPSocket::OnReceive(int) in ClientTCPSocket.cpp:1897
[9] MuleNotify::LibSocketReceive(CLibSocket*, int) in LibSocketAsio.cpp:1464
[10] MuleNotify::CMuleNotifier2<CLibSocket*, int>::Notify() const in GuiEvents.h:295
[11] MuleNotify::CMuleGUIEvent::Notify() const in GuiEvents.h:368
[12] CamuleApp::OnNotifyEvent(MuleNotify::CMuleGUIEvent&) in amule.cpp:1363
[13] wxAppConsoleBase::CallEventHandler(wxEvtHandler*, wxEventFunctor&, wxEvent&) const in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f56870e]
[14] wxEvtHandler::ProcessEventIfMatchesId(wxEventTableEntryBase const&, wxEvtHandler*, wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6ee967]
[15] wxEventHashTable::HandleEvent(wxEvent&, wxEvtHandler*) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eea5b]
[16] wxEvtHandler::TryHereOnly(wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eee18]
[17] wxEvtHandler::ProcessEventLocally(wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eeea3]
[18] wxEvtHandler::ProcessEvent(wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eef05]
[19] wxEvtHandler::ProcessPendingEvents() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6ef98a]
[20] wxAppConsoleBase::ProcessPendingEvents() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f56a827]
[21] wxEventLoopManual::ProcessEvents() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5aa88c]
[22] wxEventLoopManual::DoRun() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5aa968]
[23] wxEventLoopBase::Run() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5aa6e3]
[24] wxAppConsoleBase::MainLoop() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f56fb76]
[25] CamuleDaemonApp::OnRun() in amuled.cpp:640
[26] wxEntry(int&, wchar_t**) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5fc2b0]
[27] main in amuled.cpp:122
[28] __libc_start_main in /lib/x86_64-linux-gnu/libc.so.6[0x7ff23e8e2b45]
[29] _start in :0

Assertion failed: BaseClient.cpp:ProcessSignaturePacket:2169: Assertion 'Assert failure' failed.
Backtrace follows:
[3] wxOnAssert(char const*, int, char const*, char const*, char const*) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f569e4a]
[4] CUpDownClient::ProcessSignaturePacket(unsigned char const*, unsigned int) in BaseClient.cpp:2169
[5] CClientTCPSocket::ProcessExtPacket(unsigned char const*, unsigned int, unsigned char) in ClientTCPSocket.cpp:1337
[6] CClientTCPSocket::PacketReceived(CPacket*) in ClientTCPSocket.cpp:1987
[7] CEMSocket::OnReceive(int) in EMSocket.cpp:275
[8] CClientTCPSocket::OnReceive(int) in ClientTCPSocket.cpp:1897
[9] MuleNotify::LibSocketReceive(CLibSocket*, int) in LibSocketAsio.cpp:1464
[10] MuleNotify::CMuleNotifier2<CLibSocket*, int>::Notify() const in GuiEvents.h:295
[11] MuleNotify::CMuleGUIEvent::Notify() const in GuiEvents.h:368
[12] CamuleApp::OnNotifyEvent(MuleNotify::CMuleGUIEvent&) in amule.cpp:1363
[13] wxAppConsoleBase::CallEventHandler(wxEvtHandler*, wxEventFunctor&, wxEvent&) const in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f56870e]
[14] wxEvtHandler::ProcessEventIfMatchesId(wxEventTableEntryBase const&, wxEvtHandler*, wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6ee967]
[15] wxEventHashTable::HandleEvent(wxEvent&, wxEvtHandler*) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eea5b]
[16] wxEvtHandler::TryHereOnly(wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eee18]
[17] wxEvtHandler::ProcessEventLocally(wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eeea3]
[18] wxEvtHandler::ProcessEvent(wxEvent&) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6eef05]
[19] wxEvtHandler::ProcessPendingEvents() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f6ef98a]
[20] wxAppConsoleBase::ProcessPendingEvents() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f56a827]
[21] wxEventLoopManual::ProcessEvents() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5aa88c]
[22] wxEventLoopManual::DoRun() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5aa968]
[23] wxEventLoopBase::Run() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5aa6e3]
[24] wxAppConsoleBase::MainLoop() in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f56fb76]
[25] CamuleDaemonApp::OnRun() in amuled.cpp:640
[26] wxEntry(int&, wchar_t**) in /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0[0x7ff23f5fc2b0]
[27] main in amuled.cpp:122
[28] __libc_start_main in /lib/x86_64-linux-gnu/libc.so.6[0x7ff23e8e2b45]
[29] _start in :0

!2015-09-22 22:09:22: BaseClient.cpp(455): Client 4882 still linked in 1 places: CUpDownClient::Safe_Delete reflocker, copy ctor of copy ctor of copy ctor of copy ctor of CClientList::AddClient m_hashList.insert,
 2015-09-22 22:09:22: BaseClient.cpp(3003): Last reference to client 4882 0x0000000004bbc600 unlinked, delete it.
Logged

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #11 on: September 26, 2015, 08:59:09 AM »

Hi,
I'm trying to understand what is the cause of assertion failed.

I changed these files:

#add signature to updownclient.h
void CUpDownClient::WriteLogPacketInfo(const byte* pachPacket, uint32 nSize)

#add procedure to BaseClient.cpp
void CUpDownClient::WriteLogPacketInfo(const byte* pachPacket, uint32 nSize)
{
            if (m_socket == NULL)
            {
                AddLogLineC(wxT("Socket is NULL"));
            }
            if (credits == NULL)
            {
                AddLogLineC(wxT("Credits is NULL"));
            }
            if (pachPacket[0] != nSize-1)
            {
                AddLogLineC(wxT("Packet size mismatch"));
            }
            if (nSize == 0)
            {
                AddLogLineC(wxT("Packet size is zero"));
            }
            if (nSize > 250)
            {
                AddLogLineC(wxT("Packet size greater than 250"));
            }
}

Row 2143 of BaseClient.cpp: add call to procedure
        if (m_socket == NULL || credits == NULL || pachPacket[0] != nSize-1
                || nSize == 0 || nSize > 250){
                WriteLogPacketInfo(pachPacket, nSize); <--
                wxFAIL;
                return;
        }
       
Row 2169 of BaseClient.cpp add call to procedure
        if (m_socket == NULL || credits == NULL || pachPacket[0] != nSize-1
                || nSize == 0 || nSize > 250){
                WriteLogPacketInfo(pachPacket, nSize); <--
                wxFAIL;
                return;
        }

I write a little more to see if it is a crashing bug or not.
Logged

avware

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
Re: aMule r10874 freeze
« Reply #12 on: September 26, 2015, 06:36:07 PM »

All stacktraces are caused by:
!2015-09-26 16:19:10: BaseClient.cpp(2227): Packet size mismatch
!2015-09-26 16:19:10: BaseClient.cpp(2235): Packet size greater than 250

Maybe it's better don't write to the log in these two cases?
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: aMule r10874 freeze
« Reply #13 on: October 02, 2015, 10:21:38 AM »

New issue, trying to compile with boost:

avware@nas:/usr/src/amule$ ./configure --disable-monolithic --with-toolkit=base --enable-amule-daemon --with-boost
...
...
checking for <cxxabi.h> and __cxa_demangle()... yes
checking for Boost headers version >= 1.47.0... yes
checking for Boost's header version...
configure: error: invalid value: boost_major_version=

Maybe it depends to my compiler: gcc version 5.2.1 20150911 (Debian 5.2.1-17)
I found a post on github.com, suggests to use last version of boost.m4, but it never works.

Ok, I don't know what the error was - it might be some Debian-specific change, or I don't know. For the error details config.log should have been examined.
Code: [Select]
checking for Boost headers version >= 1.47.0... /tmp/boost_1_58_0
checking for Boost's header version... 1_58
Logged
concordia cum veritate

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: aMule r10874 freeze
« Reply #14 on: October 02, 2015, 10:24:05 AM »

All stacktraces are caused by:
!2015-09-26 16:19:10: BaseClient.cpp(2227): Packet size mismatch
!2015-09-26 16:19:10: BaseClient.cpp(2235): Packet size greater than 250

Maybe it's better don't write to the log in these two cases?

Which leaves us with two cases: either a bogus client sends invalid packets, or there's something strange going on inside aMule.
Logged
concordia cum veritate
Pages: [1] 2