Debian Bug report logs - #719582
libdbd-firebird-perl: hangs in t/embed-80-event-ithreads.t

version graph

Package: libdbd-firebird-perl; Maintainer for libdbd-firebird-perl is Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>; Source for libdbd-firebird-perl is src:libdbd-firebird-perl (PTS, buildd, popcon).

Reported by: Niko Tyni <ntyni@debian.org>

Date: Tue, 13 Aug 2013 09:45:02 UTC

Severity: serious

Tags: confirmed

Found in version libdbd-firebird-perl/1.11-1

Fixed in version libdbd-firebird-perl/1.14-1

Done: Damyan Ivanov <dmn@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>:
Bug#719582; Package libdbd-firebird-perl. (Tue, 13 Aug 2013 09:45:06 GMT) (full text, mbox, link).


Acknowledgement sent to Niko Tyni <ntyni@debian.org>:
New Bug report received and forwarded. Copy sent to Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>. (Tue, 13 Aug 2013 09:45:06 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Niko Tyni <ntyni@debian.org>
To: submit@bugs.debian.org
Subject: libdbd-firebird-perl: FTBFS on mipsel: 300 minutes of inactivity
Date: Tue, 13 Aug 2013 12:39:57 +0300
Package: libdbd-firebird-perl
Version: 1.11-1
Severity: serious

From the mipsel build log at
 https://buildd.debian.org/status/fetch.php?pkg=libdbd-firebird-perl&arch=mipsel&ver=1.11-1&stamp=1368908033

  t/embed-70-nested-sth.t ......... ok
  t/embed-75-utf8.t ............... ok
  make[1]: *** wait: No child processes.  Stop.
  make[1]: *** Waiting for unfinished jobs....
  make[1]: *** wait: No child processes.  Stop.
  make: *** wait: No child processes.  Stop.
  make: *** Waiting for unfinished jobs....
  make: *** wait: No child processes.  Stop.
  E: Caught signal 'Terminated': terminating immediately
  Build killed with signal TERM after 300 minutes of inactivity
 
Other "slow" architectures took about 10 minutes to build this, so there
seems to be a real problem somewhere here.
-- 
Niko Tyni   ntyni@debian.org



Added indication that bug 719582 blocks 712615 Request was from Niko Tyni <ntyni@debian.org> to control@bugs.debian.org. (Tue, 13 Aug 2013 12:51:15 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>:
Bug#719582; Package libdbd-firebird-perl. (Sat, 07 Sep 2013 20:27:04 GMT) (full text, mbox, link).


Message #10 received at 719582@bugs.debian.org (full text, mbox, reply):

From: Damyan Ivanov <dmn@debian.org>
To: 719582@bugs.debian.org, perl@packages.debian.org
Subject: Re: Bug#719582: libdbd-firebird-perl: FTBFS on mipsel: 300 minutes of inactivity
Date: Sat, 7 Sep 2013 23:23:16 +0300
[Message part 1 (text/plain, inline)]
Control: tags -1 confirmed
Control: retitle -1 libdbd-firebird-perl: hangs in t/embed-80-event-ithreads.t

-=| Niko Tyni, 13.08.2013 12:39:57 +0300 |=-
> Package: libdbd-firebird-perl
> Version: 1.11-1
> Severity: serious
> 
> From the mipsel build log at
>  https://buildd.debian.org/status/fetch.php?pkg=libdbd-firebird-perl&arch=mipsel&ver=1.11-1&stamp=1368908033
> 
>   t/embed-70-nested-sth.t ......... ok
>   t/embed-75-utf8.t ............... ok
>   make[1]: *** wait: No child processes.  Stop.
>   make[1]: *** Waiting for unfinished jobs....
>   make[1]: *** wait: No child processes.  Stop.
>   make: *** wait: No child processes.  Stop.
>   make: *** Waiting for unfinished jobs....
>   make: *** wait: No child processes.  Stop.
>   E: Caught signal 'Terminated': terminating immediately
>   Build killed with signal TERM after 300 minutes of inactivity
>  
> Other "slow" architectures took about 10 minutes to build this, so there
> seems to be a real problem somewhere here.

I managed to reproduce this on eder.d.o (mipsel) and on my laptop 
(amd64). The test needs to be run several times for the hang to 
happen.

The test that fails waits for asynchronous database event posted by 
another thread.

I doubt this bug is specific to perl 5.18, so perhaps there is no need 
to block the transition? Also, I uploaded the result from a successful 
build to the archive.

dam,
    continuing investigation
[signature.asc (application/pgp-signature, inline)]

Added tag(s) confirmed. Request was from Damyan Ivanov <dmn@debian.org> to 719582-submit@bugs.debian.org. (Sat, 07 Sep 2013 20:27:04 GMT) (full text, mbox, link).


Changed Bug title to 'libdbd-firebird-perl: hangs in t/embed-80-event-ithreads.t' from 'libdbd-firebird-perl: FTBFS on mipsel: 300 minutes of inactivity' Request was from Damyan Ivanov <dmn@debian.org> to 719582-submit@bugs.debian.org. (Sat, 07 Sep 2013 20:27:05 GMT) (full text, mbox, link).


Removed indication that bug 719582 blocks 712615 Request was from Dominic Hargreaves <dom@earth.li> to control@bugs.debian.org. (Sat, 07 Sep 2013 21:36:09 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>:
Bug#719582; Package libdbd-firebird-perl. (Sun, 08 Sep 2013 07:39:04 GMT) (full text, mbox, link).


Message #19 received at 719582@bugs.debian.org (full text, mbox, reply):

From: Damyan Ivanov <dmn@debian.org>
To: 719582@bugs.debian.org
Cc: dbd-firebird-devel@lists.alioth.debian.org
Subject: Re: Bug#719582: libdbd-firebird-perl: FTBFS on mipsel: 300 minutes of inactivity
Date: Sun, 8 Sep 2013 10:37:48 +0300
[Message part 1 (text/plain, inline)]
Control: tags -1 pending

-=| Damyan Ivanov, 07.09.2013 23:23:16 +0300 |=-
> I managed to reproduce this on eder.d.o (mipsel) and on my laptop 
> (amd64). The test needs to be run several times for the hang to 
> happen.
> 
> The test that fails waits for asynchronous database event posted by 
> another thread.

I have found the reason for this.

What the test does is the following:

 * start a worker thread that connects to the DB and performs some 
   event-triggering operations, then disconnects and quits.

 * in the main thread, call ib_wait_event capturing the triggered 
   events

The nature of the ib_wait_event call is that it stops execution, 
waiting for events to come, synchronously. Usually, the main thread 
manages to reach the ib_wait_event call before the worker thread 
starts posting events. However, sometimes the worker thread is run 
before the main thread, and does all of its job before the main thread 
reaches ib_wait_event, meaning that the events that ib_wait_event 
wants to see never come and the test hangs at the ib_wait_event call. 
I believe this is exactly what happens in this test when it hangs. To 
make it reproducible, add a small sleep before calling ib_wait_event.

Ideally, we should suspend the worker thread and resume it only when 
the main thread has called ib_wait_event. However, because of the 
synchronous nature of ib_wait_event, this is not possible (this is not 
firebird fault, there is an asynchronous interface which we also test 
earlier in that test and which works).

My first idea for fixing this was to add a small delay in the worker 
thread, giving time to the main thread to reach ib_wait_event before 
starting triggering events. This seems to work at first glance, but 
fails even with a 5 seconds delay when the system is heavily loaded 
(for example by a -j5 build of firebird server on a 4 CPU laptop).

My next idea is to skip these sub-tests when AUTOMATED_TESTING is 
present in the environment, which is the case when the Debian package 
is building.

If somebody has other ideas, please shout.
[signature.asc (application/pgp-signature, inline)]

Added tag(s) pending. Request was from Damyan Ivanov <dmn@debian.org> to 719582-submit@bugs.debian.org. (Sun, 08 Sep 2013 07:39:04 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>:
Bug#719582; Package libdbd-firebird-perl. (Sun, 08 Sep 2013 07:54:04 GMT) (full text, mbox, link).


Message #24 received at 719582@bugs.debian.org (full text, mbox, reply):

From: Damyan Ivanov <dmn@debian.org>
To: 719582@bugs.debian.org
Cc: dbd-firebird-devel@lists.alioth.debian.org
Subject: Re: Bug#719582: libdbd-firebird-perl: FTBFS on mipsel: 300 minutes of inactivity
Date: Sun, 8 Sep 2013 10:50:13 +0300
[Message part 1 (text/plain, inline)]
-=| Damyan Ivanov, 08.09.2013 10:37:48 +0300 |=-
> My next idea is to skip these sub-tests when AUTOMATED_TESTING is 
> present in the environment, which is the case when the Debian 
> package is building.

Heh, the 80-event-ithreads.t and 81-event-fork.t are already skipped 
when DBD_FIREBIRD_TEST_SKIP_EVENTS is present in the environment, and 
the package defined that on armel, ia64, kfreebsd-amd64, kfreebsd-i386 
and s390. :)

Still, asynchronous testing seems worth testing and should be reliable 
independent of the system load, so I'll rework that.
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>:
Bug#719582; Package libdbd-firebird-perl. (Mon, 09 Sep 2013 13:45:05 GMT) (full text, mbox, link).


Message #27 received at 719582@bugs.debian.org (full text, mbox, reply):

From: pkg-perl-maintainers@lists.alioth.debian.org
To: 719582@bugs.debian.org, 719582-submitter@bugs.debian.org
Subject: Pending fixes for bugs in the libdbd-firebird-perl package
Date: Mon, 09 Sep 2013 13:42:50 +0000
tag 719582 + pending
thanks

Some bugs in the libdbd-firebird-perl package are closed in revision
3bb18ce94a50147fa0ab0f3d6374847e3e07dffb in branch 'master' by Damyan
Ivanov

The full diff can be seen at
http://anonscm.debian.org/gitweb/?p=pkg-perl/packages/libdbd-firebird-perl.git;a=commitdiff;h=3bb18ce

Commit message:

    export environment vars disabling certain tests on certain bad platforms
    
    AUTOMATED_TESTING disabled thread-based test of ib_wait_event, as this
    test cannot be guaranteed to succeed with overloaded host
    
    DBD_FIREBIRD_TEST_SKIP_EVENTS_FORK disabled fork-involving event tests
    on kfreebsd platforms, as on them firebird uses semaphores for
    synchronisation and there appears to be a problem with that
    (semop in parent after child has destroyed the semaphore)
    
    Closes: #719582 -- hangs in t/embed-80-event-ithreads.t




Message sent on to Niko Tyni <ntyni@debian.org>:
Bug#719582. (Mon, 09 Sep 2013 13:45:11 GMT) (full text, mbox, link).


Reply sent to Damyan Ivanov <dmn@debian.org>:
You have taken responsibility. (Mon, 09 Sep 2013 13:51:30 GMT) (full text, mbox, link).


Notification sent to Niko Tyni <ntyni@debian.org>:
Bug acknowledged by developer. (Mon, 09 Sep 2013 13:51:30 GMT) (full text, mbox, link).


Message #35 received at 719582-close@bugs.debian.org (full text, mbox, reply):

From: Damyan Ivanov <dmn@debian.org>
To: 719582-close@bugs.debian.org
Subject: Bug#719582: fixed in libdbd-firebird-perl 1.14-1
Date: Mon, 09 Sep 2013 13:49:33 +0000
Source: libdbd-firebird-perl
Source-Version: 1.14-1

We believe that the bug you reported is fixed in the latest version of
libdbd-firebird-perl, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 719582@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Damyan Ivanov <dmn@debian.org> (supplier of updated libdbd-firebird-perl package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Mon, 09 Sep 2013 16:38:08 +0300
Source: libdbd-firebird-perl
Binary: libdbd-firebird-perl
Architecture: source amd64
Version: 1.14-1
Distribution: unstable
Urgency: low
Maintainer: Debian Perl Group <pkg-perl-maintainers@lists.alioth.debian.org>
Changed-By: Damyan Ivanov <dmn@debian.org>
Description: 
 libdbd-firebird-perl - Perl DBI driver for Firebird RDBMS server
Closes: 719582
Changes: 
 libdbd-firebird-perl (1.14-1) unstable; urgency=low
 .
   * New upstream release
   * export environment vars disabling fragile tests and certain tests on
     certain bad platforms.
     (Closes: #719582)
Checksums-Sha1: 
 8c11124c1ffca796139458cf8888ee8f2f27978d 2202 libdbd-firebird-perl_1.14-1.dsc
 4b4317940faf090b6c67af2d1f5e84b3cc7f5e82 100855 libdbd-firebird-perl_1.14.orig.tar.gz
 79409f5ceb4a4beddcc1c35c6c90d657bafd931c 3167 libdbd-firebird-perl_1.14-1.debian.tar.gz
 69b9c2bf98e5730a66dbd64b6670b5a5147a6041 98254 libdbd-firebird-perl_1.14-1_amd64.deb
Checksums-Sha256: 
 bbdc7172765081878d0a23ab9b7f9433aaf6065e9b65c66057fc92793fd5c0d8 2202 libdbd-firebird-perl_1.14-1.dsc
 b5db91d5aa52536bb8b29e513fc4882f5be12f1f3a6d00ab050237fb3fcdd61a 100855 libdbd-firebird-perl_1.14.orig.tar.gz
 a69853d119b2b321417e282e70d33ecfc62842b17850bc3a1d11900227542fef 3167 libdbd-firebird-perl_1.14-1.debian.tar.gz
 8b996422d4e4f12464549783f4a76896c98474daf17facfc2b5d58f08a5eeeae 98254 libdbd-firebird-perl_1.14-1_amd64.deb
Files: 
 9ecfa9a7d75d4b00373873c355dcafea 2202 perl optional libdbd-firebird-perl_1.14-1.dsc
 0168762beba8a6501b29238ac70ef0b1 100855 perl optional libdbd-firebird-perl_1.14.orig.tar.gz
 b0bc6c76dacf23e40f48b5d33f0be20e 3167 perl optional libdbd-firebird-perl_1.14-1.debian.tar.gz
 c0f8ea1e789b7c0a71fc63139a422110 98254 perl optional libdbd-firebird-perl_1.14-1_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (GNU/Linux)

iQIcBAEBCAAGBQJSLdAaAAoJENu+nU2Z0qAE4OgP/jSpJGAchHcConaYwNO38G23
RxQ/Uq5q2pYShjSPDIC3CVOaaMtrBlwnuxaKKYmta3d+lU6wEI6WvFa/8aSqLIhW
C0ZtEM2Bd/SXUWdnYvdg4a+0uX8vI3KJ5pa6IXa9/OxB2gmmMzUh2YAlHut2mTOr
hi4HLlG9f3whCdLB2RyaV9PdrF/o7O2jBdVqjDz6kITyz0VZyuqZFsoobtjfbT/r
caFYLGv6C8wdNNAbBmb909Tqv9X/DyfxKqv8fwhGvX9WEvvL5tf1cK3xls6wRikT
nliJK1SuDLXBG76KX2MitZVmfp0wsjrz+sFSankSa0aL61sJ9sApHGNVXaEPi5RA
5+dTvYxlKF+ky3s68Y8T3yxMTPcyg35EVQwgOIjwaARuWa3Q36tZj48sWF7C8O2y
dpfG/W6h5KS3u/BWSdcqtxOx7O0j6uHf12+zKB6mKgSenuzRfHvz3i+joC3/4oEj
h29e4C2hewPYDH6qIxcnGG0KYedt8xXwhaTUDt2UB5RorFNmiUBSlzQiMf6CExBw
Em1gS97P2oIoz7mQg07kQeaGxBGT+a60xMHLXk6BbCYtPnuiF+MParCk03TTbYGh
xNXnajeNTcxk1nRJM4NlCircZ+irfz1tzHbFkKAMdLdXiODK8D0QaLXlDO/aq+7a
lahoOK3BuuG9x2oWnH3E
=hSR8
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Tue, 08 Oct 2013 07:35:46 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Aug 23 11:40:24 2023; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.