GCP Cloud Digital Leader Certification
GCP Compute Part 1
Demo Compute 02 2
Welcome to this lesson on connecting to and managing your compute instance. In our previous lesson, we explored the creation of compute instances and examined their key features. In this article, we will dive into various options for connecting to a compute instance, accessing its terminal, and managing its lifecycle—including how to stop and delete an instance.
Accessing Your Virtual Machine
To connect to a specific compute instance, click on the SSH option provided in the instance list. This action opens a new browser tab with an instantaneous terminal session, allowing you to interact directly with the virtual machine.
Once connected via SSH, you will see a terminal interface where you can execute Linux commands and inspect system details.
Managing Your Compute Instance
Stopping the Instance
To stop the virtual machine, click on the three-dot menu associated with the instance and select the "Stop" option. This action safely shuts down your VM, and you can later choose to delete the instance if it is no longer needed.
Monitoring Performance
For performance monitoring, click on the "View Monitoring" option. This takes you to a dedicated page where you can review vital statistics, including CPU usage, memory consumption, running processes, and other essential metrics. The monitoring page also categorizes logs by severity level, assisting you in troubleshooting any issues.
To return to the main dashboard, simply click on "VM Instances" in the left-hand navigation menu.
Deleting the Instance
When you are finished, you might want to clean up unused resources. To delete the virtual machine, open the three-dot menu again, select "Delete," and confirm your action.
Note
If you're utilizing a free trial, be aware that the time spent on the virtual machine counts against your trial resources. For non-trial users, charges may apply based on the usage duration. We highly recommend deleting unused virtual machines promptly to avoid unexpected billing.
Conclusion
This lesson covered the essential steps for connecting to and managing your compute instance, including accessing the terminal, monitoring performance, and safely stopping or deleting your VM. Following these guidelines will help you maintain an organized and resource-efficient environment.
Thank you for reading. We look forward to guiding you in our next article.
Watch Video
Watch video content