macgyver Pan wrote:
>
> I install MySQL 4.1.7 in Solaris 9 and use JSP(using Apache+Resin 3) write a evaluation
> system program. Every user login to system and search near 250,000 data in 5 tables and write a
> few words to one of these tables.
>
> My hardware has 2 CPUS with 4 GB RAM, and I look the system utilization when more 50 users
> login , the CPU loading nears 100% and almost used by mysqld. If 1~3 users login, mysqld uses about
> 23% CPU loading.
I am definitely not a MySQL expert, but the standard advice is to index appropriately your tables. Are your sure that you have the relavant indexes built into your tables for most of your MySQL queries?
Otherwise, you should give more details, in particular about your table structures, your indexes, your typical MySQL queries, your MySQL server configuration, to get real help.
But common wisdon suggest to look into indexing issues first. A missing index may make a query run in O(n) time (where n is the size of tables), while a good index should make it run in O(log n).
Good luck.
--
Basile STARYNKEVITCH ::::
http://starynkevitch.net/Basile/