2

I'm using MySQL.

I have one volume with 1TB of space.

But now I need more space (let's say one more TB).

How can I use MySQL to store data on more than one volume ?

1
  • You might want to consider using RDS, which is a managed MySQL service provided by Amazon. Feb 12, 2015 at 12:28

3 Answers 3

2

I take it from the 1TB size mentioned that you're using EBS. Create two EBS Volumes and combine them with RAID0. In addition to giving you more space, this will also improve your performance.

0

If its a normal ec2 instance (rather than RDS) so you have command line access.

Can just use symlinks to map parts of the data folder elsewhere. Eg. Shut down MySQL server

cd /var/lib/MySQL
mv bigdata /mnt/new/bigdata
ln -s /mnt/new/bigdata

And start MySQL again. The bigdata database is now running from another partition.

Of course this is best suited to myisam tables. If innodb then going to need to mess with table spaces to get seperate files so can move some of them

1
  • How can i store the bigdata in the new volume if i only have 1 TB of space. I need 2 volumes and i need to access them both at the same time every time i make a query. moving them to the new volume and map it does not solve my space problem.
    – Aw Suevi
    Sep 26, 2011 at 17:19
0

Note that EBS volumes can currently be up to 1 TB in size. The largest EC2 instances offer local storage (ephemeral storage) up to 1,690 GB, but that storage is not persistent.

Best,

Simone

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .