什么导致MySQL在Centos6 VPS服务器上使用43.6%的内存?请注意,我删除了除MySQL之外的所有top
个列表。 VPS只运行一个Concrete5网站。我重新启动了MySQL,甚至重新启动了服务器,但没有改变。
Tasks: 40 total, 1 running, 39 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.0%us, 0.0%sy, 0.0%ni, 99.9%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 1048576k total, 989376k used, 59200k free, 0k buffers
Swap: 524288k total, 0k used, 524288k free, 223392k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1929 mysql 20 0 1117m 446m 6240 S 0.0 43.6 0:00.42 mysqld
mysql> SELECT table_schema "DB Name",
-> Round(Sum(data_length + index_length) / 1024 / 1024, 1) "DB Size in MB"
-> FROM information_schema.tables
-> GROUP BY table_schema;
+--------------------+---------------+
| DB Name | DB Size in MB |
+--------------------+---------------+
| concrete5 | 10.1 |
| information_schema | 0.0 |
| mysql | 2.4 |
| performance_schema | 0.0 |
| school_db | 23.5 |
+--------------------+---------------+
5 rows in set (1.07 sec)
mysql>