Project owners, editors, and IAM members with the Network Admin role can delete Cloud VPN tunnels.
Deleting a VPN tunnel
To delete an existing Cloud VPN tunnel, do the following:
- Go to the VPN tunnels page.
- Place a check in the box next to the VPN tunnel you need to remove.
- At the top of the screen, click Delete.
- Click Delete again when asked to confirm.
In the following commands, replace
[PROJECT_ID] with the ID of your
- Identify the name and region of the VPN tunnel you need to remove. You can gather this information using one of two methods:
To list all VPN tunnels in your project:
<pre class="devsite-click-to-copy"> gcloud compute vpn-tunnels list --project [PROJECT_ID] </pre>
If you know the name of the VPN gateway that contains the tunnel, you
can retrieve the list of its associated tunnels by using this command,
[GW_NAME] with the name of the gateway and
its region (the same region of the tunnel):
<pre class="devsite-click-to-copy"> gcloud compute target-vpn-gateways describe [GW_NAME] \ --region [REGION] \ --project [PROJECT_ID] \ --format='flattened(tunnels)' </pre>
Once you identify the VPN tunnel, replace
its name and region in the following steps.
Delete the tunnel using this command:
gcloud compute vpn-tunnels delete [NAME] \ --region [REGION] \ --project [PROJECT_ID]
After deleting a VPN tunnel, consider the following:
Review your firewall rules and delete the rules that you no longer need.
If the tunnel used policy based routing or was a route based VPN, you should review the routes in your GCP network and delete any static routes that you no longer need.
If you used the GCP Console to delete the tunnel, static routes that were automatically created should already be removed. If you used
gcloudto remove the tunnel, or if you created custom static routes for it, you will need to delete those manually.
If no more tunnels exist for the associated VPN gateway, you can delete the VPN gateway as well.
- Learn about the basic concepts of Cloud VPN
- Create a custom Virtual Private Cloud network
- Set up different types of Cloud VPN
- Maintain VPN tunnels and gateways
- See Advanced Configurations for information on high-availability, high-throughput scenarios, or multiple subnet scenarios.
- Get troubleshooting help