0

I am new to EC2 and following their tutorial.

I created a t2.medium server and would like to install java/tomcat/mongodb.

I read in Best Practices

"Use separate Amazon EBS volumes for the operating system versus your data"

the system uses only 16% of the room on the server. Do I still need to use EBS although I have enough storage room now?

Dejel
  • 195
  • 1
  • 1
  • 7

1 Answers1

1

It seems to me there are two major issues.

Firstly, what about disaster? Although you have space now, what happens when the storage fills up? If the data storage fills its own volume, your data-driven processes stop - but your server runs on. You can get in, and fix things easily. If the data floods the OS volume, logging stops, the OS may stall, remote logins may become difficult, it's a mess.

Secondly, how do you recover from or avert disaster? If you decide you need more space on a separate data volume, pumping it up to a bigger one is easy. Enlarging the root volume is trickier, though not impossible; pain is lessened with a separate data volume. What if it's not disc space, but CPU/memory that's now inadequate? If you decide you need a bigger instance, migrating the data when it shares a root volume is time- and bandwidth-consuming. If it's on its own volume, you stop the first image, detach the volume, attach it to the new image, and your data's moved across (yes, you could do that with an old root volume, but then you have to do a bunch of cleanup - and cleaning up old device and proc files isn't always problem-free). Again, pain to come is lessened with a separate data volume.

By no means is it impossible to run with mixed OS and data; many people do it. But you minimise future pain - which is a goal of any professional sysadmin - by not so doing.

MadHatter
  • 79,770
  • 20
  • 184
  • 232
  • Isn't changing the instance type easy with a click of a button? why would I need to migrate the data? from the instructions it seems like a matter of stopping the server, changing the type and starting it – Dejel Nov 29 '15 at 11:06
  • Not from paravirtualised to HVM, or vice-versa - that is a thunderous pain. It's also easier to migrate data if for some reason you're also changing OSes when you change instance size. Doing any of this with data and OS mixed is not impossible by any means, and these issues won't affect all migrations - but you future-proof yourself best when you keep things separate. Whether it's worth the added cost is a judgement call. – MadHatter Nov 29 '15 at 11:30