Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Not a Bug
-
None
-
None
-
Distro······: Debian GNU/Linux 11 (bullseye)
Kernel······: Linux 5.10.0-33-amd64
Uptime······: up 9 weeks, 3 days, 21 hours, 42 minutes
Load········: 0.03 (1m), 0.07 (5m), 0.06 (15m)
Processes···: 152 (root), 7 (user), 159 (total)
CPU·········: Intel(R) Xeon(R) Gold 6152 CPU @ 2.10GHz (4 vCPU)
Memory······: 7.8Gi used, 7.4Gi avail, 15Gi total
Distro······: Debian GNU/Linux 11 (bullseye) Kernel······: Linux 5.10.0-33-amd64 Uptime······: up 9 weeks, 3 days, 21 hours, 42 minutes Load········: 0.03 (1m), 0.07 (5m), 0.06 (15m) Processes···: 152 (root), 7 (user), 159 (total) CPU·········: Intel(R) Xeon(R) Gold 6152 CPU @ 2.10GHz (4 vCPU) Memory······: 7.8Gi used, 7.4Gi avail, 15Gi total
Description
The server consumes memory on usage on Information schema.
This server only contains MariaDB running on it.
MariaDB [(none)]> system free -h
|
total used free shared buff/cache available
|
Mem: 15Gi 6.9Gi 361Mi 109Mi 8.3Gi 8.3Gi
|
Swap: 487Mi 87Mi 400Mi
|
MariaDB [(none)]> SELECT table_schema AS "name", SUM(data_length + index_length) AS "size", COUNT(table_name) as "tables" FROM information_schema.TABLES GROUP BY table_schema;
|
|
+----------------------------------------------------+-----------+--------+
|
| name | size | tables |
|
+----------------------------------------------------+-----------+--------+
|
| information_schema | 212992 | 82 |
|
| mysql | 118759424 | 31 |
|
| performance_schema | 0 | 80 |
|
| prod_2ertest_fr | 135168000 | 456 |
|
| prod_bageops_fr | 121749504 | 466 |
|
|*** | 138428416 | 500 |
|
+----------------------------------------------------+-----------+--------+
|
53 rows in set (3.600 sec)
|
|
MariaDB [(none)]>
|
MariaDB [(none)]> system free -h
|
total used free shared buff/cache available
|
Mem: 15Gi 7.2Gi 153Mi 109Mi 8.2Gi 8.0Gi
|
Swap: 487Mi 87Mi 400Mi
|
MariaDB [(none)]>
|
This is expected. It needs to open all tables to calculate the result of your query and open tables aren't immediately closed, but go into the table cache, in case you'll need them again