Hello everyone and welcome to the EASY TO instance set up lecture now that we have our Amazon Web Services
accounts set up we can go ahead and create an easy to instance Amazon Elastic Compute Cloud or E.S.
to is a web service that provides resizable compute capacity in the cloud.
In layman's terms you can basically think of this as just a virtual computer that you can access through
the Internet.
So here is our overall plan.
The first thing we're going to do is use the AWOS Council Web site to create an easy to instance then
we'll use S-sh or secure shell to connect to the E.S. to instance over the Internet.
However you should note that S-sh is a little different for Windows versus Mac and Linux.
And we'll discuss those differences in the next slide.
Once you've connected we'll go ahead and set up Sparc and Jupiter on the east to instance let's discuss
secure shell S-sh stands for a secure shell connection.
If you're on a Windows computer what you will do is you'll watch this lecture all the way through.
We'll go ahead and show you how to set up the easy to instance and then we'll show you how to connect
through S-sh on a Windows computer.
If you're on a Mac or Linux computer you're going to watch the first half of this particular lecture
where we set up E.S. too.
And then all that you know when you can stop watching and skip to the next lecture or the S-sh set up
for Mac or Linux Mac or Linux actually has a much easier time using S-sh.
It's already built into the operating system so it's just too simple command lines for Windows.
It's a little more complicated than that which is why we're going to show it all in this one lecture
and I'll let you know when you can finish watching if you're on a Mac or Linux computer.
Basically our overall goal is just to remotely connect to the command line of our virtual machine on
Amazon too.
So regardless of what operating system you're using right now go ahead and go to your aid the U.S. consulate
AWOS the Amazon Dot Com and log in all that you know and you can stop watching if you're on a Mac or
Linux if you're on a Windows computer you're going to watch this entire lecture.
Let's go ahead and jump to Amazon.com and log in.
OK here I am.
We go to Amazon.com where you're going to go ahead and do is click sign into the console.
Usually be some sort of button either here or on the top right.
Go ahead and click on sign into the console and then fill in your e-mail address and your password.
I'm going to go ahead and do that now.
All right.
Here I am logged into the console and you should see something similar to this.
Now the interface may change but basically what we want to do is figure out how to get to the easy to
service sometimes so the shortcuts here are quick starts such as launch a virtual machine easy to instance
.
But in case you can't find the here on the main page you can either search for other services will be
under compute easy to or MCGLENNON zoom in a little bit.
You can just click here on the services tab go to compute and you should see E.S. to it's under all
AWOS services as well.
Do you go to easy to here.
So obviously there's a lot of services.
But SETI is the one that we're most interested in.
So go ahead and click on that and it will take you to a link that looks like this what you're going
to go ahead and do is then click on launch instance then you should see some options here.
And it says Choose an Amazon machine image this machine image is basically what operating system you
want on this virtual computer that we're setting up.
We're going to go ahead and do a scroll down and click on U-Boot to make sure it says free tier eligible
but we don't get charged.
So we're going to go ahead and select Ubuntu then you'll see something that looks like this general
purpose.
And these are all the incense types you can create.
We're going to use the free tier micro which is the smallest available besides Nano that it's totally
free has one CPQ and then one gigabyte of memory so it's quite small and it has low to moderate network
performance.
You can see later on if you actually do want to pay for higher performance instance types that the actual
memory or gigabytes essentially the RAM goes up to 160.
So there's quite large instances available to you.
Well right now we're just going to use the micro since it's free.
So make sure you use free tier eligible Otherwise you'll have to pay.
Then I'm going to go ahead and say next configure instance details and here we're going to say number
of instances is equal to 1.
As I mentioned earlier when we were dealing with SPARK are distributed systems you may have a cluster
of instances when you're dealing with real huge data set.
You will put more than one instance here.
But since we want everything to remain free we're just going to use one instance to make sure this is
one.
Everything else can be on the defaults and we'll go ahead and add storage next the default storage is
just eight gigabytes.
Go ahead and keep that everything detail everything as the default here and click next tag instance
.
And here we can go ahead and create a tag instance.
Go ahead and set this key to something like my spark and it will set the value equal to my machine doesn't
really matter but just write these down your key my spark and value my machine.
Next we're going to configure a security group.
And here you'll see a drop down for a type.
Go ahead and scroll down here click on it and click on all traffic.
You should see create new security group and change type to all traffic.
Everything else can be kept the same.
You'll click on review and launch and you should see a little prompt here that says improve your instances
security your security group is open to the world.
Don't worry about that because you're going to want to be able to easily access your instance.
However if you're actually dealing with some sort of company platform you probably don't want your security
to be this open.
But for now since it's only going to be you using it you can just go ahead and leave your instant security
totally open once you have everything ready.
We have our aboon too.
It's on microdots here once EPU one memory you have your security groups it's set to all traffic.
Everything's basically just defaulted except the all traffic.
Let's go ahead and launch this by clicking watch.
Here's an important step.
It's going to say select an existing key pair or create a new pair.
What you're going to go ahead and do is say creates a new key pair and then you're going to say keep
their name here.
Let's go ahead and type new spark.
And this is incredibly important.
Click download keep hair now.
You have to download this private key file it's called a dot PTM file.
You can see it pop the appear on my lower left.
You're not going to be able to download this file again after this window.
So whatever you do make sure that you say create new key pair type in a key pair name and say download
keep here.
This is absolutely important.
If you don't do this step you'll have to start all over again because there's no way to come back to
this.
So make sure you download the stop file.
Once you've done that you're ready to launch for instance.
They'll say initialing launch.
And it says your instances are now launching an old man I'll say something like the following.
The following instances launches have been initiated so you can go ahead and click on this instance
and it should take you to something that looks like this.
You'll be spending a little while if you actually pay for a larger Amazon web service instance.
It'll probably be a lot faster than this but here we're going to just wait till it's done implementing
and there we have our instant state is running and we have an instant site.
We have a public DNS.
And those are the things we need.
And we have our Doppie file.
You can also perform actions on this instance.
The most important one to know is this terminate.
So this terminate instance is the one you're going to use when you're done with this instance and you
don't want to be running the risk of getting charged anymore.
Now as I mentioned on the free tier you have 750 hours a month for 12 months that's an entire year.
So you can basically keep this thing running for an entire month but really you should terminate it
once you're done that we don't run any risk of getting charged any extra money.
You should note extremely cheap to run these things.
But it can add up over time.
All right so now if you're on a Mac or Linux computer this is it you're done.
We've done everything as far as setting up or easy to instance.
All you have to do is follow the steps for launch in that instance and download the data file.
Go ahead and skip to the next lecture so you can see how to S-sh connect to your instance.
All right.
If you're on Windows keep watching we're going to go ahead now and show you how you can connect to this
instance command line.
Now what I want you to do is go ahead and go to Google dot com in a new tab.
So I'm going to go ahead and go to a Google tab and what I want you to do is let me zoom in.
Here is search for this term s s h.
Space windows space e C2.
And it should take you to this connecting to your Linux instance from Windows using putty.
And I'm going to leave this link as a resource for the lecture.
But go out and click on this link and you should see a guide here to connecting to your Linux instance
from Windows using putty.
This is exactly all the steps we're going to do to actually connect to our Linux instance using Windows
computer when those computers have a little more involved of a process in order to connect.
Mac and Linux it's very easy.
Well let's go ahead and walk through all these steps.
I would recommend that you keep this documentation page open while you follow along with me.
That way you have a reference for everything we're into.
And you can either search for this link on Google or you can actually click on the resource link in
this lecture.
All right so let's go ahead and walk through the user guide and I will show step by step what we need
to do.
First are the prerequisites since run a Windows computer we need to install Huddie but he is going to
allow us to do a secure shell connection to our AC to instance we can do it from the download page.
Go ahead and click on this link or just google search download.
You should see a page that looks like this.
You're going to go ahead and click on it.
Go ahead and zoom in here on this download link.
This will take you to a page that looks like this.
You're going to scroll down so you see these Minories we need installed to these programs paid the ex-Sea
and then PERDIDA or gender you see the two that we need and then we're going to go ahead and save these
here and call on them when we need them.
So going back here we're going to need to get the idea of the instance you can actually just find it
here and there the instance ID column will need that series of letters and numbers.
We need the public the DNS name that's located right here Public DNS and then we need to locate the
private key remember that was a dot p m file.
I have that saved under my downloads folder.
And then you need to enable inbound S-sh traffic.
We actually already did that when we selected all traffic when we created the instance.
All right.
Next step convert your private key using putty.
GEN.
So petty doesn't natively support this PM format so we need to do is follow these instructions to convert
it to a private key.
So I'm going to click here on puttee gen launch it and you'll see that you get Windows protected your
PC if you get this message.
Go ahead and click more options and run anyway.
And then you should see the putty key generator.
So we'll go ahead and start puttee again and then under a type of key to generate will select SS h to
RSA and then we're going to go ahead and click load in order to find the dot M-file.
So click load here
and I'm going to go to my downloads folder go all files and search PTM and here's New Sparke PTM.
You should see it that it successfully imported the foreign key click OK and then I'm going to go ahead
and say save the private key.
So I'm going to save private key in a pop up will say Are you sure you want to save this key for a passphrase
.
Protect it.
Go ahead and say yes and I'm going to just save this to my desktop with file name Huddy spark and save
that.
OK.
So now our private key is in the correct format so use of putty and we're good to go.
You can then go ahead and close the key generator.
Next we want to start a putty session so we're going to go ahead and use that PPK file that we just
created as our private key.
So go ahead and skip step 1 which is optional say start Huddy.
So here we have X-Sea you know go ahead and click on that to start it should look like this.
Then in the category pain which is this pain right here select session and complete the following fields
.
So I'm going to go ahead and come over here.
Notice in the category pain we have session is actually the default here.
We're going to go ahead and say in the host name box enter user name at public DNS name.
So if we look over here we have the public DNS name.
I'm going to go ahead and grab that in a copy that and then go back to my puttee instance and then paste
it here.
And now we need to put in the user name for buntu user.
You go back here we can see that you boot to the user name is Ubuntu.
So coming back to the putty I take place in this whole DNS address and then say a boon to at that whole
address select the under connection type S-sh we have that there ensure that core is 22.
That's correct.
In the category pane.
Well we're here again expand connection expand S-sh then select a TH for authorization.
So category pain expand connection expand S-sh and click on authorization here.
We'll go ahead and click Browse and we want to select the PPK file.
Remember it was on my desktop and we called it Huddy spark that PBK.
There it is.
Open it up.
This is an optionals see but don't worry about it.
We'll go ahead and go to letter D.
Click open to start the session.
The click open here and you should see a security alert.
The server's host key is not cached in the registry.
We can trust this or go ahead and say yes obviously you trust that you created this yourself if you
don't trust this.
You know you could get a virus or something are connecting to someone else's instance but this is our
own instance we created it.
So of course we trust it.
And there you go.
Now we're able to connect directly to Ubuntu.
So this is our virtual server.
So if you type in python here you can actually just start using Python so you can say print Hello enter
and then you have hello.
And then we can go ahead and quit Python.
All right so this is basically a real connection to a virtual computer hosted somewhere through our
command line.
This is the S-sh we're talking about and that's all we have to do.
So again you can go ahead and post any questions you have to the Q&A forums but basically just follow
this Amazon guide it tells you step by step what to do.
And we just did it step by step on our own computer here.
All right.
Hope you enjoy this lecture.
Hope it was useful to you and feel free to post any questions you have and check out the documentation
in case you get stuck anywhere.
If you're a Windows user go ahead and skip the next lecture because the next lecture just talks about
doing this S-sh process on Mac or Linux computers.
After that lecture we're going to show you how to set up everything through this command line con..
So make sure you keep this open.
This command line con..
All right.
Thanks everyone and I'll see you at the next lecture