管理私有雲資源與活動

建立私有雲後,您可以查看私有雲的詳細資訊、管理其資源和活動,以及存取 VMware 管理設備。每個私有雲都包含一或多個叢集,而每個叢集都包含與 ESXi 主機相對應的節點。

如要查看私有雲清單,請先前往其資源摘要頁面:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取要管理私有雲端的機構、資料夾或專案。

  3. 從私有雲清單中選取要管理的私有雲。

gcloud 和 API 相關規定

如要使用 gcloud 指令列工具或 API 管理 VMware Engine 資源,建議您按照下列說明設定工具。

gcloud

  1. 設定預設專案 ID:

    gcloud config set project PROJECT_ID
    
  2. 設定預設地區和區域:

    gcloud config set compute/region REGION
    
    gcloud config set compute/zone ZONE
    

如要進一步瞭解 gcloud vmware 工具,請參閱 Cloud SDK 參考文件

API

本套說明文件中的 API 範例會使用 cURL 指令列工具查詢 API。cURL 要求中必須提供有效的存取權杖。取得有效存取權杖的方法有很多種,以下步驟會使用 gcloud 工具產生存取權杖:

  1. 登入 Google Cloud:

    gcloud auth login
    
  2. 產生存取權杖並匯出至 TOKEN:

    export TOKEN=`gcloud auth print-access-token`
    
  3. 確認已正確設定 TOKEN:

    echo $TOKEN
    

接下來,請在 API 要求中使用授權金鑰。例如:

curl -X GET -H "Authorization: Bearer \"$TOKEN\"" -H "Content-Type: application/json; charset=utf-8" https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations

Python

本文件中的 Python 程式碼範例會使用 VMware Engine 程式庫與 API 通訊。如要使用這種方法,您必須安裝程式庫,並設定應用程式預設憑證

  1. 下載並安裝 Python 程式庫:

    pip install google-cloud-vmwareengine
    
  2. 在 Shell 中執行下列指令,設定 ADC 資訊:

    gcloud auth application-default login
    

    或者,您也可以使用服務帳戶金鑰檔案:

    export GOOGLE_APPLICATION_CREDENTIALS="FILE_PATH"
    

如要進一步瞭解程式庫,請參閱參考頁面,或查看 GitHub 上的程式碼範例

驗證 IP 位址版面配置

2022 年 11 月之後建立的私有雲會遵循 IP 位址版面配置 (IP 企劃書) 2.0 版的子網路分配方式。2022 年 11 月前建立的私有雲幾乎都遵循 IP 方案 1.0 版的子網路分配方式。

如要瞭解私有雲端採用哪個版本,請完成下列步驟:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取要管理私有雲端的機構、資料夾或專案。

  3. 選取要檢查的私有雲名稱。版本號碼會與「IP 方案版本」一併顯示。

查看私有雲摘要

摘要會提供私有雲的相關資訊,包括名稱、vSphere 叢集數量、節點數量、位置、運作狀態等。摘要頁面也會顯示在私有雲端部署的 DNS 伺服器。

您可以在私有雲摘要頁面中執行下列操作:

在私人雲端中新增節點

私有雲包含一或多個 vSphere 叢集,每個叢集都包含多個節點。在私有雲中新增節點時,您可以將節點新增至現有叢集,或建立新的叢集。私有雲可多次擴充,但必須維持在整體節點限制內。每次擴充私有雲時,您都會新增至現有叢集或建立新叢集。

在新的叢集設定中,Google 會設定 VMware 基礎架構。這些設定包括 vSAN 磁碟群組的儲存設定、VMware 高可用性和分散式資源排程器 (DRS)。

主控台

如要使用 Google Cloud 控制台,在私人雲端中新增現有叢集的節點,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取包含私有雲的機構、資料夾或專案。

  3. 從私有雲清單中選取要管理的私有雲。

  4. 在私有雲摘要頁面中,按一下「叢集」分頁標籤。

  5. 按一下現有叢集的名稱,開啟叢集詳細資料頁面。

  6. 按一下 [編輯]

  7. 選取要新增 HCI 節點的新節點數量,或選取儲存空間節點類型和新節點數量,以便新增僅儲存空間節點,然後按一下「儲存」

