Documente Academic
Documente Profesional
Documente Cultură
GSPOOI
00:25:25
Creating a Virtual
End Lab
Overview
Username
Test your knowledge
Password
student-03-ec21301bf116e [Q Congratulations!
Password
iJ8a3jiBRiCMn'Fmo
GSP001 Test your knowledge
student-03-ec21301bf116@
D Congratulations!
Test your knowledge
student-03-ec21301bf116@
D Congratulations!
Password
student-03-ec213eibf116@ |Q Congratulations!
Password
Overview
Password and Windows Server, on Google infrastructure. You can run thousands of virtual
CPUs on a system that has been designed to be fast and to offer strong consistency
Test your knowledge
of performance.
student-93-ec21301bf116@
Congratulations!
1/17
In this hands-on lab you'll learn how to create virtual machine instances of various
Password
machine types using the Google Cloud Console and using the gcloud command
line. You'll also learn how to connect an NGINX web server to your virtual machine. Test your knowledge
student-93-ec21301bf116@ |P Congratulations!
Although you can easily copy and paste commands from the lab to the appropriate
Password
place, students should type the commands themselves to reinforce their
understanding of the core concepts Test your knowledge
student-03-ec21381bf116e
D Congratulations!
What you'll do
Password
. Create a virtual machine with the Cloud Console
. Create a virtual machine with gcloud command line Test your knowledge
Password
helpful
Test your knowledge
student-93-ec21301bf116@ |P Congratulations!
Password
Password
Setup
Before you click the Start Lab button Test your knowledge
student-03-ec21301bfn6@ |Q Congratulations!
Read these instructions. Labs are timed and you cannot pause them. The timer,
Password
which starts when you click Start Lab, shows how long Google Cloud resources will
be made available to you. Test your knowledge
student-03-ec21301bf116@
D Congratulations!
This Qwiklabs hands-on lab lets you do the lab activities yourself in a real cloud
Password environment, not in a simulation or demo environment. It does so by giving you new,
temporary credentials that you use to sign in and access Google Cloud for the
Test vour knowledae
2 / 17
duration of the lab.
Student-e3-ec213eibfll6@
D Congratulations!
What you need
Password
student-e3-ec21301bf116@ |P Congratulations!
. Access to a standard internet browser (Chrome browser recommended) .
Password
Note: If you are using a Pixelbook, open an Incognito window to run this lab.
Test your knowledge
Student-e3-ec21301bf116@ |P How to start your lab and sign in to the Google Cloud Console
Congratulations!
Password 1
. Click the Start Lab button. If you need to pay for the lab, a pop-up opens for you to
select your payment method. On the left is a panel populated with the temporary
Test your knowledge
credentials that you must use for this lab.
student-03-ec21301bf116@ |Q Congratulations!
Password
Open Ooogle Console
Test your knowledge
Caution: When you ate in the console, do not deviate
student-03-ec21301bfn6@ from the lab instructions. Doing so may cause your
account to be blocked Learn more. Congratulations!
Us«rname
Password
google2727e32_student®qwiklabs.r|
Password
Test your knowledge
k68CZXsxHZ
student-03-ec21301bf116@ |Q Congratulations!
GCP Project ID
qwiklabs-gcp-4fbfecac8667e457
Password
student-03-ec21301bf116@ |Q Congratulations!
Google
Password
3/17
Sign in
Test your knowledge
Use your Google Account
student-03-ec21301bfn6@ |Q Congratulations!
Password
Email or phone
Test your knowledge
student-03-ec21301bf116@
D Forgot email?
Congratulations!
Password
student-93-ec21301bf116@ |P Congratulations!
If you see the Choose an account page, click Use Another Account.
Password
Google
Test your knowledge
Choose an account
student-03-ec21381bf116e
D Congratulations!
Your.Email@gmail.com
Password
"
uiiito,8;<;hinfm- r 1
google1381214_student@qwiklabs.net Test your knowledge
Signed aul
student-03-ec21301bfn6@ |Q Congratulations!
Password
e[ Use another account
]
Test your knowledge
student-03-ec21301bf116@
D 3
. In the Sign in page, paste the username that you copied from the Connection Details Congratulations!
Password
panel. Then copy and paste the password.
Important: You must use the credentials from the Connection Details panel. Do not Test your knowledge
student-03-ec21301bf116@ |P use your Qwiklabs credentials. If you have your own Google Cloud account, do not Congratulations!
use it for this lab (avoids incurring charges).
Password
4
.
Click through the subsequent pages: Test your knowledge
student-03-ec21301bf116@
D Congratulations!
. Accept the terms and conditions .
Password
uiiito,8;<;hinfm- r
"
4 / 17
Password
Do not sign up for free trials.
After a few moments, the Cloud Console opens in this tab. Test your knowledge
student-e3-ec213eibf116@
Congratulations!
Password Note: You can view the menu with a list of Google Cloud Products and Services by clicking the
Navigation menu at the top-left.
Test your knowledge
student-e3-ec213eibf116@ Q Congratulations!
= Google Cloud Platform J«qwimab»-9cp-44776a13d«a687a6 » q, n o ©
Password
Home
DASHBOARD ACTIVITY / CUSTOMIZE
Password
I
Marketplace
Test your knowledge
student-e3-ec21301bf116@ Q Congratulations!
Click Continue.
Password
El Cloud Shell
Test your knowledge
student-03-ec21301bfn6@ |P Congratulations!
Google Cloud Shell provides you with command-line access to your cloud resources
directly from your browser. You can easily manage your projects and resources without
Password
having to install the Google Cloud SDK or other tools on your system. Learn more.
5/17
Password
"
uiiito,8;<;hinfm- r 1 Continue
Test your knowledge
Student-e3-ec21301bf116@ |P Congratulations!
It takes a few moments to provision and connect to the environment. When you are
Password
connected, you are already authenticated, and the project is set to your PROJECTJD.
For example: Test your knowledge
student-03-ec21301bf116@ |Q Congratulations!
g§ .< .abs-gcp-44776a13dea667a5) X +
Password
Welcome to Cloud Shell! Type "help" to get started.
Your Cloud Platform project in this session is set to q"iltlabs-gcp-44776«13dBa667a6.
Use "gcloud config set project lPROJECT ID]" to change to a different project.
_
student-03-ec21301bf116@ |P Congratulations!
gcloud is the command-line tool for Google Cloud. It comes pre-installed on Cloud
Password
Shell and supports tab-completion.
Test your knowledge
You can list the active account name with this command:
student-03-ec21301bf116@ |Q Congratulations!
Password
gcloud auth list
Test your knowledge
Password
Credentialed accounts:
Test your knowledge
-
googlel623327_student@qwiklabs.net
Password
You can list the project ID with this command: Test your knowledge
student-03-ec21381bf116@
D Congratulations!
gcloud config list project
Password
6/17
Test your knowledge
(Output)
student-03-ec21301bf116e |P Congratulations!
Password [core]
project = <project_ID>
Test your knowledge
student-03-ec21391bf116e jQ Congratulations!
(Example output)
Password
Password
student-03-ec213eibf116@ |P Congratulations!
Password
student-e3-ec21301bf116@ |P Congratulations!
Certain Compute Engine resources live in regions or zones. A region is a specific
Password geographical location where you can run your resources. Each region has one or
more zones. For example, the us-centrall region denotes a region in the Central
Test your knowledge
United States that has zones us-centrall-a, us-centrall-b, us-centrall-c,and
student-03-ec21301bf116@
D us-centrall-f. Congratulations!
Password
I I I I I Congratulations!
' ' '
us-westl-b asia-eastl-b
' ' ' ' ' ' '
student-03-ec21301bf116e |P Congratulations!
Password
"
Resources that live in a zone are referred to as zonal resources. Virtual machine
uBaaatfL0 " r 1
Test your knowledge
Instances and persistent disks live in a zone. To attach a persistent disk to a virtual
Student-e3-ec21301bf116@
machine instance, both resources must be in the same zone. Similarly, if you want to Congratulations!
assign a static IP address to an instance, the instance must be in the same region as
Password
the static IP.
7/17
Test your knowledge I
student-93-ec21301bf116@ |P Congratu,ations!
Learn more about regions and zones and see a complete list in Regions & Zones
Password documentation.
student-03-ec21301bf116e [Q Congratulations!
Password
iJ8a3jiBRiCM'VFmo
Test your knowledge
student-03-ec21301bf116@
D Congratulations!
Password
Create a new instance from the Cloud
Console
Test your knowledge
student-03-ec21301bf116@ |Q Congratulations!
in this section, you'll learn how to create new pre-defined machine types with
Password
Compute Engine from the Cloud Console.
Test your knowledge
student-03-ec21301bf116@
In the Cloud Console, on the top left of the screen, select Navigation menu >
Congratulations!
Compute Engine > VM instances:
Password
student-03-ec21301bf116e [Q Congratulations!
fmf Compute Engine VM in
Password
VM instances
Test your knowledge
student-03-ec21301bf116e
D Congratulations!
Password This may take a minute to initialize for the first time.
student-03-ec21301bf116@ |Q Congratulations!
Password
Compute Engine
VM instances Test your knowledge
student-03-ec21301bf116@
Congratulations!
8/17
Password
Password
There are many parameters you can configure when creating a new instance. Use the Test your knowledge
student-03-ec21391bf116e
C following for this lab: Congratulations!
Password
Field Value Additional Information
Password
selected, you ll need it later.
Password
This is a (nl-standard-2),
Note: A new project has a default resource quota, Test your knowledge
2-CPU 7.5GB RAM instance.
,
Machine which may limit the number of CPU cores. You
student-03-ec21301bf116@
c Congratulations!
Type can request more when you work on projects
There are a number of machine
outside of this lab.
Password
types, ranging from micro instance
types to 32-core/208GB RAM
Test your knowledge
instance types. Learn more in the
Student-e3-ec21301bf116@ |P Machine Types documentation. Congratulations!
9 / 17
UISK
student-03-ec21301bf116@
C OS Image: Debian Linux and Windows Server. See Operating System Congratulations!
GNU/Linux 9 (stretch) documentation for more detail.
Password
Note: This will automatically create firewall rule Test your knowledge
Firewa
student-93-ec21301bf116@ |P Check this option so to access a
'
to allow HTTP traffic on port 80.
Congratulations!
webserver that you ll install later.
Password
Click Create.
Test your knowledge
student-03-ec21301bf116@
D Congratulations!
Wait for it to finish - it shouldn't take more than a minute.
Password
Once finished, you should see the new virtual machine in the VM Instances page.
Test your knowledge
student-03-ec21301bf116@
To SSH into the virtual machine, click on SSH on the right hand side. This launches a Congratulations!
Password
Password
Now you'll install NGINX web server, one of the most popular web servers in the
Test your knowledge
world, to connect your virtual machine to something.
student-03-ec21301bf116@
Congratulations!
Once SSH'ed, get root access using sudo:
Password
sudo su -
Test your knowledge
student-03-ec21301bf116@
C Congratulations!
10/17
Test your knowledge
apt-get update
student-03-ec21301bf116@ |P Congratulations!
Password
(Output)
Test your knowledge
student-e3-ec213eibfn6@
D Get:! http://security.debian.org stretch/updates InRelease [94.3 kB] Congratulations!
Ign http://deb.debian.org strech InRelease
Password
Get:2 http://deb.debian.org strech-updates InRelease [91.0 kB]
student-03-ec21391bf116e |P Congratulations!
Install NGINX:
Password
student-e3-ec21301bf116@ |P Congratulations!
Password
(Output)
student-03-ec21301bf116@ |P Congratulations!
Check that NGINX is running:
Password
Password
(Output)
11 / 17
Awesome! To see the web page, go to the Cloud Console and click the External IP Test your knowledge
student-e3-ec21301bf116@ |Q link of the virtual machine instance. You can also see the web page by adding the Congratulations!
External IP to http: / /EXTERNAI IP/ in a new browser window or tab.
Password
Student-e3-ec21301bf116@ |P Congratulations!
Password
You should see this default web page:
Test your knowledge
student-e3-ec21301bf116@ |P Congratulations!
Welcome to nginxl
Password
If you see this page, the nginx web server is successfully installed and
working. Further configuration is required. Test your knowledge
student-03-ec21301bf116@ |Q For online documentation and support please refer to nainx.orci. Congratulations!
Commercial support is available at nginx.com.
Password
student-03-ec21301bf116@ |P Congratulations!
To check your progress in this lab, click Check my progress below. A checkmark
Password '
student-03-ec21301bf116@ |Q Congratulations!
Create a Compute Engine instance and add Nginx Server to your instance
Password
with necessary firewall rules.
Check my progress
Test your knowledge
student-03-ec21301bf116@
Congratulations!
Password
student-03-ec21301bf116@ |Q Congratulations!
12 / 17
Password
student-03-ec21301bf116@ |Q Congratulations!
Rather than using the Cloud Console to create a virtual machine instance, you can
Password
use the command line tool gcloud, which is pre-installed in Google Cloud Shell.
Cloud Shell is a Debian-based virtual machine loaded with all the development tools Test your knowledge
need (gcloud, git and others) and offers a persistent 5GB home directory.
'
student-03-ec21301bf116@
iD you ll ,
Congratulations!
Password
If you want to try this on your own machine in the future, read the gcloud
command line tool guide. Test your knowledge
student-e3-ec21301bf116@ |P Congratulations!
Password
In the Cloud Shell, create a new virtual machine instance from the command line
Test your knowledge
using gcloud:
student-03-ec21301bf116@
D Congratulations!
student-03-ec21301bf116@ |Q Congratulations!
(Output)
Password
Password
Click Check my progress below to verify you're on track in this lab. Test your knowledge
student-03-ec21301bf116@ |P Congratulations!
Password
Create a new instance with gcloud.
Check my progress
Test your knowledge
student-03-ec21301bf116e
D Congratulations!
Password
machine types if you d like: nl-highmem-4 or nl-highcpu-4. When you're
working on a project outside of Qwiklabs, you can also specify a custom machine
Test your knowledge
type.
student-03-ec21301bf116@
. A root persistent disk with the same name as the instance; the disk is Congratulations!
automatically attached to the instance.
Password
Run gcloud compute instances create --help to see all the defaults. Test your knowledge
student-03-ec21301bf116@
C Congratulations!
Password Note: You can set the default region and zones that gcloud uses if you are
always working within one region/zone and you don t want to append the --
'
Password
ugiito,R;Chln<:m'-
Name A Zone Recommendation Internal IP Eirternal IP Connect
Test your knowledge
student-93-ec21301bf116@ |P fi» gcelab us-cenuall-c 10.128 0 2 (nicO) 104.155 128 223 [i- SSH . ;
Congratulations!
Gl gcelab2 us-cemrall-c 10.128.0.3 (nicO) 1041S4.1S2.174 SSH . .
Password
Password
14/17
gcloud compute ssh gcelab2 --zone us-centrall-c Test your knowledge
student-03-ec21301bf116@ |P Congratulations!
(Output)
Password
Password
Password
Password
exit
Student-e3-ec213eibf116@ |P Congratulations!
Password
student-93-ec21301bf116@ |P Congratulations!
15 / 17
Password
Password
>/ Through web console.
Test your knowledge
«/ The gcloud command line tool .
student-03-ec213eibf116@ |Q Congratulations!
Submit
Password
Password
Password
Congratulations!
Compute Engine is the foundation to Google Cloud's Infrastructure-as-a-Service. You Test your knowledge
Student-e3-ec21301bf116@ |P created a virtual machine with Compute Engine and can now map your existing Congratulations!
server infrastructure, load balancers, and network topology to Google Cloud.
Password
student-03-ec213eibf116@ |Q Congratulations!
Password
Password
Finish Your Quest
Test your knowledge
student-93-ec21301bf116@ This self-paced lab is part of the Qwiklab Google Cloud Essentials Quest. A Quest is
Congratulations!
a series of related labs that form a learning path. Completing a Quest earns you a
Password
badge to recognize your achievement. You can make your badge (or badges) public
and link to them in your online resume or social media account. Enroll in this Quest Test your knowledge n
16/17
and get immediate completion credit if you ve taken this lab. See other available
'
Student-e3-ec213eibfll6@
D Congratulations!
Qwiklabs Quests.
Password
1 I
,
. Getting Started with Cloud Shell & gcloud Test your knowledge
student-e3-ec213ei bf 116@
6 Congratulations!
. Provision Services with Google Cloud Marketplace
Password
, i I
Test your knowledge
student-e3-ec213eibfn6@
0 Next Steps / Learn More
Congratulations!
Password
. For an overview of VMs see Virtual Machine Instances.
,
Congratulations!
. And then be sure to choose the right VM type by reviewing Choosing a VM
Password Machine.
Congratulations!
Password technical skills and best practices to help you get up to speed quickly and continue
your learning journey. We offer fundamental to advanced level training, with on-
B22w8SNQfms
C
demand, live, and virtual options to suit your busy schedule. Certificatic help you
GCP Project ID validate and prove your skill and expertise in Google Cloud technologies.
qwiklabs-gcp-e3-7646ecd7 |Q
Manual Last Updated: September 8, 2020
Lab Last Tested: September 8, 2020
Student Resources Copyright 2020 Google LLC All rights reserved. Google and the Google logo are
trademarks of Google LLC. All other company and product names may be
< Create a Virtual Machine, GCP
Essentials trademarks of the respective companies with which they are associated.
Chat
17 / 17