如果無法更新 Google Distributed Cloud,請參閱下列章節,瞭解如何排解問題。如要進一步瞭解可更新的設定,請參閱「叢集可更新和不可更新的項目」。
更新逾時
更新逾時時間會根據要更新的資源動態計算。 不過,這項計算有時會有誤差。更新逾時時,系統會顯示類似下列的錯誤:
在使用者叢集中:
Failed to update the cluster:...timed out waiting for the condition...
在管理員叢集中:
Failed to update the admin cluster:...timed out waiting for the condition...
您可以放心忽略這類逾時錯誤,並重試更新指令。如果重試指令後再次逾時,並顯示相同的錯誤訊息,請與 Cloud Customer Care 聯絡。
更新包含多項變更
gkectl update admin
和 gkectl update cluster
指令不允許在一個指令中更新多項設定。如果設定包含多項設定變更的差異,且傳回類似下列範例的錯誤:
Update summary for cluster X:
antiAffinityGroups: enabled to be set to true from false &config.AAGSpec{
- Enabled: false,
+ Enabled: true,
}
user master cpu to be set to 5 from 4 config.NodePoolProps{
Role: "master",
MachineType: "standard-master",
- CPUs: 4,
+ CPUs: 5,
MemoryMB: 8192,
Replicas: 3,
... // 2 identical fields
Labels: nil,
NodeTaints: nil,
- Vsphere: nil,
&config.NodePoolVsphereSpec{Datastore: "lifecycle-workloads1-datastore1"},
+ Vsphere: nil,
BootDiskSizeGB: nil,
OSImageType: "",
... // 5 identical fields
}
Exit with error:
Failed to update the cluster: the update contains multiple changes. Please
update only one feature at a time
造成這項錯誤的原因有很多,包括:
- 錯誤或設定有誤。
- 您先前已使用設定差異執行
gkectl upgrade
,並預期變更會套用。gkectl upgrade
不會套用任何設定差異,但版本升級除外。
- 您先前編輯了其他功能更新的設定,但忘記執行
gkectl update
指令。
如果發生這種情況,請查看錯誤訊息中的差異,然後使用多個 gkectl update
指令逐一更新必要設定。如要找出變更,可以使用 gkectl get-config
從叢集產生設定檔,並查看現有狀態和設定。
不支援的變更
gkectl update cluster
和 gkectl update admin
指令會忽略不支援的變更,並顯示類似下列範例的錯誤訊息:
detected unsupported changes: (-current +desired)
...
- AdvancedNetworking: &true,
+ AdvancedNetworking: &false,
...
, which will be ignored
如果遇到這種情況,請查看錯誤訊息中的差異,並採取下列行動:
- 如果變更並非預期,請編輯設定 YAML 檔案,只更新正確的預期變更。
- 在先前的範例中,如果您不打算停用
AdvancedNetworking
,請在設定 YAML 檔案中設定advancedNetworking: true
。
- 在先前的範例中,如果您不打算停用
- 如果變更是有意為之,這項錯誤表示系統不支援該變更。執行下列任一動作:
- 視情況重新建立叢集。
- 請與 Google 支援團隊聯絡。
OS 映像檔不存在
gkectl update cluster
和 gkectl update admin
指令可能會失敗,並出現類似下列範例的OS Images
預檢失敗訊息:
在使用者叢集中:
- Validation Category: OS Images - [FAILURE] User cluster OS images exist: os images [xxxx] don't exist, please run `gkectl prepare` to upload os images.
在管理員叢集中:
- Validation Category: OS Images - [FAILURE] Admin cluster OS images exist: os images [xxxx] don't exist, please run `gkectl prepare` to upload os images.
如果 vCenter 環境中的 OS 映像檔遭到非預期移除 (例如透過定期清除作業),就可能發生這類錯誤。
如要重新匯入匯入的 OS 映像檔,請執行 gkectl prepare
指令,如下所示:
gkectl prepare \ --bundle-path /var/lib/gke/bundles/gke-onprem-vsphere-TARGET_VERSION.tgz \ --kubeconfig ADMIN_CLUSTER_KUBECONFIG \ --skip-upload-container-images
資料存放區可用空間不足,無法建立新的節點集區
新增節點集區時,gkectl update cluster
指令可能會失敗,並顯示類似下列範例的 VSphere Datastore FreeSpace
預檢錯誤:
- [FAILURE] VSphere Datastore FreeSpace: vCenter datastore: xxxx insufficient
FreeSpace, requires at least xxx GB
這項失敗表示資料儲存空間的可用空間不足,無法執行新的節點集區。使用下列其中一種方式,有助於提供空間,讓作業順利完成:
- 釋出資料儲存空間。
- 為節點集區設定不同的
nodePools[].vsphere.datastore
資料儲存庫。
後續步驟
如需其他協助,請與 Cloud Customer Care 團隊聯絡。
如要進一步瞭解支援資源,包括下列項目,請參閱「取得支援」: