Anecdotal evidence: I'm currently using a multi-threaded perl/XS program that uses DBD::mysql 4.004 on several MP machines including an 8-core linux x86_64 box. In this program each thread (between 4 and 16 threads depending on configuration) creates and uses its own database handle.

Although there are still some issues with shutting down the program cleanly, they don't appear to be database related. In any case, it'll run just fine for days without any issues. Note that we create the threads ASAP and then keep them during the whole time the program is running.

The program doesn't really make heavy use of the database, though - most of the work is spend in fairly memory / cpu intensive calculations in the XS code, with the database acting as a dumb (single table) system to store the resulting data in).

YMMV,

Joost.


In reply to Re^4: Threading - getting better use of my MP box by Joost
in thread Threading - getting better use of my MP box by ethrbunny

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.