gcloud

您可以使用更新指令變更叢集的節點總數。這個指令需要叢集和私有雲的名稱。

  1. 輸入 gcloud vmware private-clouds clusters list 指令,即可列出叢集:

    gcloud vmware private-clouds clusters list \
    --private-cloud=PRIVATE_CLOUD_ID \
    --location=ZONE

更改下列內容:

  • PRIVATE_CLOUD_ID:私有雲名稱
  • ZONE:私有雲的區域
  1. 執行 gcloud vmware private-clouds clusters update 指令更新叢集:

    gcloud vmware private-clouds clusters update CLUSTER_ID \
    --location=ZONE \
    --private-cloud=PRIVATE_CLOUD_ID \
    --update-nodes-config=type=NODE_TYPE,count=NODE_COUNT

    更改下列內容:

    • CLUSTER_ID:要在這個私有雲中更新的叢集 ID。
    • ZONE:私有雲的區域。
    • PRIVATE_CLOUD_ID:此要求的私有雲 ID。
    • NODE_TYPE:節點類型。詳情請參閱「節點類型」。
    • NODE_COUNT:要新增的節點數量。

API

更新 API 可讓您變更叢集的節點總數。這個指令需要叢集和私有雲的名稱。

  1. 如要列出叢集,請發出 GET 要求:

    curl -L -X GET -H "Authorization: Bearer TOKEN" "https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters"
    

更改下列內容:

  • PROJECT_ID:這項要求的專案 ID
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:這項要求的私有雲端 ID
  1. 發出 PATCH 要求來更新叢集。例如,以下指令會將叢集更新為 standard-72 節點類型。

    curl -L -X PATCH -H "Authorization: Bearer TOKEN" \
    -H "Content-Type: application/json" \
    "https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters/CLUSTER_ID?updateMask=node_type_configs.*.node_count" \
    -d '{
    "nodeTypeConfigs": {
      "standard-72" : {
        "nodeCount": NODE_COUNT
      }
    }
    }'

    更改下列內容:

    • PROJECT_ID:這項要求的專案 ID
    • ZONE:私有雲的區域
    • PRIVATE_CLOUD_ID:私有雲的私有雲 ID
    • CLUSTER_ID:叢集 ID,用於更新此私有雲端中的叢集
    • NODE_COUNT:要新增的節點數量

Python

叢集更新方法可讓您變更叢集的總節點數。這個方法需要叢集和私有雲的名稱。

  1. 列出叢集。
from typing import Iterable

from google.cloud import vmwareengine_v1


def list_clusters(
    project_id: str, zone: str, private_cloud_name: str
) -> Iterable[vmwareengine_v1.Cluster]:
    """
    Retrieves a list of clusters in private cloud.

    Args:
        project_id: name of the project hosting the private cloud.
        zone: zone in which the private cloud is located.
        private_cloud_name: name of the cloud of which you want to list cluster.

    Returns:
        An iterable collection of Cluster objects.
    """
    client = vmwareengine_v1.VmwareEngineClient()
    return client.list_clusters(
        parent=f"projects/{project_id}/locations/{zone}/privateClouds/{private_cloud_name}"
    )

  1. 更新叢集。您可以使用下列方法修改叢集中的 standard-72 節點數量。
from google.api_core import operation
from google.cloud import vmwareengine_v1


