Mysql database 1400 + tables, slow to create new tables

there is a database for storing user behavior data, which has been divided into more than 1450 tables, and the amount of data in it is so large that the command line use database cannot be accessed for a long time. However, it is very fast to configure host and account password database names with nodejs code, and then create connections, and you can quickly list data tables with code query ("show tables").

now the problem is that creating a new sub-table is very slow, extremely slow, how to solve it?

Mar.17,2021

then change the configured table_cache from 512 to 2000

Menu