Optimization paramters read-only mysql 5.7 database? What's the best way to configure a MySQL database that is only read-only, and will never have any modifications made to it?

1) I have increased my innodb_buffer_pool_size to 70% of available RAM

2) Increase query cache size to 40mb

Running against a load generator, after some time the database starts bottlenecking to only 1000 statements per second.

The configuration is 2-cores, 8GB ram 50GB SSD. The database contains a single InnoDB 13 GB table with the same exact query running on two indexed columns.

We are using a vertx server to hit the database. The symptom we see is that the web service performance degrades after 15-20 minutes of heavy load.

Where can the bottleneck be? What parameters should we optimize?
I can think of several things that might help.  But I can't be specific without seeing that query, plus SHOW CREATE TABLE.

If we can shrink the table/index size, there might be less I/O.  If the index involves a UUID, then I will have lots to say.

Sometimes rearranging the index(es) helps.

If you are not using InnoDB, we need to discuss that.

Let's see SHOW GLOBAL STATUS; and SHOW VARIABLES; -- there are some metrics that will say how well the Query cache is doing, info about connections, whether the buffer_pool is adequately big, plus other things that might give clues.

In general, "you can't tune your way out of a performance problem."

For "readonly", add this to the config file:

read_only = ON


but I doubt if it will impact the performance.