Subject Re: [firebird-support] LockSemCount
Author Michael Weissenbacher
Hi Tom!
Well, i've used the following information sources:
http://ibdeveloper.com/issues/issue-2-oct-17-2005/locking-firebird-and-the-lock-table/
http://www.idevelopment.info/data/Oracle/DBA_tips/Linux/LINUX_8.shtml
http://forums.devshed.com/firebird-sql-development-61/tuning-firebird-database-for-large-db-on-dualxeon-with-2gbt-202214.html

Frankly, i cannot remember how exatly i arrived at those values. I conducted some load tests and settled for them after i saw my locking problems go away. I think the default values for the lock manager are pretty low for today's powerful hardware.

hth,
Michael


-------- Original-Nachricht --------
Betreff: Re: [firebird-support] LockSemCount
Von: Tom Munro Glass <tom@...>
An: firebird-support@yahoogroups.com
Datum: 29.07.2009 23:39

> Hi Michael,
>
> Thanks for the information. Clearly LockSemCount = 500 is significantly higher
> than the default value of 32 - how did you arrive at this value? I'd really
> like to know what factors should be considered when changing this value - can
> any of the Firebird developers explain the significance of this?
>
> Tom
>
> On Wed, 29 Jul 2009 20:59:16 Michael Weissenbacher wrote:
>> Hi Tom!
>> I have been running a heavily loaded Firebird Classic 2.0 on a (Gentoo)
>> Linux Server for about 3 years without a hitch with the following settings:
>> firebird.conf:
>> LockSemCount = 500
>>
>> /etc/sysctl.conf:
>> kernel.shmmax = 1073741824
>> kernel.sem = 1024 32000 256 1024
>>
>> /etc/xinetd.d/firebird:
>> service gds_db
>> {
>> disable = no
>> flags = NODELAY KEEPALIVE IPV4
>> socket_type = stream
>> wait = no
>> user = firebird
>> server = /opt/firebird/bin/fb_inet_server
>> cps = 0 0
>> instances = 1000
>> per_source = 300
>> log_type = FILE /var/log/firebird/xinetd.firebird.log
>> }
>>
>>
>> I had some problems in the start with the Lock Manager, before increasing
>> the default values. Another important thing are the "instances" and "cps"
>> settings of xinetd, which may prevent new connections under certain
>> circumstances.
>>
>> hth,
>> Michael
>>
>> -------- Original-Nachricht --------
>> Betreff: [firebird-support] LockSemCount
>> Von: Tom Munro Glass <tom@...>
>> An: firebird-support@yahoogroups.com
>> Datum: 28.07.2009 06:35
>>
>>> Running FB classic 2.1.2.18118 on Mandriva 2009 with an unmodified
>>> firebird.conf.
>>>
>>> I have had a corrupted database, and prior to this firebird.log contains
>>> the "Fatal lock manager error: semaphores are exhausted" message. The
>>> system would only have had one or two users connected at the time, so can
>>> someone please tell me what operations cause a semaphore to be used? For
>>> example is the number of semaphores used affected by the number of active
>>> transactions, and does running nbackup use any semaphores?
>>>
>>> Also, does this message mean that FB has used all of semaphores as
>>> determined by LockSemCount (default 32 I assume) or does it mean that
>>> Linux has run out of semaphores?
>>>
>>> I'm trying to determine if I need to increase the value of LockSemCount,
>>> and if so, what should I increase it to.
>>>
>>> Tom Munro Glass
>>>
>>>
>>>
>
>
>
> ------------------------------------
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Visit http://www.firebirdsql.org and click the Resources item
> on the main (top) menu. Try Knowledgebase and FAQ links !
>
> Also search the knowledgebases at http://www.ibphoenix.com
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> Yahoo! Groups Links
>
>
>
>