I am attempting to create an Ubuntu instance on an OpenStack Cloud. However, the basic images don't allow for a large root (/) partition nor would that be common when deployed to public clouds.

I have come to the idea that I should create a volume for persistent storage and tell MySQL to use this for its data storage.

However, I am not sure if that is conventional nor smart. Also, would it be better to simply replace /var with the volume (since it will save logs in addition to the database) or should I create a custom directory with the volume dedicated only to MySQL?

Overall, what is an acceptable or conventional way to create an OpenStack Ubuntu instance configured to host a MySQL daemon with a good amount of persistent storage for the data?

Note: This question has answers which will show me how to configure MySQL so feel free to abstract those particular details out of any answer.


conventional way!

Start with a VM that has enough CPU/Memory to handle user/developer work load.

For storage you can start with small instance, utilize LVM in linux to grow your database volume as you need (online without downtime).


You will need to create a volume group in linux & add logical volumes to it, then mount it to /var, then install mysql mysql-server packages.

there is no limit on how many logical volumes you could add, you can technically scale upto terabytes of data and the limit would be file system and cost.

PS: its recommended to use xfs file system with very large data volumes. for most cases ext3 or ext4 will do just fine).

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.