Hi,
I use Evictor to freeze the user's hint message, the number of users is about 100,000 and each user can contain max 100 messages. If one user gets a new message, the oldest message will be removed if the number of messages exceeds the limit. In general, each user can receive about 50-80 messages per day. The message will be mark read if the user has read it.
In this case, the Evictor often add/remove message, update message's stat, so its saving thread is busy in saving database, This causes the process takes about 99% cpu resource, I have set DB_CONFIG file:
set_cachesize 0 1073741824 1
set_lk_max_lockers 20000
set_lk_max_locks 20000
set_lk_max_objects 20000
set_tx_max 20000
set_lg_bsize 2097152
set_lg_max 2097152
set_flags DB_TXN_NOSYNC
set_flags DB_TXN_WRITE_NOSYNC
And set DbEnv's property:
<property name="Freeze.DbEnv.PnlDispatchNew.CheckpointPeriod " value="600"/>
I assure the max servant's size is less than 4k(the default Bdb's page size), so there are not dirty pages in Bdb's database file.
I trace the Evictor's log, and find that saving transaction is so slowly. There are 4 transaction log in Bdb's env directory.
I think the Evictor is a very good component and I am like to use it. I believe that the Evictor could deal with it perfect, but I don't know how to tune it. I cry for your kindness to help me resovle this problem!
Thanks.

Reply With Quote