def update_cluster_node_count(
    project_id: str,
    zone: str,
    private_cloud_name: str,
    cluster_name: str,
    node_count: int,
) -> operation.Operation:
    """
    Modify the number of nodes in a cluster in a private cloud.

    Modifying a cluster is a long-running operation and it may take over an hour.

    Args:
        project_id: name of the project you want to use.
        zone: zone in which your private cloud is located.
        private_cloud_name: name of the private cloud hosting the cluster.
        cluster_name: name of the cluster.
        node_count: desired number of nodes in the cluster.

    Returns:
        An Operation object related to cluster modification operation.
    "&<quot;"
    if node_count  3:
        raise RuntimeError("Cluster needs to have at least 3 nodes")
    client = vmwareengine_v1.VmwareEngineClient()
    request = vmwareengine_v1.UpdateClusterRequest()
    request.cluster = vmwareengine_v1.Cluster()
    request.cluster.name = (
        f"projects/{project_id}/locations/{zone}/privateClouds/{private_cloud_name}"
        f"/clusters/{cluster_name}"
    )
    request.cluster.node_type_configs = {
        "standard-72": vmwareengine_v1.NodeTypeConfig()
    }
    request.cluster.node_type_configs["standard-72"].node_count = node_count
    request.update_mask = "nodeTypeConfigs.*.nodeCount"
    return client.update_cluster(request)

將新的叢集新增至私有雲

如要在現有私有雲中新增叢集,請按照下列步驟操作:

主控台

如要使用 Google Cloud 控制台新增叢集,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取包含私有雲的機構、資料夾或專案。

  3. 從私有雲清單中選取要管理的私有雲。

  4. 在私有雲摘要頁面中,按一下「叢集」分頁標籤。

  5. 按一下「新增叢集」。然後提供下列詳細資料:

    1. 輸入叢集的名稱。
    2. 選取新叢集的節點類型。
    3. 選取節點數量。每個新叢集至少須有三個節點。
  6. 按一下 [建立]。

gcloud

執行 gcloud vmware private-clouds clusters create 指令,新增叢集並命名:

gcloud vmware private-clouds clusters create CLUSTER_ID \
   --location=ZONE \
   --private-cloud=PRIVATE_CLOUD_ID \
   --node-type-config=type=NODE_TYPE,count=NODE_COUNT

更改下列內容:

  • CLUSTER_ID:要新增至私有雲的叢集 ID。
  • ZONE:私有雲的區域。
  • PRIVATE_CLOUD_ID:Private Cloud 的 Private Cloud ID。
  • NODE_TYPE:節點類型。詳情請參閱「節點類型」。
  • NODE_COUNT:要新增的節點數量。

API

請透過 POST 要求新增叢集並命名。例如:

curl -L -X POST -H "Authorization: Bearer TOKEN" -H "Content-Type: application/json" \
"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters?clusterId=CLUSTER_ID" \
-d '{
  "nodeTypeConfigs": {
    "standard-72": {
      "nodeCount": NODE_COUNT
      }
  }
}'

更改下列內容:

  • CLUSTER_ID:要新增至私有雲的叢集 ID
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:私有雲的私有雲 ID
  • NODE_COUNT:要新增的節點數量

Python

新增叢集並命名。

from google.api_core import operation
from google.cloud import vmwareengine_v1


def create_cluster(
    project_id: str,
    zone: str,
    private_cloud_name: str,
    cluster_name: str,
    node_count: int = 4,
) -> operation.Operation:
    """
    Create a new cluster in a private cloud.

    Creation of a new cluster is a long-running operation and it may take over an hour.

    Args:
        project_id: name of the project you want to use.
        zone: region in which your private cloud is located.
        private_cloud_name: name of the private cloud hosting the new cluster.
        cluster_name: name of the new cluster.
        node_count: number of nodes in the new clu>ster. (Must be = 3)

    Returns:
        An Operation object related to started cluster creation operation.

    Raises:
        ValueError in case an incorrect number of nodes is provided.
    "&<quot;"
    if node_count  3:
        raise ValueError("Cluster needs to have at least 3 nodes")

    request = vmwareengine_v1.CreateClusterRequest()
    request.parent = (
        f"projects/{project_id}/locations/{zone}/privateClouds/{private_cloud_name}&quot;
    )

    request.cluster = vmwareengine_v1.Cluster()
    request.cluster.name = cluster_name

    # Currently standard-72 is the only supported node type.
    request.cluster.node_type_configs = {
        "standard-72": vmwareengine_v1.NodeTypeConfig()
    }
    request.cluster.node_type_configs["standard-72"].node_count = node_count

    client = vmwareengine_v1.VmwareEngineClient()
    return client.create_cluster(request)

