Tel: +44 (0)1786 430076 email: info@objectiveassociates.co.uk
Discussing Amazon's AWS, including costs and "how to" best advice. We also talk about related technologies. The Objective Podcast is available on iTunes.
The simple steps you'll need to take to get up an running on AWS with an EC2 instance.
Alex: Hello and welcome to another episode of the Objective Podcast with myself Alex Ogilvie and CTO at Objective Associates, Fraser Ingram.
Fraser: Hi there.
Alex: Today we are going to be talking about how to get started with Amazon Web Services. How to actually get yourself up and running if it's the first time that you've actually logged on to the Amazon services. So Fraser willll take us through some of that. So I guess the first thing is you have to land on a website and do something?
Fraser: Yeah, yeah, so the first thing you do is go to aws.amazon.com forward slash free and get yourself signed up for a free tier account for Amazon web services and... and kick off from there.
Alex: Alright well we always like free although I guess it doesn't remain free for very long: so then what? What are you gonna be faced with, once I guess you've created and account and you've logged in, so what's the first thing you typically going to see?
Fraser: Yeah, I mean once you, once you, create your account and login, what you get is effectively the list of services that AWS offers, or Amazon offer through AWS program. Simply - you know, if you want to start simply, you want to get a server up and running; the first thing to choose is choose EC2 as your service that you want to kick off. EC2 is effectively their cloud compute, so that's a server you can get up and running from them.
Alex: Okay, and if you if you stay within certain boundaries you can play around with that free.
Fraser: Yeah, yeah, so you can get a Windows Server up and running for free. It's not the most powerful server but you know, you can get up and running, get get connected to it, and do things.
Alex: So that would be useful if you're just experimenting. Wanting to see if this environment can he work for you and give you the comfort that you're not gonna make a mess of things I guess.
Fraser: Yeah, absolutely.
Alex: everytime I look at the list of services it seems to be getting longer and longer, but we're going to stick with EC2. Is there any other ones in there that people are worth looking at?
Fraser: Yeah, I mean, I guess the ones that typically have been seen there's things like S3. Which is Amazon's simple storage services. So that's effectively where you can store files, store images and documents and things like that. So, yeah, that's there as well. You've got Lambda, you've got artifical intelligence services, you've got a whole range of services in there. But, yeah, EC2 - good place to start. Familiar - you know - get a server up and running and remote desktop to it.
Alex: Alright so if you go down that EC2 route and you choose a server that'll give you all the memory configuration and the disk space that you can set up, you don't have to go anywhere near S3 or any other services you can concentrate on EC2 and get a server up and running.
Fraser: Yeah, yeah, yeah - just start in there and get your server up and running. So yeah, choose EC2 from your list of services. And choose instances; you'll come up with a menu on the left hand side, choose instances and just press the big blue, launch instance button and that will take you through how do you launch an instance on EC2.
Alex: I guess though, you obviously have to think about security when you're logging into servers. So what comes first... I mean have you got to set up some kind of authority or keys or something?
Fraser: Yeah, yeah, I mean the bit that I missed out there, is what you want to do is set up, get Putty downloaded onto your PC - I'm assuming that you've got, you know, Windows PCs here so download Putty onto your PC and when you're in your EC2 console - what you do in there is, underneath their network services, theres generate key pair, and get yourself a key pair generated and get it saved onto your PC. That's the first thing you really need to do. There's plenty of videos in YouTube on how to do that it's far to complicated to try and explain in a podcast. But, yeah, get a key pair generated and get get it saved onto your PC.
Alex: But I guess if your in an IT admin role you're gonna be familiar with generating key pairs and in using things like Putty. This shouldn't be, it shouldn't be a big challenge for most folks out there.
Fraser: No, I mean it's not, it's not particularly complicated. It's just a set of steps that you need to run through and keep those, keep those key pairs safe.
Alex: Download this thing called Putty, you do stuff with it, and you get your key pair, so that you can securely log in and out of of your instance once you've got it up and running. So alright, so you're going to go into this EC2 section, you're gonna launch an instance. How are you going to configure that though, how you are you going to choose the instance that you want?
Fraser: So Amazon have got a bunch of what they call AMIs, that's the Amazon machine image, that's effectively the, you know, what operating system's running on this machine and, you know, maybe, maybe even what kind of database is running on it as well. So the first thing you do is when you're launching that instance, is you choose what do you want to run on that machine: you know, are you looking for a Linux or are you looking for Windows to run on that. You know, maybe, you know, Windows 2016. So, in our case you know we'll choose a Windows Server 2016 base AMI. It's just in the list, just do a search for it and pick that one.
Alex: So this AMI, this image is just basically so that Amazon can effectively shift that onto the instance, the actual machine, if you like, that you choose ultimately. This is just you saying this is the type of operating system I want.
Fraser: Yeah, I mean it', it is the operating system, it's that image of the operating system - so that's it getting up and running effectively. So that's the base install really.
Alex: Right and I guess makes getting up running pretty quick then?
Fraser: It does, yeah, yeah.
Alex: Alright, so you've elected for, let's say, Windows Server 2016. You now, I guess, need to decide what type of kit you want to run that on. So is that complicated in Amazon's world? How do you actually choose what it is you want to run this stuff on?
Fraser: No, I mean if you want to get started quickly choose something like a T2 micro. T2 micro is their smallest, or one of the smallest instance sizes. And it's within their free tier. So you can play around with that until your heart's content under the free tier.
Alex: Alright so they've got these different instant names that don't seem to make much sense to me - so what would be a typical instance type. Once you're getting serious.
Fraser: Yeah, I mean it you're looking at, you know, a general purpose instance - you're probably looking at something like an M5 extra-large. So you're talking 4 virtual CPU cores, 16 Gig of memory in there. Yeah, so that's your kind of typical, reasonably powerful, server.
Alex: Right, so you run down the list and you choose something that you think's gonna have enough, I guess, grunt on it, capability to do what you want, if you're breaking out from the free tier.
Fraser: Yeah, the next thing you need to think about is what kind of storage you want to be attached to that server. As you're going through, down the list, there's a strange column, that's called instance storage - and it either says EBS or it gives you a drive size - an SSD drive size. If you're choosing, so that is either instance storage, or its EBS storage.
Alex: Alright so if you choose instance storage, this is storage that is connected to that server environment - that physical machine, if you like, that you want to connect that storage to - so that's the instance; you're connecting that storage to the instance. And there's various machine instances that let you do that.
Fraser: Yeah, and the thing that you've got to remember with that instance storage is that it is connected locally to that machine and is temporary. Okay - so, if you, if you shut down that machine and then bring it back up two days later, then whatever data you had on that instance storage is gone.
Alex: Alright, so you're going to pick something that's got SSD storage, local to that machine, which will give you great throughput, I guess, but it's effectively volatile. So you need to be careful that you're picking the right thing for your environment and don't assume that's going to be there as your hard disk regardless of the state of the machine.
Fraser: No, definitely don't assume that that's always going to be there or what data's going to be on there. You'll always have that if you've got an instance type that's got instance storage on it you'll always have it connected but it'll not always have your data on it from the last time you ran it up.
Alex: Right so if you're using SSD drives connected to your instance you're always going to be wanting, I guess, some other type of storage as well.
Fraser: Yes - so I mean you use that instance storage exactly for that, for temporary data. You know if you're taking data from somewhere, processing it and then you don't need that anymore, that's ideal. High-volume data you can use it for things like - on a SQL server - use it for temp DB. Things like that, so it's temporary - but: if you want to then, if you want storage that's that's always - you can save files on - and keep them there between shutdowns and startups - then you're looking at the EBS storage. EBS storage is effectively connected storage that you've got, that you can store your files on.
Alex: Right - but it's not local; but it's storage that's dedicated to your machine.
Fraser: Yeah and it's connected in the same way, so it just looks like an E drive or an F Drive on that machine.
Alex: Alright. Okay so your instance - you choose whether you want SSD local storage and you probably want to top that up with EBS as well. Otherwise you're gonna lose your data. And this is got nothing to do with S3. The S3 storage stuff is totally different? Totally different service - that's if you want you chuck stuff onto Amazon's storage facility.
Fraser: Yes, that's access through web services so you don't access it through, it's not like an attached drive to your machine.
Alex: Right, okay so we pick an M5 extra-large and we choose SSD perhaps and EBS. Then what, what happens, you hit the do it button? What happens next?
Fraser: Yeah, so the next thing you need to get the instance will get launched and then it'll appear in your dashboard - on your EC2 Dashboard. So first thing you need to do is figure out how to login to it. So you need to get your password for it, and this is where the keys come in handy from a few minutes ago.
Alex: Oh it's this Putty thing.
Fraser: Yes, yeah, yeah so you need to get... so effectively you'll see your instance on your EC2 dashboard. If you right-click on it there's a get password option in there and it takes three or four minutes. You give it your public key from your key pair that you generated earlier. And you'll get your Admin password.
Alex: Alright so you use that and you're in. You've now got access to your server.
Fraser: Yeah, you can now remotely connect to that server. Play around with it. Install some software on it.
Alex: And it just looks like a conventional server. You've not get anything in there that makes it look like it's an Amazon world, it's just, just like what you've always used.
Fraser: Just like what you've always used, the only thing - top right hand corner they tell you what kind of instance type you've got and yeah that's it.
Alex: Right okay.
Fraser: You're now getting charged by the hour.
Fraser: Certainly in the windows instances your now getting charged by the hour for that instance up and running.
Alex: Alright so yo're into the server and it might be free of you might be paying for it but, well that's you up and running. I guess the next thing you have to do is probably lock it down a bit at they so that bad people can't get access to it.
Fraser: Yeah so the next thing you need to look up beyond that, is things like, your security groups, setting up your security groups, again that's done within the EC2 console. You know, if you want to set up public IPs, set set them up. Or if you want to go a wee bit further than that, look at elastic load balancers and things like that. Elastic load balancers let you do things like, make sure that they're always a machine up or make sure there's always two machines up.
Alex: Right okay I get that. And I guess, I guess as well there must be ways in which if you haven't quite got that configuration right, you've not got enough storage or you want different types of storage you can do that same thing, You can configure that, I should say through that EC2 console then?
Fraser: Yeah so say your wanting an extra 500 gig drive attached to that, you want some EBS storage attached to it. You go into the volumes section within your EC2 console create a new volume and theres some steps you need go through to attach that to your instance. But effectively, yeah, go in there say, right ok I want a 500 gig volume. Get it up and running and then when you're finished with it - get rid of it because, you know, your paying for it when you use it so, you know. Add it then remove it when you're finished with it. There's no need it's not like a traditional data centre when you tell them you want a 500 gig drive and guess what you've now got that for the next three years.
Alex: It does seem incredible that the flexibility that Amazon's built into configuring these instances and being able to drop things like storage when you don't need it. It just strikes me as fantastic.
Fraser: It's phenomenal, absolutely phenomenal. You know, attach storage, attach large amounts of storage for short amounts of time. Use it just for what you want to use it for and then get rid of it.
Alex: Okay so well I guess that sort of covers it. I mean in summary if I can try and summarize that: I guess once you've logged in, if you're setting up an EC2 instance you go in there you choose the image that you're looking for. So typically that might be, certainly for us a Microsoft server. A Windows server rather. And then you choose the instance whether that's a free one or something like an m5 extra-large and you choose, subsequent to that, whether you want to use EBS as well in addition to any kind of local storage that you've actually selected. So yeah, sounds pretty straightforward and in amongst all that of course you have to use something like Putty for generating keys. But yeah so it's pretty straightforward doesn't seem like something that should stop any IT admin guy having a bash.
Fraser: No, and if your stuck fire onto YouTube - plenty of instructional videos on there.
Alex: Alright, okay folks thanks again for your time we'll be doing a few of these as I've said before, so please check in regularly. And if you want to know more about what we do www.objectiveassociates.co.uk Hopefully talk to you again soon - bye just know.
The Objective Podcast is available on iTunes
AWS resilience capabilities explained
How to manage Amazon’s AWS costs
How to get started on Amazon's AWS
How to choose your AWS instance type
5 tips on how to save money on AWS