Move /var directories to to /mnt on an EC2 instance
- by Geoff Lanotte
I am trying to work on a standard configuration for a set of EC2 instances running ubuntu 12.04. These servers are going to be primarily web servers for a Ruby on Rails application. When you configure a new large instance, you are given a primary of 8GB and then ephemeral storage of 400 GB that is mounted to /mnt.
It seems logical to me to move some directories that have a potential for growth off to the /mnt directory, I was specifically thinking of /var/www and /var/log.
My question is two-fold:
Is this a good idea or are there pitfalls that I cannot see?
If this is a good idea, how should I go about configuring this. I do have the ability to configure new instances and down our old instances. My concern is over long term, doing this in such a way that it prevents downtime.
I am a developer with some experience in devops, but mounting drives is something I have not faced before, so explicit directions would be greatly appreciated.