使用自訂核心數量設定建立新叢集

如要建立具有自訂核心數設定的新叢集,請按照下列步驟操作:

主控台

如要使用 Google Cloud 控制台新增叢集,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取包含私有雲的機構、資料夾或專案。

  3. 從私有雲清單中選取要管理的私有雲。

  4. 在私有雲摘要頁面中,按一下「叢集」分頁標籤。

  5. 按一下「新增叢集」。然後提供下列詳細資料:

    1. 輸入叢集的名稱。
    2. 選取節點數量。每個新叢集至少須有三個節點。
    3. 選取叢集的節點類型。
  6. 勾選「Customize cores」方塊,即可減少管理叢集中每個節點的可用核心數量。詳情請參閱「自訂核心數量」。

  7. 按一下 [建立]。

gcloud

執行 gcloud vmware private-clouds clusters create 指令,新增叢集並指定核心數設定:以下範例會使用 standard-72 節點類型建立新叢集。

gcloud vmware private-clouds clusters create CLUSTER_ID \
  --location=ZONE \
  --private-cloud=PRIVATE_CLOUD_ID \
  --node-type-config=type=standard-72,count=NODE_COUNT,custom-core-count=CORE_COUNT

更改下列內容:

  • CLUSTER_ID:要新增至私有雲的叢集 ID
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:私有雲的私有雲 ID
  • NODE_COUNT:要新增的節點數量
  • CORES_COUNT:要新增的自訂核心數量

API

請透過 POST 要求新增叢集,並指定核心數設定。以下範例會建立新的 standard-72 節點類型叢集。

curl -L -X POST -H "Authorization: Bearer TOKEN" -H "Content-Type: application/json" \
"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters?clusterId=CLUSTER_ID" \
-d '{
      "nodeTypeConfigs": {
      "standard-72": {
        "nodeCount": NODE_COUNT,
        "customCoreCount": CORE_COUNT
        }
    }
}'

更改下列內容:

  • PROJECT_ID:私有雲專案 ID
  • CLUSTER_ID:要新增至私有雲的叢集 ID
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:私有雲的私有雲 ID
  • NODE_COUNT:要新增的節點數量
  • CORES_COUNT:要新增的自訂核心數量

Python

新增叢集並指定核心數設定。舉例來說,以下會建立 standard-72 節點類型的新叢集,並可設定節點和核心數量。

from google.api_core import operation
from google.cloud import vmwareengine_v1


