Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
VMware Engine-Netzwerk erstellen
In diesem Dokument wird beschrieben, wie Sie ein Standard-VMware Engine-Netzwerk über das VMware Engine-Portal, die gcloud CLI oder die API erstellen. Es können mehrere VMware Engine-Netzwerke erstellt werden, um private Clouds zu isolieren und eindeutige VPC-Netzwerk-Peerings zu definieren. VMware Engine-Netzwerke verwalten Verbindungen zu und von privaten Clouds gemäß einer Netzwerkrichtlinie, die separat definiert wird.
Hinweise
Anforderungen an die Google Cloud CLI und API
Wenn Sie das gcloud-Befehlszeilentool oder die API zum Verwalten Ihrer VMware Engine-Ressourcen verwenden möchten, empfehlen wir, die Tools wie unten beschrieben zu konfigurieren.
In den API-Beispielen in diesem Dokumentensatz wird die API mit dem cURL-Befehlszeilentool abgefragt. Für die cURL-Anfrage ist ein gültiges Zugriffstoken erforderlich. Es gibt viele Möglichkeiten, ein gültiges Zugriffstoken zu erhalten. In den folgenden Schritten wird das Tool gcloud verwendet, um ein Zugriffstoken zu generieren:
In Google Cloudanmelden:
gcloud auth login
Zugriffstoken generieren und in TOKEN exportieren:
export TOKEN=`gcloud auth print-access-token`
Prüfen Sie, ob TOKEN richtig festgelegt ist:
echo $TOKEN
Verwenden Sie das Autorisierungstoken jetzt in Ihren Anfragen an die API. Beispiel:
In den Python-Codebeispielen in dieser Dokumentation wird die VMware Engine-Bibliothek verwendet, um mit der API zu kommunizieren. Damit dieser Ansatz verwendet werden kann, muss die Bibliothek installiert und die Standardanmeldedaten für Anwendungen konfiguriert sein.
Laden Sie die Python-Bibliothek herunter und installieren Sie sie:
pip install google-cloud-vmwareengine
Konfigurieren Sie die ADC-Informationen, indem Sie diesen Befehl in Ihrer Shell ausführen:
gcloud auth application-default login
Sie können auch eine Dienstkontoschlüsseldatei verwenden:
Klicken Sie auf Projekt auswählen und wählen Sie die Organisation, den Ordner oder das Projekt aus, in dem Sie das VMware Engine-Netzwerk erstellen möchten.
Klicken Sie auf Erstellen. Ein Formular zum Erstellen eines VMware Engine-Netzwerks wird geöffnet.
Geben Sie den Namen eines VMware Engine-Netzwerks ein.
Geben Sie eine Beschreibung für das Netzwerk ein, z. B. „Mein Standard-VEN 1“, und klicken Sie dann auf Erstellen.
Optional: Bestätigen Sie die Erstellung des Netzwerks, indem Sie den Menüpunkt VMware Engine-Netzwerke aufrufen. Alle VMware Engine-Netzwerke sind in der Tabelle auf dieser Seite aufgeführt.
In der folgenden Liste sind die einzelnen Felder, die Sie bei der Netzwerkerstellung festlegen müssen, genauer beschrieben:
Name: Permanente, eindeutige Kennung des VMware Engine-Netzwerks.
Beschreibung: Zusatzinformationen, die auf der Detailseite des VMware Engine-Netzwerks sichtbar sind.
Netzwerktyp: Kennung des Netzwerktyps, die für Netzwerk-Anwendungsfälle und Standard-Bereitstellungen in privaten Clouds verwendet wird.
Region:Dieser Wert hängt davon ab, ob Sie VMware Engine-Standardnetzwerke oder VMware Engine-Legacy-Netzwerke verwenden.
Bei alten Netzwerken ist dies die Region, in der das Netzwerk eine Verbindung hat.
Bei Standardnetzwerken ist dieses Feld immer auf „global“ gesetzt.
gcloud
So erstellen Sie ein VMware Engine-Netzwerk mit der gcloud CLI:
DESCRIPTION: Eine Beschreibung für dieses Netzwerk.
Optional: Wenn Sie alle VMware Engine-Netzwerke auflisten möchten, um die Erstellung des neuen Netzwerks zu bestätigen, verwenden Sie den Befehl gcloud vmware networks list:
gcloud vmware networks list \
--location=global
API
So erstellen Sie ein VMware Engine-Netzwerk mit der VMware Engine API:
Senden Sie zum Erstellen eines VMware Engine-Netzwerks eine POST-Anfrage:
POST "https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/global/vmwareEngineNetworks?vmware_engine_network_id=NETWORKD_ID"
'{
"type": "standard",
"description": "DESCRIPTION"
}'
Ersetzen Sie Folgendes:
PROJECT_ID: die ID des Projekts, in dem Sie das Netzwerk erstellen möchten.
NETWORK_ID: die ID Ihres VMware Engine-Netzwerks.
DESCRIPTION: Eine Beschreibung für dieses Netzwerk.
Optional: Wenn Sie alle VMware Engine-Netzwerke auflisten möchten, um die Erstellung des neuen Netzwerks zu bestätigen, senden Sie eine GET-Anfrage.
Ersetzen Sie PROJECT_ID durch die Projekt-ID, in der sich das Netzwerk befindet.
GET https://vmwareengine.googleapis.com/v1/projects//locations/global/vmwareEngineNetworks
VMware Engine-Netzwerk aktualisieren
So aktualisieren Sie ein VMware Engine-Netzwerk mit der Google Cloud Console, der gcloud CLI oder der VMware Engine API:
Console
Google Cloud Rufen Sie in der Console die Seite VMware Engine-Netzwerke auf.
Klicken Sie auf Projekt auswählen und wählen Sie die Organisation, den Ordner oder das Projekt aus, das das VMware Engine-Netzwerk enthält, das Sie aktualisieren möchten.
Klicken Sie auf den Namen des Netzwerks, das Sie aktualisieren möchten.
Bearbeiten Sie die Beschreibung auf der Seite mit den Netzwerkdetails und klicken Sie dann auf Speichern.
Optional: Wenn Sie sich die aktualisierte Beschreibung ansehen möchten, rufen Sie den Menüpunkt VMware Engine-Netzwerke auf und klicken Sie auf das Netzwerk, um die Details aufzurufen.
gcloud
So aktualisieren Sie ein VMware Engine-Netzwerk mit der gcloud CLI:
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-08-18 (UTC)."],[],[],null,["# Create a VMware Engine network\n==============================\n\nThis document describes how to create a *Standard VMware Engine\nNetwork* using the VMware Engine portal, gcloud CLI, or\nAPI. You can create multiple VMware Engine networks to isolate\nprivate clouds and define unique VPC network peerings. VMware Engine\nnetworks handle connections to and from private clouds according to a [network\npolicy](/vmware-engine/docs/preview/networking/network-policies) that you define separately.\n| **Note:** Projects created before November 2023 have *Legacy VMware Engine Networks* that are no longer available in newer projects. Google automatically created these networks for you; as such, these steps are only applicable for standard networks. For more information on legacy and standard networks, review the [Network overview](/vmware-engine/docs/networking/vmware-engine-network).\n\nBefore you begin\n----------------\n\n### Google Cloud CLI and API requirements\n\nTo use the `gcloud` command line tool or the API to manage your VMware Engine\nresources, we recommend configuring the tools as described below. \n\n### gcloud\n\n1. Set your default project ID:\n\n ```\n gcloud config set project PROJECT_ID\n ```\n2. Set a default region and zone:\n\n ```\n gcloud config set compute/region REGION\n ``` \n\n ```\n gcloud config set compute/zone ZONE\n ```\n\nFor more information on the `gcloud vmware` tool,\n[see the Cloud SDK reference docs](/sdk/gcloud/reference/vmware).\n\n### API\n\nAPI examples in this documentation set use the `cURL` command-line tool to\nquery the API. A valid access token is required as part of the `cURL`\nrequest. There are many ways to get a valid access token; the following\nsteps use the `gcloud` tool to generate a access token:\n\n1. Login to Google Cloud:\n\n ```\n gcloud auth login\n ```\n2. Generate access token and export to TOKEN:\n\n ```\n export TOKEN=`gcloud auth print-access-token`\n ```\n3. Verify that TOKEN is set properly:\n\n ```\n echo $TOKEN\n ```\n\nNow, use the authorization token in your requests to the API. For example: \n\n```\ncurl -X GET -H \"Authorization: Bearer \\\"$TOKEN\\\"\" -H \"Content-Type: application/json; charset=utf-8\" https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations\n```\n\n### Python\n\nPython code samples in this documentation use the [VMware Engine library](https://cloud.google.com/python/docs/reference/vmwareengine/latest) to communicate with the API. To be able to use this approach, the library needs to be installed and the [Application Default Credentials](https://cloud.google.com/docs/authentication/application-default-credentials) should be configured.\n\n1. Download and install the Python library:\n\n ```\n pip install google-cloud-vmwareengine\n ```\n2. Configure the ADC information by executing those command in your shell:\n\n ```\n gcloud auth application-default login\n ```\n\n Or, use a Service Account key file: \n\n ```\n export GOOGLE_APPLICATION_CREDENTIALS=\"FILE_PATH\"\n ```\n\nFor more information about the library, visit the [reference page](/python/docs/reference/vmwareengine/latest) or view [code samples on GitHub](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/main/vmwareengine/cloud-client).\n\nCreate a VMware Engine network\n------------------------------\n\nCreate a VMware Engine network using the Google Cloud console,\ngcloud CLI, or VMware Engine API: \n\n### Console\n\nTo create a VMware Engine network using the VMware Engine:\n\n1. In the Google Cloud console, go to the **VMware Engine networks** page.\n\n [Go to VMware Engine networks](https://console.cloud.google.com/vmwareengine/networks)\n2. Click **Select a project** and then select the organization, folder, or project\n where you want to create the VMware Engine network.\n\n3. Click **Create**. A VMware Engine network creation form opens.\n\n4. Enter a VMware Engine network name.\n\n5. Enter a description for the network, for example \"My standard VEN 1\", and\n then click **Create**.\n\n6. Optional: Confirm the creation of your network by navigating to the\n **VMware Engine networks** menu item. All VMware Engine\n networks are listed in the table on this page.\n\nThe following list describes each field during network creation in more detail:\n\n- **Name:** Permanent unique identifier of the VMware Engine network.\n- **Description:** Additional information that's visible on the details page of the VMware Engine network.\n- **Network type:** Network type identifier used to support networking use cases and standard private cloud deployments.\n- **Region:** This depends on whether you are using Standard\n VMware Engine or Legacy VMware Engine networks.\n\n - For legacy networks, this is the region where the network has connectivity.\n - For standard networks, this field is always set to global.\n\n### gcloud\n\nTo create a VMware Engine network using the gcloud CLI:\n\n1. Run [`gcloud vmware networks create` command](/sdk/gcloud/reference/vmware/networks/create):\n\n ```\n gcloud vmware networks create NETWORK_ID \\\n --type=STANDARD \\\n --description=\"DESCRIPTION\"\n ```\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003eNETWORK_ID\u003c/var\u003e: the ID for your VMware Engine network.\n - \u003cvar translate=\"no\"\u003eDESCRIPTION\u003c/var\u003e: a description for this network.\n2. Optional: If you want to list all VMware Engine networks to confirm the creation of the new network, use the [`gcloud vmware networks list` command](/sdk/gcloud/reference/vmware/networks/list):\n\n ```\n gcloud vmware networks list \\\n --location=global\n ```\n\n### API\n\nTo create a VMware Engine network using the VMware Engine API, do the following:\n\n1. To create a VMware Engine network, make a `POST` request:\n\n ```\n POST \"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/global/vmwareEngineNetworks?vmware_engine_network_id=NETWORKD_ID\"\n\n '{\n \"type\": \"standard\",\n \"description\": \"DESCRIPTION\"\n }'\n ```\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: the ID of the project where you want to create the network.\n - \u003cvar translate=\"no\"\u003eNETWORK_ID\u003c/var\u003e: the ID for your VMware Engine network.\n - \u003cvar translate=\"no\"\u003eDESCRIPTION\u003c/var\u003e: a description for this network.\n2. Optional: To list all VMware Engine networks to confirm the\n creation of the new network, make a `GET` request.\n Replace \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e with the project ID where the\n network is located.\n\n ```\n GET https://vmwareengine.googleapis.com/v1/projects//locations/global/vmwareEngineNetworks\n ```\n\nUpdate a VMware Engine network\n------------------------------\n\nUpdate a VMware Engine network using the Google Cloud console,\ngcloud CLI, or VMware Engine API: \n\n### Console\n\n1. In the Google Cloud console, go to the **VMware Engine networks** page.\n\n [Go to VMware Engine networks](https://console.cloud.google.com/vmwareengine/networks)\n2. Click **Select a project** and then select the organization, folder, or project that\n contains the VMware Engine network you want to update.\n\n3. Click the name of the network that you want to update.\n\n4. On the network details page, edit the description and then click **Save**.\n\n5. Optional: To view the updated description, navigate to the **VMware Engine networks**\n menu item and click the network to see the details.\n\n### gcloud\n\nTo update a VMware Engine network using the gcloud CLI,\ndo the following:\n\n1. Update the description of a VMware Engine network by running\n the [`gcloud vmware networks update` command](/sdk/gcloud/reference/vmware/networks/update):\n\n ```\n gcloud vmware networks update NETWORK_ID \\\n --description='DESCRIPTION'\n ```\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003eNETWORK_ID\u003c/var\u003e: the ID for your VMware Engine network.\n - \u003cvar translate=\"no\"\u003eDESCRIPTION\u003c/var\u003e: an updated description for this network.\n2. Optional: If you want to view the updated attribute, use the\n [`gcloud vmware networks describe` command](/sdk/gcloud/reference/vmware/networks/describe):\n\n ```\n gcloud vmware networks describe NETWORK_ID\n ```\n\n### API\n\nTo update a VMware Engine network using the VMware Engine API,\ndo the following:\n\n1. To update the description of a VMware Engine network, make a\n `PATCH` request:\n\n ```\n PATCH \"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION/vmwareEngineNetworks/NETWORK_ID?update_mask=description\"\n\n '{\n \"description\":\"DESCRIPTION\"\n }'\n ```\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: the project ID where the network is located.\n - \u003cvar translate=\"no\"\u003eLOCATION\u003cvar translate=\"no\"\u003e\u003c/var\u003e\u003c/var\u003e: the location of the network, either `global` for standard networks or the region for legacy networks.\n - \u003cvar translate=\"no\"\u003eNETWORK_ID\u003c/var\u003e: the ID for your VMware Engine network.\n - \u003cvar translate=\"no\"\u003eDESCRIPTION\u003c/var\u003e: an updated description for this network.\n2. Optional: If you want to view the updated attribute, make a `GET` request:\n\n ```\n GET \"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/global/vmwareEngineNetworks/NETWORK_ID\"\n ```\n\nWhat's next\n-----------\n\n- [Get sign-in credentials for management appliances](/vmware-engine/docs/vmware-platform/howto-access-vsphere-client).\n- [Manage your private cloud resources and activity](/vmware-engine/docs/private-clouds/howto-manage-private-cloud)."]]