Working with Compute Engine Windows Instances

Hands-On Lab

 

Photo of Joseph Lowery

Joseph Lowery

Google Cloud Training Architect II in Content

Length

00:30:00

Difficulty

Beginner

Compute Engine VM instances can utilize a wide range of boot disks; Google Cloud currently offers well over 50 disk images to choose from. Cloud computing professionals must be adept in spinning up a variety of operating systems, including Windows server. In this hands-on lab, you’ll experience the creation of a Windows-based Compute Engine VM instance, set up an IIS server, and push your first web page live to confirm the server’s operation.

What are Hands-On Labs?

Hands-On Labs are scenario-based learning environments where learners can practice without consequences. Don't compromise a system or waste money on expensive downloads. Practice real-world skills without the real-world risk, no assembly required.

Working with Compute Engine Windows Instances

In this hands-on lab, we’ll experience the creation of a Windows-based Compute Engine VM instance, set up an IIS server, and push our first web page live to confirm the server’s operation.

How to Log in to Google Lab Accounts

On the lab page, right-click Open GCP Console and select the option to open it in a new private browser window (this option will read differently depending on your browser — e.g., in Chrome, it says "Open Link in Incognito Window"). Then, sign in to Google Cloud Platform using the credentials provided on the lab page.

On the Welcome to your new account screen, review the text, and click Accept. In the "Welcome L.A.!" pop-up once you're signed in, check to agree to the terms of service, choose your country of residence, and click Agree and Continue.

Working with Compute Engine Windows Instances

Now, on to the lab!

Create a Compute Engine VM instance.

  1. From the main navigation, choose Compute Engine > VMs.
  2. Click Create.
  3. With New VM instance chosen from the options on the left, configure your instance:
    • Name: Provide a relevant name using hyphens, like "la-windows-1".
    • Region Leave as-is
    • Zone: Leave as-is
    • Machine type: Leave as-is
    • Boot disk:
      • Click Change.
      • Select Windows Server 2019 Datacenter, Server with Desktop Experience.
      • Click Select.
    • Identity and API access: Leave as-is
    • Firewall: Allow HTTP traffic
  4. Click Create.

Set Windows password.

  1. Once the instance is created, click the arrow next to RDP in the Connect column, and select Set Windows password from the dropdown.
  2. In the dialog, confirm your username is correct, and click Set.
  3. Copy the supplied password, and click Close.

Launch RDP window.

  1. Launch the RDP window by using one of the following methods:
    • If you're on a Windows system, click RDP.
    • If you're on a Mac using Chrome in a standard window, first install the Chrome RDP extension, and then click RDP.
    • If you're on a Mac using another browser or incognito window, from the App Store, download and install the latest version of the Microsoft Remote Desktop app. Then, choose Download the RDP file from the RDP options and open the file.

Install IIS.

  1. From the Windows Start menu, right-click on Windows Powershell, choose More and then Run as administrator.

  2. In the PowerShell window, enter the following commands to set install IIS, starting with:

    import-module servermanager
  3. Set up the web server:

    add-windowsfeature web-server -includeallsubfeature
  4. Create the index.html page:

    echo '<!doctype html><html><body><h1>Greetings from Linux Academy!</h1></body></html>' > C:inetpubwwwrootindex.html

Test your page.

  1. From the Compute Engine VM instances page, click the external IP link for the Windows VM instance.
  2. Review the page in the browser.

Conclusion

Congratulations on completing this lab!