def create_custom_cluster(
    project_id: str,
    zone: str,
    private_cloud_name: str,
    cluster_name: str,
    node_count: int = 4,
    core_count: int = 28,
) -> operation.Operation:
    """
    Create a new cluster with custom number of cores in its nodes
    in a private cloud.

    Creation of a new cluster is a long-running operation and it may take over an hour.

    Args:
        project_id: name of the project you want to use.
        zone: region in which your private cloud is located.
        private_cloud_name: name of the private cloud hosting the new cluster.
        cluster_name: name of the new cluster.
        node_count: number of nodes in the new cluster.
        core_count: number of CPU cores in the new cluster nodes.

    Returns:
        An Operation object related to started cluster creation operation.

    Raises:
        ValueError in case an incorrect number of nodes is provided.
    "&<quot;"
    if node_count  3:
        raise ValueError("Cluster needs to have at least 3 nodes")

    request = vmwareengine_v1.CreateClusterRequest()
    request.parent = (
        f"projects/{project_id}/locations/{zone}/privateClouds/{private_cloud_name}&quot;
    )

    request.cluster = vmwareengine_v1.Cluster()
    request.cluster.name = cluster_name

    # Currently standard-72 is the only supported node type.
    request.cluster.node_type_configs = {
        "standard-72": vmwareengine_v1.NodeTypeConfig()
    }
    request.cluster.node_type_configs["standard-72"].node_count = node_count
    request.cluster.node_type_configs[";standard-72"].custom_core_count = core_count

    client = vmwareengine_v1.VmwareEngineClient()
    return client.create_cluster(request)

從叢集中移除節點

從私有雲中移除節點時,您會從現有叢集中移除節點。

主控台

如要使用 Google Cloud 控制台更新叢集,以移除私人雲端中的節點,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取包含私有雲的機構、資料夾或專案。

  3. 從私有雲清單中選取要管理的私有雲。

  4. 按一下「叢集」分頁標籤,然後選取要縮小的叢集。

  5. 按一下「編輯」,然後將節點數量減少一個。您一次只能移除一個節點。

  6. 按一下 [儲存]

如要監控進度,請依序選取「活動」>「工作」。這項程序需要在 vSAN 中重新同步處理,可能需要數小時才能完成,具體情況視資料而定。

gcloud

如要使用 Google Cloud CLI 從私有雲中移除節點,請使用 gcloud vmware private-clouds clusters update 指令

gcloud vmware private-clouds clusters update CLUSTER_ID \
  --location=ZONE \
  --private-cloud=PRIVATE_CLOUD_ID \
  --update-nodes-config=type=NODE_TYPE,count=NODE_COUNT

更改下列內容:

  • CLUSTER_ID:叢集 ID,用於更新此私有雲端中的叢集。
  • ZONE:私有雲的區域。
  • PRIVATE_CLOUD_ID:Private Cloud 的 Private Cloud ID。
  • NODE_TYPE:節點類型。詳情請參閱「節點類型」。
  • NODE_COUNT:新的節點數量。這個新值必須比目前的值少一個。

API

如要使用 VMware Engine API 從私有雲移除節點,請提出 PATCH 要求:

curl -L -X PATCH -H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters/CLUSTER_ID?update_mask=node_type_configs.*.node_count" \
-d '{
  "nodeTypeConfigs": {
    "standard-72" : {
      "nodeCount": NODE_COUNT
    }
  }
}'

更改下列內容:

  • CLUSTER_ID:叢集 ID,用於更新此私有雲中的叢集
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:私有雲的私有雲 ID
  • NODE_COUNT:新的節點數量。這個新值必須比目前值少一個

Python

from google.api_core import operation
from google.cloud import vmwareengine_v1


def update_cluster_node_count(
    project_id: str,
    zone: str,
    private_cloud_name: str,
    cluster_name: str,
    node_count: int,
) -> operation.Operation:
    """
    Modify the number of nodes in a cluster in a private cloud.

    Modifying a cluster is a long-running operation and it may take over an hour.

    Args:
        project_id: name of the project you want to use.
        zone: zone in which your private cloud is located.
        private_cloud_name: name of the private cloud hosting the cluster.
        cluster_name: name of the cluster.
        node_count: desired number of nodes in the cluster.

    Returns:
        An Operation object related to cluster modification operation.
    "&<quot;"
    if node_count  3:
        raise RuntimeError("Cluster needs to have at least 3 nodes")
    client = vmwareengine_v1.VmwareEngineClient()
    request = vmwareengine_v1.UpdateClusterRequest()
    request.cluster = vmwareengine_v1.Cluster()
    request.cluster.name = (
        f"projects/{project_id}/locations/{zone}/privateClouds/{private_cloud_name}"
        f"/clusters/{cluster_name}"
    )
    request.cluster.node_type_configs = {
        "standard-72": vmwareengine_v1.NodeTypeConfig()
    }
    request.cluster.node_type_configs["standard-72"].node_count = node_count
    request.update_mask = "nodeTypeConfigs.*.nodeCount"
    return client.update_cluster(request)

刪除叢集

如要刪除整個叢集,請按照下列步驟操作:

