- Andreas Bartel
- May 18, 2021
How to Create internet-facing Network(TCP) layer load balancer on Google Cloud Platform.
Google Cloud external TCP/UDP Network Load Balancing (after this referred to as Network Load Balancing) is a regional, pass-through load balancer. A network load balancer distributes TCP or UDP traffic among virtual machine (VM) instances in the same region.
A network load balancer can receive traffic from:
- Any client on the internet
- Google Cloud VMs with external IPs
- Google Cloud VMs that have internet access through Cloud NAT or instance-based NAT.
- Login to google cloud platform portal.
- Click on Network services.
- Select Load balancing.
- Click on Create load balancer.
- Select TCP Load Balancing.
- Click on Start Configuration.
- Select internet-facing load balancer.
- Select Single Region only.
- Select Target Pool or Backend service as a backend type.
Target Pool
- If select Target pool as a backend type then click on continue.
- Provide the TCP load balancer name.
- Click on Backend configuration.
- Provide the backend configuration name.
- Select Region.
- Select existing instance group or Firstly create instance group so click on link https://www.hackerxone.com/blog/how-create-instance-group-autoscaling-google-cloud-platform for how to create instance group.
- Click on Backend pool.
- Provide the target pool name.
- Select existing instance group name.
- Select existing health check or create new so click on link https://www.hackerxone.com/blog/how-create-health-check-google-cloud-platform for how to create health check.
- Then click on Save & continue.
- At backend configuration page select create or existing health check & select session affinity.
- Click on Create a health check,
- Select existing health check or create new so click on link https://www.hackerxone.com/blog/how-create-health-check-google-cloud-platform for how to create health check.
- Then click on Save & continue.
- Next click on frontend configuration.
- Provide frontend configuration name.
- Select Standard or Premium Network service tier.
- Provide port number.
- Click on Done.
- Click on Review & Finalize.
- Click on Create.
Backend Service
- If select backend service as a backend type then click on continue.
- Provide TCP load balancer name.
- Click on backend configuration.
- Provide the backend configuration name.
- Select Region.
- If needs to add more backends so click on Add backends.
- Select existing instance group or Firstly create instance group so click on link https://www.hackerxone.com/blog/how-create-instance-group-autoscaling-google-cloud-platform for how to create instance group.
- Click on Done.
- Click on Health check.
- Select existing health check or create new so click on link https://www.hackerxone.com/blog/how-create-health-check-google-cloud-platform for how to create health check.
- Then click on Save & continue.
- Next click on frontend configuration.
- Provide the frontend configuration name.
- Select Standard or Premium Network Service tier.
- Provide port numbers.
- Click on Done.
- Next click on Review & Finalize.
- Click on Create.
- After sometime TCP load balancer is ready then go to load balancing home page.
- TCP Load Balancer is there with the name we provide.