This content explains Google Cloud Platform's (GCP) compute options, focusing on machine families, their use cases, and how to configure and modify virtual machines (VMs), including the addition of GPUs.
Mind Map
Expand करने के लिए click करें
पूरा interactive mind map देखने के लिए click करें
foreign [Music]
[Music]
in the last video I covered the basics
of compute the types of compute and we
also did a small case study to create a
compute if you have not watched that
link is in the description do watch that
as well
this video will be more around
understanding the type of compute
options we have like these four
we will also understand when to use what
Nuance if we understand that we'll also
be doing this case study where we'll create
create
a VM with scratch and understand the
options available
the GPU is a concept which is pretty new
and very relevant to the exam so stay
tuned with the video the first thing we
need to understand today is the machine
family resources and comparison
gcp provides us four type of machines to use
use
the first one is general purpose it's
mainly used for the best price
performance ratio for variety of
workloads then we have compute optimized
when you need a better CPU performant
jobs then you'll be using compute
optimized when you need a memory hungry
processes memory intensive workloads you
want to run we use memory optimized VMS
and then we have gpus if we want to run
some ml high performance Computing then
we go ahead with gpus which is called
accelerator optimized so these four type
of machines we have while creating a
machine you remember this is one of the
decision which we have to make that
which what is the purpose of this VM
these four are the options which we must
be aware of before we create reasons
moving on
now coming to the machine family and
series recommendations this is one of
the page which you must bookmark and use
while while planning your resources
here is the workload types first is
general purpose workload second is
optimized workload general purpose comes
under E2 N2 tt2 t2a these are the
general purpose machines then you have
very optimized workloads which is
specific to your need as we mentioned
when you want some memory intensive
process when you want more CPU menu mod
GPU so you'll be going with optimized workloads
workloads
it also has some recommendation like for
day-to-day Computing at a lower cost you
will be using it
for balance price performance across
wide range of machine types you'll be
using N1 N2 use cases are also mentioned here
here
like for web serving app serving back
office databases microservices virtual
desktops E2 stands the best
N1 however also serves the same purpose
it's just that it it is also a little
better for media streaming cache and all
E2 is a better candidate when you are
using it for shorter time and N1 N2 is a
good candidate when you are running it
for more than 24 hours or for some
regularly for more than 12 hours okay so
if you are creating infrastructure on
demand for few hours go with YouTube but
if you need it for like for full week or
full full month this is your candidate
okay same goes with the
d2a and t2d when you have large scale
Java micro Services where you have
containerized microservices and you want
best performance versus cost for scale
out workloads then you go with scale out
optimization now generally our use case
has Falls between these two categories
then coming to optimized workloads then
we have memory optimized you have a need
to run medium large olap in memory data
aw you suggests hapana electronic design
automation then you'll be using memory optimized
optimized
you could also have situations like when
you want to run compute optimized
workloads high performance web serving
gaming servers ad servers these all are
CPU hungry processes
high performance Computing then we'll go
with compute optimized and same when you
want to use a ml training interfaces
then you choose gpus
okay so I hope these categories are
clear now so before creating the machine
you it must be very clear that what kind
of workload you are going to create it
for once that question is clear it's
very easy to choose either of these
you may also compare the machines in
this table itself
where you'll get to know that what are
the CPU types if you are interested in
that detail just quickly covering it how
many CPUs you will be getting
okay what kind of CPU definition it is
what is the maximum memory you will be
getting in these
these series what is available what is
not available you can just quickly
compare it and you can filter it if you
need to compare something suppose you
just want want to know CPU types all the
memory ones okay so you get you got all
the CPU types and the memory information
only so a memory intensive application
you know where to go and this is the
maximum uh GB of memory you'll be
getting so which is you know that out of
these three candidates M1 to M3 which is
my which what is my need how much memory
of GB of memory I need and then you can
choose either you'll you'll go for M1 M
to M3 these kind of this decisions you
can make
I hope that is uh clear now now coming
to gpus
so yeah the last category is the gpus so
gpus are generally used to accelerate
the workloads you can attach GPU to VMS
using the N1 series or the A2 machine
Series so it is not available everywhere
and it is not available in every region also
also
while creating it you'll get to know
that typically revising it we have four
type of machine families general purpose
compute memory and accelerator optimized
which is gpus and we have depending on
our workload type we can choose between
or M3 to M2 C2 to A2
GPU regions and zones are really
important concept why because you you
are not gonna find gpus everywhere okay
you might have specific need for
versions of the which GPU model you want
to use so you need to first of all
understand which location it is
available so if you want to check where
it is in Europe you'll select Europe and
then you'll say that okay I need T4
in this it is available with only these zones
zones
the point is that always be sure before
planning your gpus because you're not
going to get it everywhere suppose if
you come to a pack Zone
and you choose in more models suppose
300 okay
so T4 v100p 100 is only available in
Asia s1c
that means that if you need this kind of
gpus you need to provide provision your
VM in this Zone not 80 models if you do
it you don't get you won't get gpus
so always be sure that viewers this
planning already in place before you go
and provisional infrastructure
let's go ahead and do the case study to
understand it the case study in this
video is around creating a virtual
machine with below configuration name
machine family should be E2 standard 2.
we want to install Apache on this VM by
creating a sample HTML file and this
should happen automatically I don't have
to do anything manually the next
requirement is remotely connecting to
the instance via Cloud shell and confirm
if Apache is installed or not this is
the step one once we'll do it step 2
will be editing the configuration
okay so there's a requirement suppose
that you want to change the machine type
from E2 standard 2 to N1 standard four
can you do that
we'll figure that out the last
requirement is to attaching a GPU of T4
family and then start the VM first one
first part is around creating something
and running a patch over it second part
is about making changes to that existing
and running VM and how do we do that
let's go ahead and do it at the console
for this first of all I'll click on
create a VM or you can go to compute
engine and then click on VM instance
and create instance I have already
covered the basics in the first video so
I'll be covering the case study for now
this is the name
reason could be just default let's not
change it
now you see this is what I was talking
about at the start of the video this is
a general purpose these are the family types
types
this is the first generation this is the
second generation machines for general
purpose then we have compute a compute
optimized which is for high performance
compute intensive workloads
if you need memory optimize you will use
memory optimized if you use GPU you'll
use GPU for now the requirement is to
create a E2 standard to machine E2 so
I'll say that okay
let's choose E2 standard two machines
no GPU for now
after choosing this the third
requirement is to install Apache
for this what I'm gonna do I'm going to
use the startup script startup script is
basically you want to run something when
your system boots up or restarts startup
scripts can be used to install softwares
and updates and to ensure their services
are running within the virtual machine
so that is the requirement I want to
install Apache once the machine is
getting created it should install Apache
as well before it makes it available for
me for this simple script will do so
what I'm saying apt update which will
update the OS and then I'm saying
install Apache
I'm creating a simple
index.html which is Linux
startup script add it directly so this
message should be there
once I have provided a startup script so
I'm creating
an E2 standard machine with this name
and installing the Apache
that that's the ask so without a delay
I'll click on create
may see the machine is available now the
next step is we need to remotely connect
to the instance via Cloud shell and
confirm if Apache is installed correctly
or not
the last video we understood at how to
connect it via browser but this time
I'll go ahead and connect via Cloud shell
shell
for this you need to click here it will
activate your session so what it is
doing it is again transferring your
keys to Cloud shell creating a small VM
for you Cloud shell is a very big topic
I'll have a separate video on it because it's
it's
not very relevant to the exam but uh
it's it's it's important for you to
understand while you work with gcp
perfect it's available now with the
first thing I want to check who is the author
it is asking me to authorize
again I'll pass my password you can see
my account
pushkar@cloudsprint dot in is the active
account which means I have logged in
once you are done with your key setup
you need to connect to the VM okay now
you're authorized to connect to this
project VMS so I'll be for that I'll
write a command called gcloud compute
SSH and the VM name once you hit enter
okay let me transfer the key
yes the key is transferred it is
updating the metadata that was the
default one so now
it is setting my
project metadata SSH met.2 Us West 4
because that's where my
perfect so I'm inside the VM now okay so
now I'm inside the VM and I want to
check that Apache was installed or not
for that I want to verify my PWD which
is root so I'll go from CD slash where
slash www
there's uh
index files I'll just click so this is
what I had
added the comment so you can see that
this VM is created Apache is installed
and the HTML file is also created we
verified it
that's how you create a VM you connect
it via Cloud shell okay I'm closing the
session for now and we'll move to the
second part of the video now suppose the
requirement changed and I have to change
the machine family from E2 standard to
N1 standard 4. how can I do it for that
I will open
the VM first of all once you open the VM
you'll see that
edit button for now you cannot change
anything so you'll click on the edit button
button
this is really important for exam again
when you click on edit there are many
things which you cannot change okay you
cannot change the Zone it's read only
you cannot change the name you cannot change
change
middle machine type okay while the
machine is running you cannot change the
machine type you cannot change the
network you can change network tags okay
you can change view options like you
want to keep this you can add a disk you
can attach a disk okay apart from that
you can't change much that's the thing
which you need to understand that you
cannot change it if the machine is
running it is in running State you
cannot change many things now the ask is
to change the process machine type from
E2 standard to to N1 standard four so
I'm gonna stop the machine now
I'll click here I click on stop the
machine now
once you hit the stop button it will
stop the VM and once it is done the
status becomes stopped we'll again hit
edit and try to change things cool now
you can see the instance status is
stopped I'll again hit on edit
now if you go back you can change many
things okay because the machine is
stopped now now you can go ahead and
change many thing you can change service
accounts you can change everything but
you need to uh what needs to be done on
the restart level our ask is to edit the
configuration type to N1 standard for
the first requirement so I'll go ahead
and change
N1 standard 4.
okay and also attach a GPU
N1 standard four
now you can see now you can see your
machine type is N1 standard four it is
saved all again started once you start
the machine it will boot up with N1
standard for now
the main concept to learn here is that
if you want to change something in your
machine configuration you need to stop
the VM if you are working with unmanaged instances
instances
okay you cannot increase the memory or
change the CPU change the machine family
type change the service account while
the VM is running it has to be stopped
and then you can edit the configurations
you can only change things like
like some firewall rules Network tags or
some disk policies that's it
that that's the one thing I wanted to
explain in this video
the second part is attaching a GPU so
GPU gpus are mainly as we already
discussed gpus are mainly for machine
learning and machine learning and ml for
training your ml pipelines when you work
with big data Technologies this is a
very very common ask so we are gonna add
a Nvidia T4 and then start the VM attach
a GPU
again I'll click on edit so once I click
on edit I cannot change it again already
discussed so I'm gonna stop it
I'm gonna stop it and then again come
back to edit page quickly
click don't edit
and here I'll go to GPU now
last time we changed the machine type as
we were asked in this step now we are
going to attach a GPU of nvdf T4 let's
go ahead and click on GPU
let's say Nvidia T4
N1 standard four
okay and Save
when you're adding gpus you can migrate
on host maintenance it is a concept
which I'll be explaining the later
videos but for now let's say that
terminatorium instance and upgrade and
save it now you can see the ask was to
have N1 standard 4 with attached GPU and
vdrt4 you can
you can confirm here we have N1 standard
four okay running with
Nvidia T4 which is just one of the gpus
okay we just hit start once you start
the VM you're good to go that concludes
our case study thank you for watching
the video so far if you are still with
the video which means you have liked the
content so subscribe to the channel and
hit the like button for such videos I'm
gonna make a lot of content around gcp
devops and SRE so security I also do
regular podcast with technology leader
so stay tuned see you in the other video
Video के उस moment पर जाने के लिए कोई भी text या timestamp click करें
Share करें:
ज्यादातर transcripts 5 सेकंड से कम में तैयार
एक Click में Copy125+ भाषाएंContent Search करेंTimestamps पर जाएं
YouTube URL Paste करें
कोई भी YouTube video link डालें और पूरा transcript पाएं
Transcript निकालें
ज्यादातर transcripts 5 सेकंड से कम में तैयार
हमारा Chrome Extension लें
YouTube छोड़े बिना transcript तुरंत पाएं। हमारा Chrome extension install करें और watch page पर ही किसी भी video का transcript one-click में access करें।