Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstalliTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
To install NGINX on a Google Cloud server, create or select a Linux Compute Engine virtual machine, allow TCP port 80 for HTTP, connect with SSH, and run sudo apt-get update followed by sudo apt-get install -y nginx. Verify the service locally, then open the VM’s external IP address in a browser. If local access works but the external address does not, the usual cause is a missing VPC firewall rule or a network-tag mismatch.
This guide covers the complete path from VM creation through firewall troubleshooting, HTTPS preparation, repeatable startup-script provisioning, and the distinction between the open-source NGINX package and the separately licensed NGINX Plus offering.
What are you installing on Google Cloud?
NGINX runs on a Linux Compute Engine VM in this setup. Google Cloud supplies the virtual machine, network interface, VPC firewall, and optional external IP; the Linux distribution supplies NGINX through its package manager. The commands below use Debian or Ubuntu-style images and the APT package manager.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →There are two separate paths to a working website:
- Software path: install and start the NGINX service inside the VM.
- Network path: permit traffic to the VM through a Google Cloud VPC firewall rule and give the VM a reachable address.
Completing only the software path produces a server that answers locally but may be invisible from the internet. Completing only the network path opens a port without placing a web server behind it.
#1 Best Overall
- Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
- Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
- Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
- Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
- 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
What do you need before installing NGINX?
Prepare these items before you begin:
- A Google Cloud project with permission to create Compute Engine instances and change VPC firewall settings.
- A Linux VM image, such as a Debian or Ubuntu family image.
- An SSH method: the Google Cloud Console SSH button, the
gcloudCLI, or another configured SSH client. - A public external IP if people on the internet must reach the site directly.
- A decision about exposure. Public HTTP normally uses TCP 80 from the internet; a private service should use narrower source ranges instead of opening the port globally.
A temporary or ephemeral external address is adequate for a test. A production DNS record normally requires an address whose value will not change when the VM is stopped, deleted, or recreated; reserve and attach a static external address through Google Cloud when that stability is required.
How do you create the VM and open HTTP?
During VM creation, enable the Google Cloud options that create the standard web-server firewall access. The exact console layout can change, but the relevant controls are labeled Allow HTTP traffic and Allow HTTPS traffic.
- Open Compute Engine and choose to create an instance, or select an existing Linux instance.
- Choose the project, region, zone, machine type, boot disk, and Linux image appropriate for your workload.
- Ensure the instance receives a public external IP when direct internet access is required.
- Enable Allow HTTP traffic. Google Cloud maps this option to ingress TCP port 80.
- Enable Allow HTTPS traffic only when you intend to configure TLS on the VM or otherwise terminate HTTPS there. This option maps to TCP port 443.
- Create the VM and wait until its status is running.
| Console option | Port | Use it when | Important limitation |
|---|---|---|---|
| Allow HTTP traffic | TCP 80 | You will serve ordinary HTTP or use HTTP while obtaining a certificate. | It does not configure NGINX or TLS. |
| Allow HTTPS traffic | TCP 443 | NGINX is configured with a certificate and should accept HTTPS. | Opening 443 alone does not create an HTTPS site. |
These checkboxes commonly target a network tag such as http-server or https-server. The firewall rule applies only to VM interfaces carrying the tag selected by the rule. If you create your own rule, record both its target tag and the VM’s tags so you can compare them during troubleshooting.
Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Scan for outdated or missing drivers - takes under a minute3Repair Windows errors before they cause bigger problemsHow do you install NGINX over SSH?
After the VM is running, connect to it with SSH and update the package index before installing. Updating first ensures APT sees current package metadata from the configured repositories.
- In the Compute Engine VM list, click the SSH action for the Linux instance, or connect with your configured SSH command.
- Refresh package metadata:
sudo apt-get update
- Install the distribution NGINX package:
sudo apt-get install -y nginx
The package installation normally creates a systemd service named nginx. On a standard Debian-family image, the package starts the service as part of installation. Explicitly enable and start it if you want to make the desired state clear:
sudo systemctl enable --now nginx
If your VM uses a distribution other than Debian or Ubuntu, use that distribution’s package manager and service conventions rather than copying APT commands unchanged. The Google Cloud workflow remains the same: install the package, confirm the service, test locally, and then test through the external address.
How do you verify that NGINX is running?
Use a process check, a systemd status check, and an HTTP request. Each test answers a different question.
Rank #2
- 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
- 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
- Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
- 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
- What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
Check the NGINX process
ps auwx | grep nginx
You should see a master process and one or more worker processes. The grep command itself may also appear; that line alone is not evidence that NGINX is active.
Inspect the service state
sudo systemctl status nginx
Look for an active, running state. If systemd reports a failure, read the error text, correct the configuration or port conflict it identifies, and then run sudo systemctl restart nginx.
Test the local web listener
curl -I http://127.0.0.1
A response such as HTTP/1.1 200 OK or a normal NGINX redirect confirms that the VM can reach its own web service. A failure here is an NGINX, package, configuration, or local firewall problem—not a Google Cloud internet-routing problem.
Test the external address
Find the VM’s external IPv4 address in the Compute Engine details page and substitute it for EXTERNAL_IP:
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →curl -I http://EXTERNAL_IP
You can also enter http://EXTERNAL_IP in a browser. A default NGINX page indicates that the request reached the VM and that NGINX is serving its initial site. If the local request succeeds but this external request times out, continue with the firewall checks below.
Why can’t you reach NGINX by the external IP?
When curl -I http://127.0.0.1 works but an external request fails, check the Google Cloud path in this order.
1. Confirm that the address belongs to this VM
Copy the current external IPv4 address from the instance details rather than relying on an old browser bookmark or DNS record. An ephemeral address can change after lifecycle operations. Also confirm that the VM is running and that you are using http:// with port 80, not an unconfigured HTTPS URL.
Rank #3
- Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
- Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
- Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
- Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
- What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
2. Confirm the VPC firewall rule
The rule must allow ingress TCP 80 from the source ranges that should use the site. A public web server commonly uses 0.0.0.0/0, which means any IPv4 source, but that is broader than necessary for a private or administrative service. For a restricted service, replace the public range with the organization’s application, office, VPN, or load-balancer ranges.
3. Confirm the target network tag
Google Cloud’s web-server guidance requires the VM to carry the network tag targeted by the firewall rule. If the rule targets http-server but the VM has no matching tag, the rule does not apply. Add the correct tag to the VM or change the rule target, then retry the external request.
4. Check the guest operating system
A local success normally means NGINX is listening, but a host-level firewall or a custom NGINX listen directive can still restrict access. Inspect the active configuration and confirm that NGINX listens on the VM interface, not only on loopback. After any edit, validate and reload:
sudo nginx -t
sudo systemctl reload nginx
5. Distinguish a timeout from an HTTP error
- Timeout or no route: investigate the external IP, VPC firewall rule, target tag, subnet route, and any guest firewall.
- Connection refused: verify that NGINX is running and listening on port 80.
- HTTP 403 or 404: networking works; inspect the NGINX server block, document root, and file permissions.
- Unexpected default page: the request reached NGINX, but the intended server block or content has not been configured.
How do you automate installation with a startup script?
A Compute Engine Linux startup script is a file of commands that runs when a VM boots. When supplied through supported metadata methods, Compute Engine copies the script to the VM, makes it executable, and runs it as root. Public Compute Engine images include the guest environment needed to process this metadata.
Write the script
Create a file named nginx-startup.sh with the following contents:
#!/bin/bash
apt-get update
apt-get install -y nginx
systemctl enable --now nginx
The commands intentionally omit sudo because startup scripts run with root privileges. The script installs on boot, enables the service for later starts, and starts it immediately after installation.
Supply the script in the console
In the VM creation form, expand the advanced or management settings and locate the startup-script metadata field. Paste the complete script, including the #!/bin/bash line, then create the instance. Keep the HTTP firewall option enabled if the newly provisioned VM must be reachable on port 80.
Rank #4
- Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
- Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
- Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
- Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
- Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
Supply the script with gcloud
For a local file, use a command shaped like this:
gcloud compute instances create nginx-vm
--zone=ZONE
--image-family=debian-12
--image-project=debian-cloud
--tags=http-server
--metadata-from-file=startup-script=nginx-startup.sh
ZONE is a deployment-time value, not a literal universal zone. Confirm the current Debian image family, project, zone, and CLI syntax for the project you are using. The http-server tag must correspond to a VPC firewall rule that permits TCP 80; adding a tag by itself does not open a port.
Use Cloud Storage for larger scripts
Google Cloud also supports startup scripts stored in Cloud Storage. This is useful when a script is too large or is maintained as a separate deployment artifact. Give the VM service account permission to read the object, reference the object using the supported metadata option, and test the boot log on a non-production instance before rolling it out broadly.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Check whether provisioning completed
Connect over SSH after the VM reports running and repeat the process, service, and local HTTP checks. If installation did not complete, inspect the guest startup-script output and system logs, then verify that the VM had network access to the package repositories during boot. A startup script is not a replacement for a firewall rule: it installs software, while the VPC rule controls whether clients can reach it.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.How do you configure NGINX after the default page works?
The default page proves the installation path, not the final application configuration. Before replacing it, keep a way back to the known-good state and make one change at a time.
Validate every configuration change
sudo nginx -t
Only reload after the test reports a valid configuration:
sudo systemctl reload nginx
A reload applies configuration without unnecessarily terminating existing connections. Use a restart when a package or system change requires it, or when reload cannot recover from the current service state.
Free tools Windows power users keep installed
One-click scans. No signup required.
Separate sites and application content
For a static site, point a server block at the intended document root and ensure the NGINX worker can read the files. For an application server, proxy requests to the application’s private listening address rather than exposing that application port directly to the internet. Keep the VPC firewall limited to the ports clients actually need.
Best Value
- 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
- Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
- Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
- HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
- What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
Use logs to diagnose application-level failures
Once a request reaches NGINX, access and error logs explain status codes, missing files, permission errors, and upstream failures. A successful local request to the default site does not validate a new server block, proxy target, or domain-name match; test each hostname and path after configuration.
When should you open TCP 443?
Open TCP 443 after you have configured TLS in NGINX and have a certificate and private key available to the VM. The Google Cloud firewall option permits traffic; it does not issue certificates, install keys, or convert HTTP into HTTPS.
A common rollout sequence is to keep port 80 available for initial validation and certificate challenges, configure an HTTPS server block that listens on 443, test with sudo nginx -t, reload NGINX, and then verify both the certificate and redirect behavior from an external client. Do not describe a site as HTTPS merely because the 443 rule exists.
What is the difference between open-source NGINX and NGINX Plus?
The distribution package is the simplest baseline for a normal web server and is sufficient for the installation described here. NGINX Plus is a separate enterprise deployment option documented for Google Cloud Compute Engine; it is not required to install or serve a basic site.
| Area | Open-source NGINX package | NGINX Plus |
|---|---|---|
| Typical starting point | General web serving, reverse proxying, and static content. | Enterprise deployments that need the Plus feature set and support model. |
| Licensing | Open-source software distributed through the Linux image’s package repositories. | Separately licensed commercial software. |
| Installation source | Distribution package manager, such as APT on Debian-family images. | A separately documented Google Cloud Compute Engine image or enterprise installation path. |
| Initial behavior | Install and manage the nginx systemd service yourself or through the package defaults. |
F5 documentation states that the deployed VM starts NGINX Plus automatically and serves a default index.html page. |
| Support and tooling | Community and distribution documentation, with updates following the package source. | Commercial support and enterprise operational features under its license. |
Choose the open-source package unless a documented enterprise requirement justifies the separate product, licensing, and operational process. Do not mix package instructions for one edition with image instructions for the other.
What should you check before calling the deployment complete?
- The VM is a Linux Compute Engine instance with the intended image and zone.
- A public external IP is attached if the site is meant for internet users.
- NGINX is installed, its process exists, and
systemctl status nginxreports an active service. curl -I http://127.0.0.1returns an HTTP response.curl -I http://EXTERNAL_IPworks from a client outside the VM.- The TCP 80 firewall rule has the correct source range and targets a tag present on the VM.
- TCP 443 is opened only after TLS is configured.
- Any startup script has been tested, and its image family, zone, metadata method, and service-account permissions are valid.
- Custom NGINX configuration passes
sudo nginx -tbefore reload.
Frequently Asked Questions
Can NGINX run on a Google Cloud VM without a public external IP?
Yes. A VM without a public address can serve internal clients through its private address, an internal load balancer, VPN, or another private connectivity method. Direct requests from the public internet require a public ingress design, not merely an NGINX installation.
Does a Compute Engine startup script run again after every reboot?
Linux startup scripts are processed during VM boot, so design the script to be safe when it runs more than once. Package installation commands should be repeatable, and application-specific setup should avoid overwriting configuration or data on later boots.
How can I keep the website’s external IP from changing?
Use a reserved static external IP address and attach it to the VM or the production load-balancing design. Update DNS only after the stable address is in place, and release unused reservations so they do not remain assigned to the project.
What should I do if the package installation cannot reach Debian repositories?
Check that the VM has a usable route and outbound connectivity, then review DNS resolution and any organization-level egress policy. A startup script can fail before NGINX is installed if boot-time networking or repository access is unavailable; rerun the installation after connectivity is restored.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