主控台

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 按一下「選取專案」,然後選取包含私有雲的機構、資料夾或專案。

  3. 從私有雲清單中選取要管理的私有雲。

  4. 按一下「叢集」分頁標籤,然後選取要刪除的叢集。

  5. 按一下「Delete」,然後確認叢集容量。請注意,管理叢集無法刪除。

  6. 按一下 [儲存]

gcloud

如要使用 Google Cloud CLI 刪除整個叢集,請使用 gcloud vmware private-clouds clusters delete 指令

gcloud vmware private-clouds clusters delete CLUSTER_ID \
  --location=ZONE \
  --private-cloud=PRIVATE_CLOUD_ID

更改下列內容:

  • CLUSTER_ID:叢集 ID,用於更新此私有雲中的叢集
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:私有雲的私有雲 ID

API

如要使用 VMware Engine API 刪除整個叢集,請發出 DELETE 要求:

curl -L -X DELETE -H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
"https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters/CLUSTER_ID"

更改下列內容:

  • PROJECT_ID:私有雲端的專案 ID
  • ZONE:私有雲的區域
  • PRIVATE_CLOUD_ID:私有雲的私有雲 ID
  • CLUSTER_ID:叢集 ID,用於更新此私有雲中的叢集

Python

from google.api_core import operation
from google.cloud import vmwareengine_v1


