Need info about FreeBSD and interrupted system calls for MySQL code

Joerg Bruehe joerg at mysql.com
Thu Apr 29 18:32:06 UTC 2010


Hi Groggy (whom I didn't contact for too long a time), everybody,


following the advice on your page, I include the FreeBSD list, even
though I'm not subscribed there (hoping it will allow me to post) -
so please, whoever replies, could you please cc: me directly?

Of course, I tried Google, but I didn't find any answers to my question.


For some long, unknown time, the MySQL code contains a variable
"net_retry_count" which is by default set to 10 (ten) for all platforms,
but to 1000000 (1 million) for FreeBSD (during configure phase).

The source code comment about this variable reads
       If a read on a communication port is interrupted, retry this
       many times before giving up.

The documentation (manual) has this sentence in addition:
       This value should be set quite high on FreeBSD because internal
       interrupts are sent to all threads.


I read that as
"On FreeBSD, a thread may receive many more interrupts than on other
platforms, so an operation which may take some time (like network I/O)
may be interrupted much more often than on other platforms, and hence
the retry count should be higher."

I trust that this comment was valid at the time it was written -
is it still true for current versions of FreeBSD, or did things change?


Thanks for all your hints,
Jörg

-- 
Joerg Bruehe,  MySQL Build Team,  Joerg.Bruehe at Sun.COM
               (+49 30) 417 01 487
Sun Microsystems GmbH,   Komturstrasse 18a,   D-12099 Berlin
Geschaeftsfuehrer: Juergen Kunz
Amtsgericht Muenchen: HRB161028



More information about the freebsd-questions mailing list