Understanding Internal and External IP Addresses V2 | Scribe

    Understanding Internal and External IP Addresses V2

    • Hafeez Baig |
    • 13 steps |
    • 2 minutes
    information ordinal icon
    Refer to this guide to learn how to create a Virtual Machine in GCP\ <https://scribehow.com/shared/Creating_your_first_Virtual_Machine_in_GCP__dF2VjMksT5en6PowYws7lQ> Refer to this guide to learn how to Install HTTP WebServer on a Virtual Machine in GCP<https://scribehow.com/shared/Installing_HTTP_Webserver_on_Google_Compute_Engine_Virtual_Machine__RCjtAN8xTAm6_ZvYcUD8vQ>
    1
    Sign in into the **Google Cloud Platform**
    2
    Type "**Compute Engine**" in the search bar and click on the **Compute Engine** option
    information ordinal icon
    **What is a Compute Engine?** Google Compute Engine (GCE) is an Infrastructure-as-a-Service (IaaS) offering from Google Cloud Platform (GCP) that allows users to run virtual machines (VMs) on Google's infrastructure. It provides scalable and flexible computing resources, high-performance persistent storage, advanced networking capabilities, and integration with other GCP services, making it suitable for a variety of workloads including web hosting, data processing, and high-performance computing.
    3
    **VM instances** wizard will open. Scroll to the **Internal IP** section, here you can see that the **Internal** and **External** IP are visible **Note:** Make sure the VM Instance is running state
    information ordinal icon
    **What is Internal IP in GCP?**\ \ This is an IP address assigned to an instance within a Virtual Private Cloud (VPC) network that is used for communication within the same VPC network or between VPC networks connected via VPC peering or VPN. Internal IPs are typically used for internal communication and are not accessible directly from the internet. \ **What is External IP in GCP?**\ \ This is an IP address assigned to an instance that allows it to communicate directly over the internet. External IPs can be ephemeral (dynamic, changing upon restart) or static (reserved and persistent). They are used for external-facing services such as web servers, APIs, or any service that needs to be accessed from the internet.
    4
    To stop the VM instance, checkbox the **my-first-vm** VM instance
    5
    Click on the three dots on the right side and select the **Stop** option
    6
    **Stop my-first-vm** wizard will open, click on the **STOP** button **Note:** The instance will take some time to stop.
    7
    After the instance is stopped, you will see that the **External IP** is no longer available and only the **Internal IP** is available
    information ordinal icon
    **Why is the internal IP address still visible and not the external IP address after the VM is stopped in the Google Cloud Platform?**\ \ In the Google Cloud Platform, internal IP addresses remain visible even when a VM is stopped because they are assigned within the Virtual Private Cloud (VPC) network and are used for internal communication between resources. External IP addresses, however, are released when the VM is stopped unless they are reserved as static IPs, ensuring cost-effective use of IP resources.
    8
    To start the VM instance, click on the three dots on the right side and select the **Start / Resume** option
    9
    **Start my-first-vm** wizard will open, click on the **START** button **Note:** The instance will take some time to start.
    10
    After the VM instance successfully starts, scroll to the **External IP** section. Here, you will see that the **External IP** address is now available but is different from the previous IP address
    information ordinal icon
    **Why does the external IP address change from the previous IP in the Google Cloud Platform?**\ \ External IP addresses in the Google Cloud Platform can change when a VM instance is stopped and restarted unless a static IP address is reserved. This dynamic allocation helps optimize resource usage and IP address management within GCP.
    11
    To view the webpage, on the **External IP** section click on the copy widget to copy the IP address
    12
    Open the new tab in the browser and paste the copied **External IP** address
    13
    **Hello World from my-first-vm 10.128.0.2** will be displayed
    information ordinal icon
    Congratulations on completing this lab and Understanding Internal and External IP Address V2 in Google Cloud Platform