def delete_cluster(
    project_id: str, zone: str, private_cloud_name: str, cluster_name: str
) -> operation.Operation:
    """
    Delete a cluster from private cloud.

    Deleting a cluster is a long-running operation and it may take over an hour..

    Args:
        project_id: name of the project you want to use.
        zone: region in which your private cloud is located.
        private_cloud_name: name of the private cloud hosting the new cluster.
        cluster_name: name of the new cluster.

    Returns:
        An Operation object related to started cluster deletion operation.
    &quot;"";
    client = vmwareengine_v1.VmwareEngineClient()
    request = vmwareengine_v1.DeleteClusterRequest()
    request.name = (
        f"projects/{project_id}/locations/{zone}/privateClouds/{private_cloud_name}"
        f"/clusters/{cluster_name}"
    )
    return client.delete_cluster(request)

列出節點

如要使用主控台、Google Cloud CLI 或 VMware Engine API 列出特定私有雲叢集的節點,並取得多個節點或特定節點的相關資訊,請按照下列步驟操作。 Google Cloud

主控台

如要使用 Google Cloud 控制台列出一個或多個私有雲的節點,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 在私有雲摘要頁面中,按一下私有雲的名稱。

  3. 按一下「叢集」分頁標籤。

  4. 按一下叢集名稱。叢集內的所有節點都會列在叢集節點表格中。

gcloud

如要使用 Google Cloud CLI 列出一個或多個私有雲的節點,請執行下列操作:

  1. 執行 gcloud vmware private-clouds clusters node list 指令,即可列出所有已繫結至特定私有雲端 PRIVATE_CLOUD_ID 的節點:

    gcloud vmware private-clouds clusters node list \
     --project=PROJECT_ID\
     --location=ZONE \
     --private-cloud=PRIVATE_CLOUD_ID \
     --cluster=CLUSTER_ID

    更改下列內容:

    • PROJECT_ID:這項要求的專案名稱。
    • ZONE:這個網路所在的可用區。
    • PRIVATE_CLOUD_ID:這項要求的網路 ID。
    • CLUSTER_ID:此要求的叢集 ID。

API

如要使用 VMware Engine API 列出一個或多個私有雲的節點,請按照下列步驟操作:

  1. 如要列出已繫結至特定私有雲的所有節點 PRIVATE_CLOUD_ID,請提出 GET 要求:

    GET "https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters/CLUSTER_ID/nodes"

    更改下列內容:

    • PROJECT_ID:這項要求的專案名稱。
    • ZONE:這個網路所在的可用區。
    • PRIVATE_CLOUD_ID:這項要求的網路 ID。
    • CLUSTER_ID:此要求的叢集 ID。

說明節點

如要使用控制台、Google Cloud CLI 或 VMware Engine API 取得節點的說明,請按照下列步驟操作: Google Cloud

主控台

如要使用Google Cloud 主控台列出一個或多個私有雲的節點,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「Private clouds」頁面。

    前往 Private Cloud

  2. 在私有雲摘要頁面中,按一下私有雲的名稱。

  3. 按一下「叢集」分頁標籤。

  4. 按一下叢集名稱。節點詳細資料會列在叢集節點表格中。

gcloud

如要使用 Google Cloud CLI 取得節點或多個節點的說明。

  1. 選用步驟:執行 gcloud vmware private-clouds clusters node list 指令,找出節點名稱:

    gcloud vmware private-clouds clusters node list \
     --project=PROJECT_ID\
     --location=ZONE \
     --private-cloud=PRIVATE_CLOUD_ID \
     --cluster=CLUSTER_ID

    更改下列內容:

    • PROJECT_ID:這項要求的專案名稱。
    • ZONE:這個網路所在的可用區。
    • PRIVATE_CLOUD_ID:這項要求的網路 ID。
    • CLUSTER_ID:此要求的叢集 ID。
  2. 執行 gcloud vmware private-clouds clusters nodes describe 指令,取得特定節點的說明:

    gcloud vmware private-clouds clusters nodes describe NODE_NAME \
     --project=PROJECT_ID\
     --location=ZONE \
     --private-cloud=PRIVATE_CLOUD_ID \
     --cluster=CLUSTER_ID

    更改下列內容:

    • NODE_NAME:上一個指令傳回的節點名稱。例如:esxi-1435-f4d250
    • PROJECT_ID:這項要求的專案名稱。
    • ZONE:這個網路所在的可用區。
    • PRIVATE_CLOUD_ID:此要求的網路 ID。
    • CLUSTER_ID:此要求的叢集 ID。

API

如要使用 VMware Engine API 取得節點或多個節點的說明。

  1. 選用步驟:透過發出 GET 要求,找出節點名稱:

    GET "https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters/CLUSTER_ID/nodes"
    

    更改下列內容:

    • PROJECT_ID:這項要求的專案名稱。
    • ZONE:這個網路所在的可用區。
    • PRIVATE_CLOUD_ID:此要求的網路 ID。
    • CLUSTER_ID:此要求的叢集 ID。
  2. 提出 GET 要求,取得特定節點的說明:

    GET "https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/clusters/CLUSTER_ID/nodes/NODE_NAME"

    更改下列內容:

    • NODE_NAME:上一個指令傳回的節點名稱。例如:esxi-1435-f4d250
    • PROJECT_ID:這項要求的專案名稱。
    • ZONE:這個網路所在的可用區。
    • PRIVATE_CLOUD_ID:此要求的網路 ID。
    • CLUSTER_ID:此要求的叢集 ID。

限制

從私有雲中移除節點的程序有下列限制:

  • vSphere 叢集至少須有三個節點。您無法從包含三個節點的 vSphere 叢集中移除節點。
  • 無論您使用的是 Google Cloud 控制台、gcloud CLI 還是 VMware Engine API,每次移除節點要求只能移除一個節點。
  • 從叢集中移除節點後,總儲存空間用量不得超過總容量。
  • 您無法刪除在建立私有雲時建立的第一個叢集。
  • 如果 vSphere DRS 規則 (親和性和反親和性) 套用至叢集的所有節點,就無法從叢集中移除節點。您可以刪除規則,然後重試節點移除作業。

查看子網路

如要查看私有雲端所定義的管理子網路清單,請選取「子網路」分頁標籤。清單中包含建立私有雲時建立的 HCX 子網路。

查看活動資訊

如要查看私有雲端的活動資訊,請按一下「前往 Logs Viewer」。如需活動和相關動作的完整清單,請參閱「監控 VMware Engine 活動」。

查看 vSphere 管理網路

如要查看在私有雲中設定的 VMware 管理資源和虛擬機器清單,請選取「vSphere Management Network」分頁標籤。資訊包括資源的軟體版本、完整網域名稱 (FQDN) 和 IP 位址。