我可以将MySQL表移动到第二个驱动器吗? [英] Can I move MySQL table to a second drive?

查看:71
本文介绍了我可以将MySQL表移动到第二个驱动器吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遇到了与I/O相关的性能问题,如果在SSD上运行一些相对较小的表,这些问题将得到解决.我无法将整个数据库移至SSD,因为它太大了.

I am having I/O related performance problems that would be solved if a few relatively small tables were running on a SSD. I can't move the entire DB to SSD because it is much too large.

我认为这是有可能的(将特定的表映射到不同的驱动器),但是我托管的托管公司的一名技术人员说整个数据库需要放在一个目录中.这样对吗?如果他错了,有人可以向我指出如何完成此工作的基本说明吗?甚至在这里提供说明?

I thought this was possible (map specific tables to different drives) but a tech at my managed hosting company says that the entire DB needs to be in a single directory. Is this correct? If he's wrong, can someone point me somewhere with basic instructions on how this is done? Or even provide the instructions here?

推荐答案

创建MySQL表时,可以指定data directoryindex directory. 看看 http://dev.mysql.com/doc /refman/5.1/en/create-table.html

When you create a MySQL table you can specify the data directory and index directory. Have a look at http://dev.mysql.com/doc/refman/5.1/en/create-table.html

因此,要回答您的问题,您可以在其他目录中创建一个新表,然后将数据迁移到该表中.

So, to answer your question, you could create a new table in the different directory and migrate your data there.

这篇关于我可以将MySQL表移动到第二个驱动器吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